Gilbet, thought we had it..
but its not really working.. Ive set the timer to activate from a region now.
The ceiling drops down as it should with the char behind it but nothing is said (displayed)..I also wanted the char to changeview to 17 if collides...
Code: ags
And put this in RepExec:
Code: ags
UPDATE
I think it may be a case of distance,speed of object and time..!!
This is what I now use:
Code: ags
Code: ags
Do I really need a Timer?... would it be better to adjust speed of Object with Collision???
barefoot
but its not really working.. Ive set the timer to activate from a region now.
The ceiling drops down as it should with the char behind it but nothing is said (displayed)..I also wanted the char to changeview to 17 if collides...
function region1_WalksOnto()
{
Display("Clue: You are going to have to hurry!");
SetTimer(1, 160);
object[0].Move(80, 469, 2, eNoBlock, eAnywhere);
}
And put this in RepExec:
function room_RepExec(){
if (IsTimerExpired(1)) {
if (cindy_bones.IsCollidingWithObject(object[0])) Display("You've been squashed. It's the end of your journey!!");
else Display("Congratulations! You escaped from the trap!");
}
}
UPDATE
I think it may be a case of distance,speed of object and time..!!
This is what I now use:
function region1_WalksOnto()
{
Display("Clue: You are going to have to hurry!");
SetTimer(1, 120);
object[0].Move(56, 433, 3, eNoBlock, eAnywhere);
}
function room_RepExec(){
if (IsTimerExpired(1)) {
if (cindy_bones.IsCollidingWithObject(object[0])) Display("You've been squashed. It's the end of your journey!!");
else Display("Congratulations! You escaped from the trap!");
}
}
Do I really need a Timer?... would it be better to adjust speed of Object with Collision???
barefoot