[Scummvm-cvs-logs] SF.net SVN: scummvm:[42245] scummvm/branches/gsoc2009-draci/engines/draci

dkasak13 at users.sourceforge.net dkasak13 at users.sourceforge.net
Tue Jul 7 23:24:40 CEST 2009


Revision: 42245
          http://scummvm.svn.sourceforge.net/scummvm/?rev=42245&view=rev
Author:   dkasak13
Date:     2009-07-07 21:24:39 +0000 (Tue, 07 Jul 2009)

Log Message:
-----------
Implementend F_Not GPL function.

Modified Paths:
--------------
    scummvm/branches/gsoc2009-draci/engines/draci/script.cpp
    scummvm/branches/gsoc2009-draci/engines/draci/script.h

Modified: scummvm/branches/gsoc2009-draci/engines/draci/script.cpp
===================================================================
--- scummvm/branches/gsoc2009-draci/engines/draci/script.cpp	2009-07-07 21:18:28 UTC (rev 42244)
+++ scummvm/branches/gsoc2009-draci/engines/draci/script.cpp	2009-07-07 21:24:39 UTC (rev 42245)
@@ -116,7 +116,7 @@
 
 	/** Functions used by the mathematical evaluator */
 	static const GPL2Function gplFunctions[] = {
-		{ "Not", 		NULL },
+		{ "Not", 		&Script::funcNot },
 		{ "Random", 	&Script::funcRandom },
 		{ "IsIcoOn", 	NULL },
 		{ "IsIcoAct", 	NULL },
@@ -218,6 +218,10 @@
 	return _vm->_rnd.getRandomNumber(n);
 }
 
+int Script::funcNot(int n) {
+	return !n;
+}
+
 /* GPL commands */
 
 void Script::load(Common::Queue<int> &params) {

Modified: scummvm/branches/gsoc2009-draci/engines/draci/script.h
===================================================================
--- scummvm/branches/gsoc2009-draci/engines/draci/script.h	2009-07-07 21:18:28 UTC (rev 42244)
+++ scummvm/branches/gsoc2009-draci/engines/draci/script.h	2009-07-07 21:24:39 UTC (rev 42245)
@@ -116,6 +116,7 @@
 	int operMod(int op1, int op2);
 
 	int funcRandom(int n);
+	int funcNot(int n);
 
 	void setupCommandList();
 	const GPL2Command *findCommand(byte num, byte subnum);


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list