mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-03-18 20:00:56 +00:00
Compilation fixes for C++20
This commit is contained in:
parent
e16351605b
commit
1940becb2d
40 changed files with 220 additions and 211 deletions
|
|
@ -133,6 +133,11 @@ namespace Sim
|
|||
SimObject* findObject(const char* name);
|
||||
SimObject* findObject(const char* fileName, S32 declarationLine);
|
||||
|
||||
inline SimObject* findObject(const String& name)
|
||||
{
|
||||
return findObject(name.c_str());
|
||||
}
|
||||
|
||||
template<class T> inline bool findObject(SimObjectId iD,T*&t)
|
||||
{
|
||||
t = dynamic_cast<T*>(findObject(iD));
|
||||
|
|
@ -143,6 +148,11 @@ namespace Sim
|
|||
t = dynamic_cast<T*>(findObject(objectName));
|
||||
return t != NULL;
|
||||
}
|
||||
template<class T> inline bool findObject(const String& objectName, T*& t)
|
||||
{
|
||||
t = dynamic_cast<T*>(findObject(objectName));
|
||||
return t != NULL;
|
||||
}
|
||||
|
||||
SimObject *spawnObject(String spawnClass,
|
||||
String spawnDataBlock = String::EmptyString,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue