Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Game Development

Reply
 
LinkBack Thread Tools Display Modes
Old 08-22-2011, 09:47 PM   #1 (permalink)
Registered Member
 
Join Date: Nov 2009
Posts: 31
thyrgle is on a distinguished road
Default Having trouble removing enemies in Corona SDK.

First off I am making my objects with the Beebe Games Class. I am also using the doTansition and for its onComplete function I have made the following function (inside the function I am using to make the enemy):
Code:
local removeEnemy = function()
    enemy:destroy()
    enemy = nil
end
It is being called (I tested by putting a print("Here") inside of the function. But, after a while my iStats menu bar shows that the Corona Simulator is slowly taking up more and more of my free memory. I think that I am not not removing the enemy object right since it is the only object I am creating continuously.

What should I change my onComplete function to?
thyrgle is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 397
14 members and 383 guests
7twenty7, apatsufas, AppsBlogger, comicool, Creativ, Dalia, dansparrow, Duncan C, HemiMG, heshiming, LunarMoon, Murphy, pbart, Tomsky
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,676
Threads: 94,127
Posts: 402,915
Top Poster: BrianSlick (7,990)
Welcome to our newest member, jleannex55
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 06:54 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0