Files
dsrc/sku.0/sys.server/compiled/game/script/working/cmayer/memtest.script
T

36 lines
652 B
Plaintext

include library.utils;
trigger OnHearSpeech(obj_id speaker, string text)
{
if ( text == "test" )
{
dictionary dict = new dictionary();
if (!hasObjVar(self, "myTest"))
{
messageTo(self, "TestCallback", dict, 1, true);
setObjVar(self, "myTest", 1);
}
}
if (text == "end")
{
removeObjVar(self, "myTest");
}
return SCRIPT_CONTINUE;
}
messageHandler TestCallback()
{
if (hasObjVar(self, "myTest"))
{
debugSpeakMsg(self, "bleh");
resizeable int[] test = new int[0];
for (int j = 0; j < 2000; ++j)
{
test = utils.addElement(test, j);
}
messageTo(self, "TestCallback", params, 1, true);
}
return SCRIPT_CONTINUE;
}