Lotus Particle System

Blitz3D Forums/Blitz3D Beginners Area/Lotus Particle System

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Greetings All,


I am using the Lotus particle system and I am getting a weird error periodically. The error is "Runtime Error - Entity does not exist". I realize that this stems back to deleting an entity and then referencing later. The odd thing is the location of this error:

File: c_vector.bb
Function: LotusVec_Entity_Position.LotusVector(Entity,G=False)

Here is the code for the function:

Function LotusVec_Entity_Position.LotusVector(Entity,G=False)

If Entity=0 then Return Null
V.LotusVector = New LotusVector
V\X = EntityX(Entity,G)
V\Y = EntityY(Entity,G)
V\Z = EntityZ(Entity,G)
Return V
End Function

The error occurs on the EntityX line which leads me to believe that somewhere within the Lotus particle system the entity is being freed but is not being set to 0. I have checked my code a number of times (and will check it again) and could not find a place that I freed and entity without setting the entity to 0. Any insight would be helpful.


Thanks,

Jamie