mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
ItemDef/EntityDef/Block: Add method cloneTo to definition to other definition
ContentBuilder: Add method `get` to get definition or nullptr ContentLoader: Add functionality to clone from definition specified in `parent` field in json
This commit is contained in:
parent
8ef288c189
commit
5f6ae5daba
9 changed files with 123 additions and 13 deletions
12
src/objects/EntityDef.cpp
Normal file
12
src/objects/EntityDef.cpp
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
#include "EntityDef.hpp"
|
||||
void EntityDef::cloneTo(EntityDef& dst) {
|
||||
dst.components = components;
|
||||
dst.bodyType = bodyType;
|
||||
dst.hitbox = hitbox;
|
||||
dst.boxSensors = boxSensors;
|
||||
dst.radialSensors = radialSensors;
|
||||
dst.skeletonName = skeletonName;
|
||||
dst.blocking = blocking;
|
||||
dst.save = save;
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue