game_player_equip and 9mmAR problems Created 8 years ago2016-02-03 08:36:53 UTC by Dallas Dallas

Created 8 years ago2016-02-03 08:36:53 UTC by Dallas Dallas

Posted 8 years ago2016-02-03 08:36:53 UTC Post #328638
I'm having trouble giving the player a 9mmAR with the game_player_equip.

Every other weapon seems to work fine with the game_player_equip, but the weapon_9mmAR will not equip for me.

The problem, best I can tell, is that the weapon_9mmAR entry in my game_player_equip is saved to the .rmf WITHOUT the "AR" capitalized as just "weapon_9mmar."

If I edit the compiled .BSP in a text editor and change the "ar" to "AR" then the weapon adds fine from the game_player_equip.

Does anyone know of a better workaround for this that is less hacky?
Posted 8 years ago2016-02-03 11:58:46 UTC Post #328640
Use weapon_mp5 instead of weapon_9mmAR.

Reason it works? The 9mmAR is linked to two different entity names in the game code:
LINK_ENTITY_TO_CLASS( weapon_mp5, CMP5 );
LINK_ENTITY_TO_CLASS( weapon_9mmAR, CMP5 );
Oskar Potatis Oskar Potatis🦔
Posted 8 years ago2016-02-03 14:25:20 UTC Post #328643
ooh neat. Perfect.

Thanks!
Posted 8 years ago2016-02-03 20:35:40 UTC Post #328647
In Gold Source, entities names are case sensitive like Linux.

For Windows, a and A are the same.
For GoldSource and Linux, a and A are different.
Posted 8 years ago2016-02-03 23:53:47 UTC Post #328651
if it doesnt work when you cheat and type 'give weapon_9mmar' then it wont work there
Posted 8 years ago2016-02-08 08:28:09 UTC Post #328771
So, I've run into one major issue with my game_player_equip's -

They don't work after the player has loaded from save. I only need them to be a one shot deal - they only get triggered 1 time in the map.

...But if the player hits the trigger that targets my game_player_equip after a load, the equip never fires (the trigger does, as other things happen).

Anyone have a workaround? I'm stumped.
You must be logged in to post a response.