deleting a bullet
BlitzPlus Forums/BlitzPlus Programming/deleting a bullet
| ||
hi guys, it seems like im posting too much :). any way, im working on a game, and i need to delete a bullet when it hits the botton of the screen, but it says "can't delete non newtype". help!(again) |
| ||
This compiles:Type a End Type b.a=New a Delete band this generates the error "Can't delete non-Newtype": Type a End Type ;b.a=New a Delete b Therefore, your problem is attempting to delete an instance of a Type that you haven't created or have already deleted. Make sure you haven't made any typos either. |
| ||
ok, there are no errors in the code, but delete each enemybullet works. why? |
| ||
delete each enemybullet works. why? Think about it for a second...If you tell it to delete each bullet, and there are no bullets, then there's nothing to delete, therefore, no error. |