Page 1 of 1
barrier
Posted:
Thu Aug 12, 2010 2:55 am
by ESL
I get the idea that you can use a wire frame actor to create a barrier. Are there any more specific examples?
I want to make a wall that blocks the actor from passing until an action occurs that destroys the wall.
Re: barrier
Posted:
Thu Aug 12, 2010 3:16 am
by Bee-Ant
Why don't you just make the player collide with the wall itself?
If the wall and the background are the same actor, you can use this code :
Wall -> CreateActor
- Code: Select all
if(animindex==getAnimindex("Wall"))barrier=1;
Player -> Collision -> Wall
- Code: Select all
if(collide.barrier==1)PhysicalResponse();
Re: barrier
Posted:
Thu Aug 12, 2010 5:14 am
by ESL
I tried it but there were too many code errors.
I made"wall" the actor>collision with man> script editor> added your scripts
Re: barrier
Posted:
Thu Aug 12, 2010 8:17 am
by Bee-Ant
Did you just copy-paste it?
In that case, you have to make "barrier" variable first (actor variable).
Re: barrier
Posted:
Fri Aug 13, 2010 5:16 am
by ESL
I want to have the wall as a separate character. How do I create a barrier variable?
Thanks!
Re: barrier
Posted:
Fri Aug 13, 2010 1:33 pm
by Bee-Ant
Go to any Script Editor and do this :
Re: barrier
Posted:
Sat Aug 14, 2010 3:56 am
by ESL
Thanks so much. Now the problem is that the focus goes back to it's original position so that the letters overlap each other.