AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   [SOLVED] Spawning armoury_entity gives wrong weapon (https://forums.alliedmods.net/showthread.php?t=245664)

Kia 08-05-2014 10:07

[SOLVED] Spawning armoury_entity gives wrong weapon
 
Hello everybody,

I try to spawn a pick-up-able smoke grenade, but I always get a auto-sniper.
What am I doing wrong?

Code:
new iEnt = engfunc(EngFunc_CreateNamedEntity, engfunc(EngFunc_AllocString, "armoury_entity"))     new Float:flOrigin[3] flOrigin = g_flSpawnerPos[id]     flOrigin[1] += 20     set_pev(iEnt, pev_origin, flOrigin) set_pdata_int(iEnt, 34, CSW_SMOKEGRENADE, 4) set_pdata_int(iEnt, 35, 1, 4) set_pev(iEnt, pev_model, "models/w_smokegrenade.mdl")     ExecuteHamB(Ham_Spawn, iEnt)

meTaLiCroSS 08-05-2014 18:39

Re: Spawning armoury_entity gives wrong weapon
 
armoury_entity doesn't use CSW_ indexes. https://forums.alliedmods.net/showpo...5&postcount=19

Kia 08-06-2014 02:54

Re: Spawning armoury_entity gives wrong weapon
 
Thanks. :)


All times are GMT -4. The time now is 13:02.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.