 |
|
Junior Member
|

06-30-2006
, 18:10
Re: Plugin For loading Multiple or Single Weapon skins/models
|
#11
|
Quote:
|
Originally Posted by k007
if you want it that hard i have simple one
Code:
#include <amxmodx>
#include <engine>
#include <fun>
new WEAPON1_MODEL_NAME[64] = "models/name/v_name.mdl" //model dir for the v
new WEAPON2_MODEL_NAME[64] = "models/name/p_name.mdl" /// model dir for the p_
public plugin_init(){
register_plugin("weapon","0.1","k007")
register_event("WeapPickup","checkModel","b","1=19")
register_event("CurWeapon","checkWeapon","be","1=1")
}
public plugin_precache(){
precache_model(WEAPON2_MODEL_NAME)
precache_model(WEAPON1_MODEL_NAME)
return PLUGIN_CONTINUE
}
public checkModel(id){
if (!is_user_alive(id)){
return PLUGIN_CONTINUE
}
entity_set_string(id, EV_SZ_viewmodel, WEAPON1_MODEL_NAME) // thats for v
entity_set_string(id, EV_SZ_weaponmodel, WEAPON2_MODEL_NAME) /// that for the p
new iCurrent
iCurrent = find_ent_by_class(-1,"weapon_name")
while(iCurrent != 0) {
iCurrent = find_ent_by_class(iCurrent,"weapon_weapon")
}
return PLUGIN_HANDLED
}
public checkWeapon(id){
new plrClip, plrAmmo, plrWeap[32]
new plrWeapId
plrWeapId = get_user_weapon(id, plrClip, plrAmmo)
if (plrWeapId == CSW_weapon name){
checkModel(id)
}
else {
return PLUGIN_CONTINUE
}
return PLUGIN_CONTINUE
}
this will make every one comes to your server download the weapon the v and p the w is realy hard 
|
so in that code, what do i edit
and when that other plugin is ready could you post that in here?
|
|
|
|