542 {
544 {
546 if (entity)
548 else
550
551 InventoryItem item;
552 if (Class.CastTo(item, entity) && withPhysics)
553 item.ThrowPhysically(null, "0 0 0");
554
555 return entity;
556 }
557 else
558 {
559 Param6<string, float, float, vector, bool, bool> params = new Param6<string, float, float, vector, bool, bool>(item_name, health, quantity, pos, special, withPhysics);
560 player.RPCSingleParam(
ERPCs.DEV_RPC_SPAWN_ITEM_ON_GROUND, params,
true);
561 }
562 return NULL;
563 }
void OnSpawnErrorReport(string name)
EntityAI SpawnEntityOnGroundPos(PlayerBase player, string object_name, vector pos)
void SetupSpawnedEntity(PlayerBase player, EntityAI entity, float health, float quantity=-1, bool special=false, string presetName="")