VR-Engage  2.2
Loading...
Searching...
No Matches
vreSimulationModelSetLoader.h
Go to the documentation of this file.
1/*******************************************************************************
2** Copyright (c) 2025 MAK Technologies
3** All rights reserved.
4*******************************************************************************/
5
6//! \file vreSimulationModelSetLoader.h
7//! \ingroup vreSimulationObjectEditor
8//! \brief Extended simulation model set loader for VREngage
9//!
10//! This file defines the DtVreSimulationModelSetLoader class, which extends
11//! the base simulation model set loader with VREngage-specific functionality.
12//! It provides enhanced capabilities for loading and saving ammunition tables
13//! with VREngage-specific extensions.
14
15#pragma once
16
18
19#include <simulationObjectEditorImpl/simulationModelSetLoader.h>
20
21namespace makVre
22{
23//! \brief Extended simulation model set loader for VREngage
24//!
25//! This class extends the base simulation model set loader with the ability
26//! to load and save VREngage-specific extensions to the ammunition table in
27//! a Simulation Model Set (SMS). It handles the creation of VREngage-specific
28//! ammunition parameters and ensures proper serialization of extended data.
29class VRESIMULATIONOBJECTEDITOR_DLL DtVreSimulationModelSetLoader : public DtSimulationModelSetLoader
30{
31public:
32 //! \brief Constructor
33 //! \param de The document environment providing access to application resources
34 //!
35 //! Creates a new simulation model set loader for VREngage with the specified
36 //! document environment.
38
39 //! \brief Destructor
40 //!
41 //! Cleans up resources used by the simulation model set loader.
43
44 //! \brief Saves the ammunition table with VREngage-specific extensions
45 //! \return True if the save operation was successful, false otherwise
46 //!
47 //! Overrides the base implementation to use VREngage-specific ammunition parameters.
48 //! This corrects the issue with the standard VR-Forces implementation using
49 //! DtAmmunitionParams on the stack instead of the derived DtVreAmmunitionParams,
50 //! which has VREngage-specific extensions. This override replaces the stack
51 //! variable with a call to createAmmunitionParameters(), which creates the
52 //! correct derived type.
53 //!
54 //! \note This function should be removed once VREngage builds against a version
55 //! of VR-Forces that has resolved defect Jira VRF-2152.
56 virtual bool saveAmmunitionTable() override;
57
58protected:
59 //! \brief Creates VREngage-specific ammunition parameters
60 //! \return Pointer to the created ammunition parameters object
61 //!
62 //! Overrides the base implementation to create the derived DtVreAmmunitionParameters,
63 //! which is the extended type used by VREngage. This enables support for
64 //! VREngage-specific extensions to ammunition parameters.
65 virtual DtAmmunitionParams* createAmmunitionParameters() const override;
66
67private:
68 //! \brief Copy constructor (not implemented)
69 //! \param other The source object
70 //!
71 //! Copy constructor is private and not implemented to prevent copying.
73
74 //! \brief Assignment operator (not implemented)
75 //! \param other The source object
76 //! \return Reference to this object
77 //!
78 //! Assignment operator is private and not implemented to prevent assignment.
80};
81} // namespace makVre
virtual ~DtVreSimulationModelSetLoader() override
Destructor.
DtVreSimulationModelSetLoader & operator=(const DtVreSimulationModelSetLoader &other)
Assignment operator (not implemented)
virtual bool saveAmmunitionTable() override
Saves the ammunition table with VREngage-specific extensions.
DtVreSimulationModelSetLoader(const DtVreSimulationModelSetLoader &other)
Copy constructor (not implemented)
DtVreSimulationModelSetLoader(makVrv::DtDe &de)
Constructor.
virtual DtAmmunitionParams * createAmmunitionParameters() const override
Creates VREngage-specific ammunition parameters.
Export macros for the VREngage Simulation Object Editor library.
#define VRESIMULATIONOBJECTEDITOR_DLL
Platform-specific DLL export/import declaration.
Definition export.h:27
Include export definitions for this library.
Definition glsVreMessageUtil.h:49
makVrv::DtDe * de()
Gets the display element pointer used by the plugin.