The Daily Click ::. Forums ::. Klik Coding Help ::. Throwing and picking up objects.
 

Post Reply  Post Oekaki 
 

Posted By Message

Dr Collosus



Registered
  14/07/2004
Points
  33
15th July, 2004 at 13:37:27 -

Does any one know some events for throwing and picking up things, in a platformer???

 
n/a

JP



Registered
  07/06/2003
Points
  1338
15th July, 2004 at 19:59:08 -

That is specific.

 
Steve Zissou: Anne-Marie, do all the interns get Glocks?

Anne-Marie: No, they have to share one.

Radix

hot for teacher

Registered
  01/10/2003
Points
  3139

Has Donated, Thank You!VIP MemberGOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!GOTW WINNER CUP 4!
15th July, 2004 at 20:26:01 -

Yeah, I did it the other day. All you need is for pickupable objects to have a flag that says when they're being carried, and for the player object to have a flag saying when it's carrying something.

When the 'carrying' flag is off, and the player performs the picking up action, set the both objects' flags on. When the carryable object's flag is on, set it to the position of wherever the character carries it (above his head, for example), rather than doing what it normally does.

To throw, just use a second flag for the carriable object that says it's airborne, so it can no longer be picked up, thrown or do what it normally does, and apply whatever actions you want for it to fly. Simple.

 
n/a
   

Post Reply



 



Advertisement

Worth A Click