Page 1 of 1

Is this a bug? Collision to only one side does not work

PostPosted: Thu May 25, 2006 11:08 pm
by Diana Kennedy
Hi,

I have a pretty tricky Problem here. I probably would need some kind of IF script, but I don’t the heck know how to do so.

Here’s what I want to do: I have a rider that gallops trough the desert.
There’s a big rock.

Image

When the rider actor has collision with rock actor, he changes animation, the horse refuses to go forth and marches back- he goes back with the help of a path. At the end of the path, he changes animation again, gallops forward and if nothing is done, the same thing happens. The horse will refuse for ever.

Image

But the player can strike the space bar. This will make the rider jump. Not via the gravitation thing, I could not manage to do a clean jump this way, mostly because the actor only jumps straight in the air, without moving forward (over the rock). So I created a jumping animation and made a new actor of it. So when space bar is put, rider actor is destroyed, jumper actor is created.

Image

I did not make a collision action in the jumper actor, so he can jump over the rock. After jump is finished – jumper is destroyed, original rider actor is re-created.
But.. - and here’s my problem: the right or even bottom side of the rider-actor still collides with the rock and so, instead of galloping forth, the rider restarts the “refusing animation”.

Yes, I tried to avoid the thing by making the collision effective only to the right side of the rock actor – but , then, the whole thing doesn’t work: In this case, the changing animation (from galloping to refusing) does not happen. Is this a bug?

Anyway. Is there a possibility to get the rider over the rock, without any problem?

PostPosted: Fri May 26, 2006 12:11 am
by frodo
make him jump higher :) (heh heh!)

PostPosted: Fri May 26, 2006 1:08 am
by Novice
Simplest way i thik would be to destroy the rock actor and make a new one when the rider is recreated, but without the change animation action.

PostPosted: Fri May 26, 2006 2:10 am
by DilloDude
The problem coyld be when it collides, it thinks it's colliding with the top or bottom side instead, due to the hape of the animation. You could try on collision, test is the direction between the rock and you is > 300 or < 45, and if it is, then do the action.

PostPosted: Fri May 26, 2006 4:43 am
by Fuzzy
Remember that time when I said I liked your graphics? That is not true. I really LOVE your graphics. You are SO talented!


I agree with novice(you modest one!), remove the rock when jumping. Use a second actor that doesnt have collisions, or just turn the rocks collision off after the jump starts.