# Deleting an object from array

**URL:** <https://forum.kirupa.com/t/deleting-an-object-from-array/233469>\
**Category:** flash\
**Created:** [July 24, 2007, 10:37am UTC](https://forum.kirupa.com/t/deleting-an-object-from-array/233469 "2007-07-24T10:37:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![superpeppe](https://avatars.discourse-cdn.com/v4/letter/s/a183cd/32.png) [@superpeppe](https://forum.kirupa.com/u/superpeppe)\
**Post date:** [July 24, 2007, 10:37am UTC](https://forum.kirupa.com/t/deleting-an-object-from-array/233469/1 "2007-07-24T10:37:24Z")

</div>

Hi

I am currently developing a game in AS3. The game has an array that contain all Movable objects, but during the game a Movable might die, so the question is how do i delete that array element? There is of course the splice() Method, but does it delete the object or what? I searched the internet, and some places the write that I should use the delete statement, setting a null reference or something completely different…

By the way it would be nice if you could post the code, it’s a lot easier to understand:thumb:

Thanks in advance!
