void entity_OnPositionChanged(Common.Components.MyPositionComponentBase entity) { DetectedEntityInfo info; if (m_detectedEntities.TryGetValue(entity.Entity as MyEntity, out info)) { info.Moved = true; } }
void PositionComp_OnPositionChanged(Common.Components.MyPositionComponentBase obj) { //if (m_collidingEntities.ContainsKey((MyEntity)obj.Entity)) //{ // if (m_frameCounter - m_collidingEntities[(MyEntity)obj.Entity].FrameTime > 20) // { //Object not contacted with grid for 20 frames // obj.OnPositionChanged -= PositionComp_OnPositionChanged; // DynamicWeights.Remove(m_collidingEntities[(MyEntity)obj.Entity].Position); // m_collidingEntities.Remove((MyEntity)obj.Entity); // ForceRecalc = true; // } //} }