![](images/misc/post_spacer.gif) |
Senior Member
Join Date: Feb 2009
Location: Russian Federation
|
![Old](images/statusicon/post_old.svg)
08-09-2009
, 02:42
Re: [ZP] Extra Item: Sawn-Off Shotgun v0.2
|
#17
|
Quote:
Originally Posted by Exolent[jNr]
That's not the problem.
The problem is the code:
PHP Code:
public fw_Touch(entity, toucher)
{
// Entity is not valid
if(!pev_valid(entity))
return FMRES_IGNORED;
// Get model, toucher classname, and entity classname
new model[33], toucherclass[33], entityclass[33]
pev(entity, pev_model, model, charsmax(model))
pev(entity, pev_classname, entityclass, charsmax(entityclass))
pev(toucher, pev_classname, toucherclass, charsmax(toucherclass))
if(!equali(toucherclass, "player") || !equali(entityclass, "weaponbox"))
return FMRES_IGNORED;
if(equali(model, sawnoff_model_w))
if(allowed_touch(toucher))
g_sawnoff_shotgun[toucher] = true;
return FMRES_IGNORED;
}
Line 218:
PHP Code:
pev(toucher, pev_classname, toucherclass, charsmax(toucherclass))
Should be:
PHP Code:
public fw_Touch(entity, toucher)
{
// Entity is not valid
if(!pev_valid(entity) || !pev_valid(toucher))
return FMRES_IGNORED;
// Get model, toucher classname, and entity classname
new model[33], toucherclass[33], entityclass[33]
pev(entity, pev_model, model, charsmax(model))
pev(entity, pev_classname, entityclass, charsmax(entityclass))
pev(toucher, pev_classname, toucherclass, charsmax(toucherclass))
if(!equali(toucherclass, "player") || !equali(entityclass, "weaponbox"))
return FMRES_IGNORED;
if(equali(model, sawnoff_model_w))
if(allowed_touch(toucher))
g_sawnoff_shotgun[toucher] = true;
return FMRES_IGNORED;
}
|
Thank you! I would test!
__________________
Sorry for my bad English.
|
|
|
|