mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2025-12-20 17:26:01 +08:00
[cpp] 4.3 porting WIP
This commit is contained in:
parent
91f2f71abf
commit
28c48dc88a
@ -78,6 +78,9 @@ namespace spine {
|
||||
/// @param parent May be NULL.
|
||||
Bone(BoneData& data, Bone* parent);
|
||||
|
||||
/// Copy constructor. Does not copy the children bones.
|
||||
Bone(Bone& bone, Bone* parent);
|
||||
|
||||
/// The parent bone, or null if this is the root bone.
|
||||
Bone* getParent();
|
||||
|
||||
|
||||
@ -47,6 +47,16 @@ Bone::Bone(BoneData &data, Bone *parent) : PosedGeneric<BoneData, BoneLocal, Bon
|
||||
_applied->_bone = this;
|
||||
}
|
||||
|
||||
Bone::Bone(Bone &bone, Bone *parent) : PosedGeneric<BoneData, BoneLocal, BonePose>(bone._data),
|
||||
PosedActive(),
|
||||
_parent(parent),
|
||||
_children(),
|
||||
_sorted(false) {
|
||||
_constrained._bone = this;
|
||||
_applied->_bone = this;
|
||||
_pose.set(bone._pose);
|
||||
}
|
||||
|
||||
Bone *Bone::getParent() {
|
||||
return _parent;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user