Novelty scripting reference > Scripted events > OnCreate

OnCreate

This event is called at the start of the page, when the object is created.


Implicit arguments

Object@ sender
Handle to the associated object.


Sample

event MyEvent.OnCreate
{
	// Turn object red 
	sender.SetColor(Color("red"));
}

Back to top