public virtual void ApplyImpulse(idEntity entity, int id, Vector3 point, Vector3 impulse) { if (this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idEntity.ApplyImpulse"); }
public virtual void Teleport(Vector3 origin, idAngles angles, idEntity destination) { if (this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idEntity.Teleport"); }
/// <summary> /// /// </summary> /// <param name="inflictor">Entity that is causing the damage.</param> /// <param name="attacker">Entity that caused the inflictor to cause damage to us.</param> /// <param name="direction">Direction of the attack for knockback in global space.</param> /// <param name="damageDefName"></param> /// <param name="damageScale"></param> /// <param name="location"></param> public virtual void Damage(idEntity inflictor, idEntity attacker, Vector3 direction, string damageDefName, float damageScale, int location) { if (this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idEntity.Damage"); }
public virtual object GetImpactInfo(idEntity entity, int id, Vector3 point) { if (this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idEntity.GetImpactInfo"); return(null); }
/// <summary> /// /// </summary> /// <remarks> /// May not change the game state whatsoever! /// </remarks> /// <param name="renderEntity"></param> /// <param name="renderView"></param> /// <returns></returns> protected bool ModelCallback(idRenderEntity renderEntity, idRenderView renderView) { idEntity ent = idR.Game.Entities[renderEntity.EntityIndex]; if (ent == null) { idConsole.Error("idEntity::ModelCallback: callback with null game entity"); } return(ent.UpdateRenderEntity(renderEntity, renderView)); }
public virtual void ApplyImpulse(idEntity entity, int id, Vector3 point, Vector3 impulse) { if(this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idEntity.ApplyImpulse"); }
public void RemoveContactEntity(idEntity entity) { this.Physics.RemoveContactEntity(entity); }
public void AddContactEntity(idEntity entity) { this.Physics.AddContactEntity(entity); }
/// <summary> /// Activate the physics object. /// </summary> /// <param name="entity">Entity activating us.</param> public void ActivatePhysics(idEntity entity) { this.Physics.Activate(); }
/// <summary> /// Called whenever an entity recieves damage. Returns whether the entity responds to the pain. /// </summary> /// <param name="inflictor"></param> /// <param name="attacker"></param> /// <param name="damage"></param> /// <param name="direction"></param> /// <param name="location"></param> /// <returns></returns> public virtual bool Pain(idEntity inflictor, idEntity attacker, int damage, Vector3 direction, int location) { return(false); }
public override bool HandleSingleGuiCommand(idEntity entityGui, Text.idLexer lexer) { if(this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idPlayer.HandleSingleGuiCommand"); return false; }
public override void Damage(idEntity inflictor, idEntity attacker, Vector3 direction, string damageDefName, float damageScale, int location) { if(this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idPlayer.Damage"); }
/// <summary> /// Searches all active entities for the next one using the specified entityDef. /// </summary> /// <remarks> /// Searches beginning at the entity after from, or the beginning if NULL /// NULL will be returned if the end of the list is reached. /// </remarks> /// <param name="from"></param> /// <param name="match"></param> /// <returns></returns> public idEntity FindEntityUsingDef(idEntity from, string match) { int index = 0; if(from != null) { index = _spawnedEntities.IndexOf(from); if(index == -1) { index = 0; } } int count = _spawnedEntities.Count; string matchLower = match.ToLower(); for(int i = index; i < count; i++) { idEntity ent = _spawnedEntities[i]; if(ent.DefName.ToLower() == matchLower) { return ent; } } return null; }
/// <summary> /// Callback function for when another entity received damage from this entity. damage can be adjusted and returned to the caller. /// </summary> /// <param name="victim"></param> /// <param name="inflictor"></param> /// <param name="damage"></param> public virtual void DamageFeedback(idEntity victim, idEntity inflictor, ref int damage) { }
public virtual object GetImpactInfo(idEntity entity, int id, Vector3 point) { if(this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idEntity.GetImpactInfo"); return null; }
public void RegisterEntity(idEntity entity) { int entitySpawnIndex; if(_spawnCount >= (1 << (32 - idR.GameEntityBits))) { idConsole.Error("idGameLocal.RegisterEntity: spawn count overflow"); } if(_spawnArgs.ContainsKey("spawn_entnum") == true) { entitySpawnIndex = _spawnArgs.GetInteger("spawn_entnum", 0); } else { while((_entities[_firstFreeIndex] != null) && (_firstFreeIndex < idR.EntityCountNormalMax)) { _firstFreeIndex++; } if(_firstFreeIndex >= idR.EntityCountNormalMax) { idConsole.Error("no free entities"); } entitySpawnIndex = _firstFreeIndex++; } _entities[entitySpawnIndex] = entity; _spawnIds[entitySpawnIndex] = _spawnCount++; entity.Index = entitySpawnIndex; entity.SpawnArgs.TransferKeyValues(_spawnArgs); _spawnedEntities.Add(entity); if(entitySpawnIndex >= _entityCount) { _entityCount++; } }
public virtual bool HandleSingleGuiCommand(idEntity entityGui, idLexer lexer) { return false; }
public override void DamageFeedback(idEntity victim, idEntity inflictor, ref int damage) { if(this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idPlayer.GetAASLocation"); }
/// <summary> /// Called whenever an entity recieves damage. Returns whether the entity responds to the pain. /// </summary> /// <param name="inflictor"></param> /// <param name="attacker"></param> /// <param name="damage"></param> /// <param name="direction"></param> /// <param name="location"></param> /// <returns></returns> public virtual bool Pain(idEntity inflictor, idEntity attacker, int damage, Vector3 direction, int location) { return false; }
/// <summary> /// /// </summary> /// <remarks> /// Use exitEntityNum to specify a teleport with private camera view and delayed exit. /// </remarks> /// <param name="origin"></param> /// <param name="angles"></param> /// <param name="destination"></param> public override void Teleport(Vector3 origin, idAngles angles, idEntity destination) { if(this.Disposed == true) { throw new ObjectDisposedException(this.GetType().Name); } idConsole.Warning("TODO: idPlayer.Teleport"); }
public virtual bool HandleSingleGuiCommand(idEntity entityGui, idLexer lexer) { return(false); }