Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0006759opensim[REGION] Physics Enginespublic2013-09-04 17:412013-10-18 13:00
Reporterdahlia 
Assigned ToRobert Adams 
PrioritynormalSeverityblockReproducibilitysometimes
StatusassignedResolutionopen 
PlatformWindows/.NetOSWIndowsOS VersionWindows 8
Product Versionmaster (dev code) 
Target VersionFixed in Version 
Summary0006759: BulletSim: Newly created NPC fails to move unless a delay is added after creation when physics engine is BulletSim
DescriptionI have scripted NPCs which are created from script events. When the NPC is created it is instructed to move with osNpcMoveToTarget(). If I use the ODE physics engine, the NPC moves immediately after rezzing, just as the script is coded. When I use BulletSim, often the NPC fails to move (probably 80% failure) unless I add a small delay of 1 second after creating the NPC and before calling osNpcMoveToTarget(). I'm not sure if this is a potential problem with ODE as well, however I've never seen the problem when using ODE.
Steps To ReproduceCreate a NPC in a script, Immediately call osNpcMoveToTarget() within the same event that creates the NPC.
TagsNo tags attached.
Git Revision or version number
Run ModeStandalone (1 Region)
Physics EngineBulletSim
Script Engine
Environment.NET / Windows64
Mono VersionNone
ViewerSingularity
Attached Files

- Relationships

-  Notes
(0024310)
dz (reporter)
2013-09-05 10:22

I have seen similar behavior. Using a FLY_TO_TARGET option in the call results in fewer stuck NPC's, but it will still occur. Rezzing the NPC on/over a ramp can provide the required "nudge" to get the NPC moving.
I will add the script delay between functions to see if that works for me.
(0024529)
Robert Adams (administrator)
2013-10-18 13:00

I suspect this is part of a general problem in BulletSim where some operations are delayed from when the script call is made to the next simulation step time. Internally, BulletSim keeps some operations until the next simulation step so changes can be made when it knows the physics engine is not running (the 'taint' mechanism that is in both BulletSim and ODE).

The other place this problem shows up is scripted teleports within the same region. OpenSimulator implements this by destroying the physical avatar shape and then instantly recreating the shape in the new location. Part of the physical destruction and creation is done at script call time but the bulk of the work is done just before the next simulation step. So, things like parameter changes made between the teleport and the next simulation step may be lost.

BulletSim needs its internal architecture changed a bit to completely fix this problem.

- Issue History
Date Modified Username Field Change
2013-09-04 17:41 dahlia New Issue
2013-09-05 10:22 dz Note Added: 0024310
2013-10-18 09:26 Robert Adams Assigned To => Robert Adams
2013-10-18 09:26 Robert Adams Status new => assigned
2013-10-18 12:11 aiaustin Summary Newly created NPC fails to move unless a delay is added after creation when physics engine is BulletSim => BulletSim: Newly created NPC fails to move unless a delay is added after creation when physics engine is BulletSim
2013-10-18 13:00 Robert Adams Note Added: 0024529


Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker