summaryrefslogtreecommitdiffstats
path: root/source/squirrelbindings
diff options
context:
space:
mode:
authorlapayo94@gmail.com <lapayo94@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-07-10 18:46:15 +0200
committerlapayo94@gmail.com <lapayo94@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-07-10 18:46:15 +0200
commit273ddcbfff87676d10c04e90ba98a74035d9d30a (patch)
tree618ad418f30685a33d8c5164cc58a36688aed338 /source/squirrelbindings
parentAuthentication should work now.. (diff)
downloadcuberite-273ddcbfff87676d10c04e90ba98a74035d9d30a.tar
cuberite-273ddcbfff87676d10c04e90ba98a74035d9d30a.tar.gz
cuberite-273ddcbfff87676d10c04e90ba98a74035d9d30a.tar.bz2
cuberite-273ddcbfff87676d10c04e90ba98a74035d9d30a.tar.lz
cuberite-273ddcbfff87676d10c04e90ba98a74035d9d30a.tar.xz
cuberite-273ddcbfff87676d10c04e90ba98a74035d9d30a.tar.zst
cuberite-273ddcbfff87676d10c04e90ba98a74035d9d30a.zip
Diffstat (limited to '')
-rw-r--r--source/squirrelbindings/SquirrelObject.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/source/squirrelbindings/SquirrelObject.h b/source/squirrelbindings/SquirrelObject.h
index 1ac6fa105..547dd4e02 100644
--- a/source/squirrelbindings/SquirrelObject.h
+++ b/source/squirrelbindings/SquirrelObject.h
@@ -9,15 +9,20 @@ public:
m_SquirrelObject = a_Obj;
}
- Sqrat::Function GetFunction(const char *methodName)
+ Sqrat::Function GetFunction(const char *a_MethodName)
{
if(m_SquirrelObject.IsNull())
return Sqrat::Function();
- Sqrat::Function method(m_SquirrelObject, methodName);
+ Sqrat::Function method(m_SquirrelObject, a_MethodName);
return method;
}
+ bool HasFunction(const char *a_MethodName)
+ {
+ return !this->GetFunction(a_MethodName).IsNull();
+ }
+
protected:
Sqrat::Object m_SquirrelObject;