Hello!
Because i have many Problems which i sometimes cannot solve for myself, i wanted to start one Thread for some different Questions.
My first Question is that i want to call an object from my Room2 in the Globalscript.. This is not possible because Globalscript cannot recognise my Room Specific Objects...
Here is my Sourcecode:
Code: AGS
The Errormessage is:
Because i have many Problems which i sometimes cannot solve for myself, i wanted to start one Thread for some different Questions.
My first Question is that i want to call an object from my Room2 in the Globalscript.. This is not possible because Globalscript cannot recognise my Room Specific Objects...
Here is my Sourcecode:
function Kater_UseInv()
{
if ( (player.ActiveInventory==inventory [7]) || (player.ActiveInventory==inventory [4]) )
{
if (Kater.Room==2)
{
if ((player.HasInventory(Napfivoll)) && (player.HasInventory(essenfertig)) )
{
cEgo.Walk(555, 356, eBlock);
wassernapf.visible=true; // <- Here is the Problem! What to do with it?!
volleschale.visible=true; // <- Here is the Problem! What to do with it?!
cEgo.Walk(505, 380);
Kater.Walk(603, 325, eBlock);
}
else
{
Display("Die Katze braucht Wassser -und- Nahrung.");
}
}
else
{
Display("Geh Küche");
}
}
else
{
Display("Das möchte er nicht..");
}
}
The Errormessage is:
Quote
GlobalScript.asc(265): Error (line 265): Undefined token 'wassernapf'