Question about ZGE

All topics about ZGameEditor goes here.

Moderator: Moderators

Post Reply
User avatar
turshija
Posts: 127
Joined: Sat Feb 17, 2007 9:26 am
Location: Novi Sad, Serbia
Contact:

Question about ZGE

Post by turshija »

In tutorial 3 we have something like this
* Add a DefineCollision component to OnLoaded on App.
* Set the following properties:
- Comment = Player vs Walls
- Cat2 = 1
what is Cat2 ? why did you put Cat2 to 1 and not Cat1 ? when I set Cat2 to 0 and Cat1 to 1 I get the same thing ....
help please :)

Boris
User avatar
VilleK
Site Admin
Posts: 2277
Joined: Mon Jan 15, 2007 4:50 pm
Location: Stockholm, Sweden
Contact:

Post by VilleK »

We want to have collision between walls and player.

PlayerModel is category 0 (default)
WallModel is category 1

So DefineCollision needs to have Cat1 to 0 and Cat2 to 1. Or the other way
around, it makes no difference.

And since DefineCollision.Cat1 is zero by default, we do not need to touch it.

I've tried to explain in the component reference:
http://www.emix8.org/wiki/index.php?n=C ... eCollision

I will update the tutorial to make it more clear what is happening :)
User avatar
turshija
Posts: 127
Joined: Sat Feb 17, 2007 9:26 am
Location: Novi Sad, Serbia
Contact:

Post by turshija »

Ok, maybe I understand that ....
Now I am trying to create new version of my own game by modifying tutorial 3 :)

really great program ...
Post Reply