 |
Blamite Game Engine - blam!
00398.09.22.23.2015.blamite
The core library for the Blamite Game Engine.
|
Go to the documentation of this file.
5 #include <OGRE/OgreManualObject2.h>
7 #include <Strings/components/classes/events/events.h>
8 #include <Strings/components/classes/vector/vector.h>
12 #define BLAM_EXT_API __declspec(dllexport)
14 #define BLAM_EXT_API __declspec(dllimport)
45 std::string
name =
"unnamed";
46 std::string description =
"";
47 int editor_folder_id = 0;
51 BlamVector3 position = { 0, 0, 0 };
52 BlamVector3 rotation = { 0, 0, 0 };
53 BlamVector3 scale = { 1, 1, 1 };
106 float cached_radius_0 = 1.0f;
107 float cached_radius_1 = 1.0f;
108 int cached_resolution = 5;
110 BlamVector3 cached_position = { 0, 0, 0 };
111 BlamVector3 cached_rotation = { 0, 0, 0 };
112 BlamVector3 cached_scale = { 1, 1, 1 };
113 BlamColor cached_color = BlamColor(255, 255, 255);
114 bool cached_solid =
true;
116 void CreateManualObject();
120 Ogre::ManualObject* manual_object =
nullptr;
121 Ogre::SceneNode* node =
nullptr;
122 Ogre::HlmsDatablock* datablock =
nullptr;
124 float radius_0 = 1.0f;
125 float radius_1 = 1.0f;
127 BlamColor
color = BlamColor(255, 255, 255);
152 std::vector<BlamWorldObject*> objects = std::vector<BlamWorldObject*>();
167 void RemoveObject(
uint64_t object_id);
169 int GetObjectCount();
189 void OnTickEvent(TickEvent* event);
191 void RenderObjects();
#define BLAM_EXT_API
Definition: world_objects.h:14
BLAM Ogre::HlmsUnlitDatablock * CreateDefaultUnlitDatablockForPrimitives(std::string id)
Definition: materials.cpp:916
BlamTagData * parent_tag
Definition: tags.h:164
void RenderObjects()
Definition: BlamWorldState.cpp:151
Ogre::SceneNode * node
Definition: world_objects.h:121
void AddObject(BlamWorldObject *object)
Definition: BlamWorldState.cpp:70
std::string name
The unique name of this object.
Definition: world_objects.h:45
BlamVector3 position
The position of this object in world space.
Definition: world_objects.h:51
BLAM void LogEvent(std::string message)
Logs a message to the log and/or console.
Definition: aliases.cpp:142
Blam3DPrimitiveType primitive_type
The type of primitive this object represents.
Definition: world_objects.h:119
bool Drop(BlamTagData *tag_data, BlamVector3 position)
Drops a tag into the world at the specified coordinates.
Definition: BlamWorldState.cpp:32
BLAM BlamRenderingEngine GetCurrentRenderingEngine()
Retrieves the current rendering engine being used.
Definition: rendering_abstraction.cpp:104
void Drop(std::string tag_name)
Definition: hs.cpp:44
BlamColor color
Definition: world_objects.h:127
bool solid
Definition: world_objects.h:128
BLAM Demo::GraphicsSystem * GetGraphicsSystem()
Definition: ogre.cpp:343
BlamWorldObjectType
Definition: world_objects.h:21
@ OGRE
Definition: rendering.h:41
char path[256]
The tag's path.
Definition: tags.h:84
BlamVector3 rotation
The rotation of this object in world space.
Definition: world_objects.h:52
int GetObjectCount()
Definition: BlamWorldState.cpp:101
Ogre::ManualObject * manual_object
Definition: world_objects.h:120
BlamTagData()
Definition: BlamTagData.cpp:8
BlamTagData * tag_data
Pointer to the tag data associated with this object.
Definition: world_objects.h:81
Ogre::SceneManager * getSceneManager(void) const
Definition: GraphicsSystem.h:146
BLAM void DrawCuboid(BlamVector3 position, BlamVector3 rotation, BlamVector3 scale)
Renders a cuboid to the screen.
Definition: cuboid.cpp:12
Class representing a tag-based world object.
Definition: world_objects.h:78
unsigned long long uint64_t
Definition: stdint.h:18
IMGUI_API void Render()
Definition: imgui.cpp:4248
~BlamTagData()
Definition: BlamTagData.cpp:15
std::vector< BlamTagInstance * > instances
Definition: tags.h:88
bool SetTagPath(std::string new_path)
Updates the tag path.
Definition: BlamTagData.cpp:31
BLAM void DrawCylinder(BlamVector3 position, BlamVector3 rotation, BlamVector3 scale, int resolution, int radius_top, int radius_bottom)
Renders a cylinder to the screen.
Definition: cylinder.cpp:28
BlamWorldObject * GetObjectAtIndex(int index)
Definition: BlamWorldState.cpp:122
void Render()
Renders the object to the screen.
Definition: BlamWorldObject_Tag.cpp:8
BLAM BlamTagData * CloneTag(BlamTagData *original_tag_data)
Definition: tag_io.cpp:825
BlamWorldObject * GetObjectById(uint64_t object_id)
Definition: BlamWorldState.cpp:130
uint64_t id
A unique identifier for this object. Used to identify objects during runtime.
Definition: world_objects.h:48
BlamTagInstance * GetInstance(std::string identifier)
Definition: BlamTagData.cpp:64
virtual void Render()
Renders the object to the screen.
Definition: BlamWorldObject.cpp:9
virtual ~BlamWorldObject()
Definition: world_objects.h:64
BlamVector3 scale
The scale/size of the object.
Definition: world_objects.h:53
bool HasObject(uint64_t object_id)
Definition: BlamWorldState.cpp:106
BlamWorldObjectType type
The type of this world object.
Definition: world_objects.h:55
std::string identifier
Definition: tags.h:165
Ogre::HlmsDatablock * datablock
Definition: world_objects.h:122
void OnTickEvent(TickEvent *event)
Definition: BlamWorldState.cpp:146
Class representing a primitive-based world object.
Definition: world_objects.h:103
Class representing a world object.
Definition: world_objects.h:42
BlamWorldObject(BlamWorldState *_world, BlamWorldObjectType _type)
Creates a new world object.
Definition: BlamWorldObject.cpp:3
float radius_1
A secondary radius of the primitive. Only used in cylinders.
Definition: world_objects.h:125
BlamWorldObject_Tag(BlamTagData *_tag_data, BlamWorldState *_world)
Creates a new tag-based world object.
Definition: BlamWorldObject_Tag.cpp:3
~BlamWorldState()
Destroys the world state.
Definition: BlamWorldState.cpp:16
BlamTagInstance * CreateNewInstance()
Definition: BlamTagData.cpp:51
float radius_0
The radius of the primitive. Only used in cylinders.
Definition: world_objects.h:124
int resolution
The level of detail to use for the primitive. Only used in cylinders.
Definition: world_objects.h:126
Class used to contain and access tag data.
Definition: tags.h:68
void RemoveObject(uint64_t object_id)
Definition: BlamWorldState.cpp:85
Blam3DPrimitiveType
Definition: world_objects.h:28
@ BGFX
Definition: rendering.h:40
BlamTagData * instance
Definition: tags.h:166
BlamWorldState * world
The world state this object belongs to.
Definition: world_objects.h:50
~BlamWorldObject_Primitive()
Definition: BlamWorldObject_Primitive.cpp:36
void Render()
Renders the object to the screen.
Definition: BlamWorldObject_Primitive.cpp:306
Class representing a world state.
Definition: world_objects.h:149
ARPHIC PUBLIC LICENSE Ltd Yung Chi Taiwan All rights reserved except as specified below Everyone is permitted to copy and distribute verbatim copies of this license but changing it is forbidden Preamble The licenses for most software are designed to take away your freedom to share and change it By the ARPHIC PUBLIC LICENSE specifically permits and encourages you to use this provided that you give the recipients all the rights that we gave you and make sure they can get the modifications of this software Legal Terms Font means the TrueType fonts AR PL Mingti2L AR PL KaitiM AR PL KaitiM and the derivatives of those fonts created through any modification including modifying reordering converting changing font name
Definition: ARPHICPL.TXT:16
BlamWorldObject_Primitive(Blam3DPrimitiveType _primitive_type, BlamWorldState *_world)
Creates a new primitive world object.
Definition: BlamWorldObject_Primitive.cpp:15
BlamWorldState()
Initializes a new world state.
Definition: BlamWorldState.cpp:8
std::string tag_class
The tag's short class name.
Definition: tags.h:85