mirror of
https://github.com/geode-sdk/geode.git
synced 2024-11-22 23:48:08 -05:00
Make the field fix only a minor change
This commit is contained in:
parent
534b20d3df
commit
ceeea0bd51
2 changed files with 6 additions and 0 deletions
|
@ -49,6 +49,8 @@ namespace geode::modifier {
|
|||
}
|
||||
};
|
||||
|
||||
[[deprecated("Will be removed in 1.0.0")]]
|
||||
GEODE_DLL size_t getFieldIndexForClass(size_t hash);
|
||||
GEODE_DLL size_t getFieldIndexForClass(char const* name);
|
||||
|
||||
template <class Parent, class Base>
|
||||
|
|
|
@ -84,6 +84,10 @@ size_t modifier::getFieldIndexForClass(char const* name) {
|
|||
return s_nextIndex[name]++;
|
||||
}
|
||||
|
||||
size_t modifier::getFieldIndexForClass(size_t hash) {
|
||||
return s_nextIndex[std::string(hash)]++;
|
||||
}
|
||||
|
||||
// not const because might modify contents
|
||||
FieldContainer* CCNode::getFieldContainer() {
|
||||
return GeodeNodeMetadata::set(this)->getFieldContainer();
|
||||
|
|
Loading…
Reference in a new issue