an error

Discuss any questions about BEPUphysics or problems encountered.
Post Reply
BoltonBeedz
Posts: 45
Joined: Fri Dec 07, 2007 12:58 am

an error

Post 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
BoltonBeedz
Posts: 45
Joined: Fri Dec 07, 2007 12:58 am

Re: an error

Post by BoltonBeedz »

forget that. somthing weirds going on.
BoltonBeedz
Posts: 45
Joined: Fri Dec 07, 2007 12:58 am

Re: an error

Post by BoltonBeedz »

i checked it i didn't add my entity to space like a fool. please delete this.
Norbo
Site Admin
Posts: 4929
Joined: Tue Jul 04, 2006 4:45 am

Re: an error

Post 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.
Post Reply