AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   finding an entity's index and execute a command on it (https://forums.alliedmods.net/showthread.php?t=20467)

haimmaik 11-09-2005 06:43

finding an entity's index and execute a command on it
 
how do i find the index of the entity - "EV_SZ_viewmodel" of player "id" and execute - set_rendering(index,....) on it? :\
can u write an example here?

Hawk552 11-09-2005 06:49

Code:
#define model "YOUR MODEL GOES HERE" new ent; while((ent = find_ent_by_model(ent,"player",model)) != 0) {     set_rendering( //... }

I guess...?

jtp10181 11-09-2005 06:52

the index of the entity is the "id" and you don't need to do anything goofy with engine to change rendering on a payer.

http://www.amxmodx.org/funcwiki.php?go=func&id=119

if you use "kRenderTransAlpha" for the mode, the last number sets the alpha blend (transparency)

haimmaik 11-09-2005 07:22

1 Attachment(s)
i need to find the EV_SZ_viewmodel model.. not my player model...

EV_SZ_viewmodel is the model of my hands holding the weapon (client side) the other players cannot see that.

the model - "models/v_knife.mdl" actually i only need the class of this
v_ models... (its not "player")

XxAvalanchexX 11-09-2005 13:54

News flash: you can't!

jtp10181 11-09-2005 20:08

it doesn't have an entity id, its a setting of the player entity. You can change that model for a certian player, possibly making it blank would make it go away.


All times are GMT -4. The time now is 23:35.

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