# Item not affected by gravity in a platform game

**URL:** <https://forum.kirupa.com/t/item-not-affected-by-gravity-in-a-platform-game/303499>\
**Category:** flash\
**Created:** [January 21, 2010, 9:04am UTC](https://forum.kirupa.com/t/item-not-affected-by-gravity-in-a-platform-game/303499 "2010-01-21T09:04:29Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ExA](https://avatars.discourse-cdn.com/v4/letter/e/7cd45c/32.png) [@ExA](https://forum.kirupa.com/u/ExA)\
**Post date:** [January 21, 2010, 9:04am UTC](https://forum.kirupa.com/t/item-not-affected-by-gravity-in-a-platform-game/303499/1 "2010-01-21T09:04:29Z")

</div>

Hi everyone,

I’m just starting out in actionscript 3.0, and I’m trying to create a basic platform game. Since I don’t really have time to code it from A to Z, I’m using an ‘engine’ I found [here](http://www.emanueleferonato.com/2009/08/15/tilesense-as3-tile-based-platform-engine/).

I’ve made a few modifications (mostly deleting stuff I don’t need, such as the enemies and the coins).

Now I’d like to create a crate that the player character can pick-up, throw, put down and jump on. I’ve created a new class (Cage.as) for it, based on the player class. When I run the game, the crate is displayed, but it just floats there. I can’t figure how to make it interact with gravity (i.e. fall to the ground).

Can you help me with that?
