Custom collision shape?

TeebTeeb Member Posts: 5
edited December 2011 in Working with GS (Mac)
Is it possible to define a custom collision shape for an actor?

It's all very well having a circle and a square available, but I have an irregularly shaped actor and being a confined game in terms of space, I want the collision shape to reflect the real shape of the actor.

For instance, let's say my main actor is a triangle - what about the space on the two sides? I don't want the object to collide in that space, even if the image transparency exists there.

Is there any way of doing this? I saw someone suggest that it's possible to group together certain actors and have them all with square or circle collision shapes in order to 'construct' the main actor. My game is extremely simple and so I have some leeway. So this would be possible I suppose, but it sounds messy and I'd rather a different option.

Comments

  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    Hi Teeb, that's on the cards for a future GSC release; here's hoping it'll be here before 1.0...

    The workaround you mentioned is really the only way to simulate non-zero alpha collision only at the moment...

    ----------------------------------------------
    http://davidgriffinapps.co.uk/

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • TeebTeeb Member Posts: 5
    Thanks for the response gyro. Suppose it's not going to be a terribly difficult workaround for me considering the shape of my actor, so I've just got to stop complaining and get to it ^^
  • TeebTeeb Member Posts: 5
    Yeah.. like say I had a triangle shaped actor, I could just make a series of small circles surrounding it as the 'boundaries'?
  • CloudsClouds Member Posts: 1,599
    @ Teeb

    Yeah.. like say I had a triangle shaped actor, I could just make a series of small circles surrounding it as the 'boundaries'?

    It would be much more efficient to simply have three long thin rectangles along each edge.
  • MaestroKaizersMaestroKaizers Member Posts: 6
    Hi! Teeb, i am working on a game aswell, and i am both a triangle and a circle that i want to "act realistic". The method you mentioned sounds like it works, have you tried it out? If so could you please explain what behaviors etc i will need to use for this. Im kinda new to GameSalad, and still learning, it would be awsome if you or someone else could tell me.

    Cheers
  • CloudsClouds Member Posts: 1,599
    I don't think this will work beyond being able to move the object left right up and down, as soon as you want to rotate this composite object all (mathematical) hell will break loose!
  • podzolpodzol Member Posts: 1
    I'd very much like to see the ability to apply custom object shape. I can see many applications for us use in jig-saw puzzle-type games, or games where alignment important in collision scenarios.
  • eoineoin Member, PRO Posts: 36
    Is there any Official News on a Custom Path or a Custom Shape in Gamesalad.
  • ahiungahiung Member Posts: 36

    bump

Sign In or Register to comment.