Page 1 of 1

an error

Posted: Wed Jul 22, 2009 10:06 pm
by BoltonBeedz
sorry
e.applyImpulse(e.centerOfMass, towardsplayer * 0.001f, true);
results in this
"Object reference not set to an instance of an object."
for no obvious reason
i did recently add the entity to the space maybe thats it
it works fine on all the entities i add during startup

Re: an error

Posted: Wed Jul 22, 2009 10:20 pm
by BoltonBeedz
forget that. somthing weirds going on.

Re: an error

Posted: Wed Jul 22, 2009 10:22 pm
by BoltonBeedz
i checked it i didn't add my entity to space like a fool. please delete this.

Re: an error

Posted: Wed Jul 22, 2009 10:50 pm
by Norbo
There was an unprotected reference to the entity's space in the applyAngularImpulse method (called from within the applyImpulse method). The applyImpulse method shouldn't require that an entity belongs to a space and this should be corrected in the next version.