AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Change player models w/o cs_set_user_model (https://forums.alliedmods.net/showthread.php?t=54257)

djmd378 04-21-2007 03:19

Change player models w/o cs_set_user_model
 
Is it possible to change player models in cs1.6 without using cs_set_user_model? I know that I can use fakemeta to change players weapon models but I can't figure out how to make it change the player models. I REALLY don't want to use cs_set_user_model and have to include cstrike just for 2 lines of coding into my script that I'm working on.

Thanks for any help.

Ryu2877 04-21-2007 03:51

Re: Change player models w/o cs_set_user_model
 
Quote:

EngFunc_SetClientKeyValue, // void ) (int clientIndex, char *infobuffer, char *key, char *value);
try that

djmd378 04-21-2007 13:48

Re: Change player models w/o cs_set_user_model
 
That works, just that it resets every round. Oh wells at lest I got rid of cstrike.inc :)

Ty.

kp_uparrow 08-04-2007 03:25

Re: Change player models w/o cs_set_user_model
 
does this dump server sometimes? like cs set user model?

Fredd 08-04-2007 05:18

Re: Change player models w/o cs_set_user_model
 
for example the usage cs_set_user_model(id, "zombie")
that would set the user model to the hl1 zombie model, if u have ur own models and u wanna use them then precashe them, and name the path for example the model name was sexy.mdl make sure the folder called sexy under \models\player\ that how it works for me :)

Doc-Holiday 08-05-2007 14:27

Re: Change player models w/o cs_set_user_model
 
maybe try calling that code at the begining of every round. the code below is vens tut on getting player spawn. in code tuts and w/e the other word is :)
try it it might work.

Code:

#define MAX_PLAYERS 32
new bool:g_restart_attempt[MAX_PLAYERS + 1]
 
public plugin_init() {
register_event("ResetHUD", "event_hud_reset", "be")
register_clcmd("fullupdate", "clcmd_fullupdate")
register_event("TextMsg", "restart_attempt", "a", "2=#Game_will_restart_in")
}
 
public clcmd_fullupdate() {
  return PLUGIN_HANDLED_MAIN
}
 
public restart_attempt() {
  new players[32], num
  get_players(players, num, "a")
  for (new i; i < num; ++i)
g_restart_attempt[players[i]] = true
}
 
public event_hud_reset(id) {
  if (g_restart_attempt[id]) {
g_restart_attempt[id] = false
return
  }
player_spawn(id)
}
 
// this function is called on player spawn
public player_spawn(id) {
// code for player model goes here



_Master_ 08-06-2007 03:14

Re: Change player models w/o cs_set_user_model
 
Cstrike module uses prethink to "keep" the new model after a new round. This is somehow a code overhead and you could use the new round as NcB_Sav said.

Doc-Holiday 08-06-2007 03:30

Re: Change player models w/o cs_set_user_model
 
WOOT I GOT ONE RIGHT!!!

kp_uparrow 08-06-2007 16:02

Re: Change player models w/o cs_set_user_model
 
ok what? how you set a model with this? never seen something in such form:

EngFunc_SetClientKeyValue, // void ) (int clientIndex, char *infobuffer, char *key, char *value);

Doc-Holiday 08-06-2007 19:30

Re: Change player models w/o cs_set_user_model
 
why dont u just use set_user_model?


All times are GMT -4. The time now is 20:53.

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