CreateInvisibleObject

Object CreateInvisibleObject(string polygon)

Create an Object Sprite defined by a polygon.

It returns an object type.

  • string polygon: Coordinates of the polygon (see how to create image maps).
//The main function
function Main()
{
	//Title of the Room
	SetTitle("Outside the house");
	
	//Creating Scene and menu
	CreateScreen("outsideright","543,250,587,260,622,398,2,396,1,167,490,171,508,247");
	
	//Adding the player
	CreatePlayer(20,260);
	
	Window1=CreateInvisibleObject("116,39,154,53,164,79,143,106,120,110,81,98,70,71,89,46");
	Window1.description="I cannot open it, I see three vampires blocking the door to the gym.";
	
	Window2=CreateInvisibleObject("375,39,408,50,424,75,405,102,379,109,348,101,329,75,345,50");
	Window2.description="Closed ... It seems grandad closed everything to protect me.";
	
	//Persons
	Grandad=CreateObject("Grandad",350,260);
	Grandad.description="Oh my God! my grandad was knocked by the vampires.";
	Grandad.status="knocked";
	Grandad.SetConversation(TaoistConversation);
	Grandad.SetUseAction(GrandadUse);
	
	//Objects
	Sword=CreateObject("Sword",450,270);
	Sword.description="It's my grandad's sword";
	Sword.Takable();
}

To add object variables we will use a simple dot-notation.

Object.variable=value;

Get the latest version here.


It works on: