Game Development Community

Trigger on TGB

by Bruce Slabinski · in Technical Issues · 01/01/2007 (5:07 pm) · 2 replies

Hi, I'm very new at programming and I want to know what script I make so that when a static sprite enters the "Trigger" area, It will load the next level.


I thought it was

setCollisionResponse(loadLevel(%levelFile))

but I was wrong. Can anyone help?

#1
01/04/2007 (8:20 am)
This post should go in the TGB forums (click Edit Subscriptions from the Forum Listings if it doesn't show up for you there).

Triggers have their own callbacks - onEnter and onLeave. setCollisionResponse is for things like "CLAMP" "STICKY" or "KILL". Look in the documentation at the TGB Reference doc - it has almost all the functions you can use, and has the functions for triggers in there.
#2
01/04/2007 (12:46 pm)
Oh i thought everything was for TGE AND TGB