About Store Forum Documentation Contact
Donations:
289$/mo



Post Reply 
Controller initial pos()
Author Message
aceio76 Offline
Silver Supporter

Post: #1
Controller initial pos()
Hi Esenthel,

I am trying to troubleshoot an issue that I can't understand. When I perform ctrl.create() and set it an initial pos() location, the controller seems to get placed at 0,0,0 anyway.

Basically, I perform:
Code:
ctrl.create(Capsule()))
    .pos(center)

The code above is executed at obj creation (based on Game::Chr). I can confirm that the initial position is non-zero.

Then in the first Chr::update() call, the controller's position displays zero, not the initial value.

Do you have any idea what could be reason why this is happening?
07-19-2013 11:12 PM
Visit this user's website Find all posts by this user Quote this message in a reply
aceio76 Offline
Silver Supporter

Post: #2
RE: Controller initial pos()
This is a sampling of what I'm getting from a capture of the logs from creation of the Chr obj:
Code:
CurTime (19.352), ObjSpawner::operator=(MobData) created new_mob startloc=119.602, 2.850, -63.535 actual_pos=119.602, 2.850, -63.535
CurTime (19.356), ObjMobChr::update action=0 cur_loc=35.881, 0.000, -19.061 active=0 paths=0
CurTime (19.365), ObjMobChr::update action=0 cur_loc=10.764, 0.337, -5.719 active=0 paths=0
CurTime (19.380), ObjMobChr::update action=0 cur_loc=3.230, -0.249, -1.715 active=0 paths=0
CurTime (19.396), ObjMobChr::update action=0 cur_loc=0.969, -0.425, -0.514 active=0 paths=0
CurTime (19.411), ObjMobChr::update action=0 cur_loc=0.291, -0.477, -0.154 active=0 paths=0
CurTime (19.427), ObjMobChr::update action=0 cur_loc=0.087, -0.493, -0.046 active=0 paths=0
CurTime (19.443), ObjMobChr::update action=0 cur_loc=0.026, -0.498, -0.014 active=0 paths=0
CurTime (19.458), ObjMobChr::update action=0 cur_loc=0.008, -0.499, -0.004 active=0 paths=0
CurTime (19.474), ObjMobChr::update action=0 cur_loc=0.002, -0.500, -0.001 active=0 paths=0
CurTime (19.489), ObjMobChr::update action=0 cur_loc=0.001, -0.500, -0.000 active=0 paths=0

CurTime shows the time elapsed in fractional seconds.

The ObjSpawner creates the new obj and confirms that the Obj ctrl.actor.pos() is at the intended location.

The repeating part of the logs are from Chr::update() calls. As you can see, the obj ctrl.actor.pos() is very rapidly moving towards 0.

There are no paths set, and UpdateController() is never called.

The newly created obj seem to very rapidly move towards 0, 0.5, 0 and I cannot determine what is causing it. There is literally no other calls I can capture in-between the update() calls.

Any insight to this is greatly appreciated.
07-20-2013 02:58 AM
Visit this user's website Find all posts by this user Quote this message in a reply
cmontiel Offline
Member

Post: #3
RE: Controller initial pos()
Try:

ctrl.actor.vel(Vec(0));
ctrl.actor.angVel(Vec(0));
07-20-2013 04:34 AM
Find all posts by this user Quote this message in a reply
aceio76 Offline
Silver Supporter

Post: #4
RE: Controller initial pos()
Unfortunately, the issue is something related to EE2.0 headers/libs with EE1.0 terrain (or something to that combination). Unfortunately I am stuck between versions since there isn't a "nice" way for me to use VS2012 with the various projects inside the same solution with shared code and use EE2.0 editor, etc. I've tried a few times to find a way to coexist with EE2.0 but there is always some compromise that I cannot commit to. I have no choice but to wait for EE1.0 to get updated with PhysX3.

In the meantime, using the latest 1.0 update allows me to continue without this problem.
(This post was last modified: 07-22-2013 02:24 PM by aceio76.)
07-22-2013 02:09 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #5
RE: Controller initial pos()
(07-19-2013 11:12 PM)aceio76 Wrote:  Hi Esenthel,

I am trying to troubleshoot an issue that I can't understand. When I perform ctrl.create() and set it an initial pos() location, the controller seems to get placed at 0,0,0 anyway.

Basically, I perform:
Code:
ctrl.create(Capsule()))
    .pos(center)

The code above is executed at obj creation (based on Game::Chr). I can confirm that the initial position is non-zero.

Then in the first Chr::update() call, the controller's position displays zero, not the initial value.

Do you have any idea what could be reason why this is happening?
Hello,

It would be great if you could attach a smallest possible project (preferrably 2.0) reproducing this issue.

Thank you
07-22-2013 08:00 PM
Find all posts by this user Quote this message in a reply
Post Reply