Mapster
Newbie
- Joined
- Feb 16, 2005
- Messages
- 357
- Reaction score
- 0
Hey all,
I've been working on a mod for half-life 2 in secret for a couple months now with a couple problems which I've been able to overcome via tutorials and other help adds around, but this error just keeps coming back and biting me in the *** every time.
The entity in the .fgd is a modified version of the item_item_crate but with 2 Item Classes to spawn instead of 2 so someone and input 2 different items which the crate can spawn when it's broken instead of 1, .fgd code below.
In the code I've run a loop when spawning the items class string which checks if the item spawning is not "NULL_STRING" then it will spawn the item... but regardless it still tries to spawn the item and gives me an error saying "Unable to create unknown entity 0" when someone chooses the option "Skip" in hammer.
Anyone else come across the error before and know how to fix it?
Cheers,
Mapster
I've been working on a mod for half-life 2 in secret for a couple months now with a couple problems which I've been able to overcome via tutorials and other help adds around, but this error just keeps coming back and biting me in the *** every time.
The entity in the .fgd is a modified version of the item_item_crate but with 2 Item Classes to spawn instead of 2 so someone and input 2 different items which the crate can spawn when it's broken instead of 1, .fgd code below.
@PointClass base(BasePropPhysics, Targetname, Angles, DamageFilter, BaseFadeProp) studio("models/items/item_item_crate.mdl") = item_item_crate : "Item Crate"
[
ItemClass(choices) : "Item Type #1" : "item_dynamic_resupply" : "Class name of the random entity to spawn ( 'Skip' will set self to 0 on
selection )" =
[
"0" : "Skip"
"item_ammo_357" : "item_ammo_357"
"item_ammo_ar2" : "item_ammo_ar2"
"item_ammo_ar2_altfire" : "item_ammo_ar2_altfire"
"item_ammo_crossbow" : "item_ammo_crossbow"
"item_ammo_pistol" : "item_ammo_pistol"
"item_ammo_smg1" : "item_ammo_smg1"
"item_ammo_smg1_grenade" : "item_ammo_smg1_grenade"
"item_battery" : "item_battery"
"item_box_buckshot" : "item_box_buckshot"
"item_healthkit" : "item_healthkit"
"item_healthvial" : "item_healthvial"
"item_item_rpg_round" : "item_rpg_round"
"item_dynamic_resupply" : "item_dynamic_resupply"
"item_battery" : "item_battery"
"weapon_357" : "weapon_357"
"weapon_ar2" : "weapon_ar2"
"weapon_crossbow" : "weapon_crossbow"
"weapon_crowbar" : "weapon_crowbar"
"weapon_frag" : "weapon_frag"
"weapon_physcannon" : "weapon_physcannon"
"weapon_pistol" : "weapon_pistol"
"weapon_rpg" : "weapon_rpg"
"weapon_shotgun" : "weapon_shotgun"
"weapon_smg1" : "weapon_smg1"
]
ItemCount(integer) : "Item Count #1" : 1 : "Number of items to emit upon breakage"
SpecificResupply(target_destination) : "Specific resupply #1" : "" : "If item type is item_dynamic_resupply, specify a specific one to use
instead of the master"
ItemClass2(choices) : "Item Type #2" : "0" : "Class name of the random entity to spawn ( 'Skip' will set self to 0 on selection )" =
[
"0" : "Skip"
"item_ammo_357" : "item_ammo_357"
"item_ammo_ar2" : "item_ammo_ar2"
"item_ammo_ar2_altfire" : "item_ammo_ar2_altfire"
"item_ammo_crossbow" : "item_ammo_crossbow"
"item_ammo_pistol" : "item_ammo_pistol"
"item_ammo_smg1" : "item_ammo_smg1"
"item_ammo_smg1_grenade" : "item_ammo_smg1_grenade"
"item_battery" : "item_battery"
"item_box_buckshot" : "item_box_buckshot"
"item_healthkit" : "item_healthkit"
"item_healthvial" : "item_healthvial"
"item_item_rpg_round" : "item_rpg_round"
"item_dynamic_resupply" : "item_dynamic_resupply"
"item_battery" : "item_battery"
"weapon_357" : "weapon_357"
"weapon_ar2" : "weapon_ar2"
"weapon_crossbow" : "weapon_crossbow"
"weapon_crowbar" : "weapon_crowbar"
"weapon_frag" : "weapon_frag"
"weapon_physcannon" : "weapon_physcannon"
"weapon_pistol" : "weapon_pistol"
"weapon_rpg" : "weapon_rpg"
"weapon_shotgun" : "weapon_shotgun"
"weapon_smg1" : "weapon_smg1"
]
ItemCount2(integer) : "Item Count #2" : 0 : "Number of items to emit upon breakage"
SpecificResupply2(target_destination) : "Specific resupply #2" : "" : "If item type is item_dynamic_resupply, specify a specific one to use
instead of the master"
]
In the code I've run a loop when spawning the items class string which checks if the item spawning is not "NULL_STRING" then it will spawn the item... but regardless it still tries to spawn the item and gives me an error saying "Unable to create unknown entity 0" when someone chooses the option "Skip" in hammer.
Anyone else come across the error before and know how to fix it?
Cheers,
Mapster