Professional Documents
Culture Documents
Aa 1
Aa 1
dl")
}
}
//--------------------------------------------------------------------------------------------public weaponChange(id)
{
if ( !gHasArcPredPowers[id] || !shModActive() )
return
new wpnid = read_data(2)
if ( wpnid != CSW_AWP && wpnid != CSW_KNIFE && wpnid != CSW_SCOUT )
return
switchgun(id)
new clip = read_data(3)
// Never Run Out of Ammo!
if ( clip == 0 )
shReloadAmmo(id)
}
//--------------------------------------------------------------------------------------------public arcticpredator_damage(id)
{
if ( !shModActive() || !is_user_alive(id) ) return
new damage = read_data(2)
new weapon, bodypart, attacker = get_user_attacker(id, weapon, bodypart)
new headshot = bodypart == 1 ? 1 : 0
if ( attacker <= 0 || attacker > SH_MAXSLOTS ) return
if ( gHasArcPredPowers[attacker] && weapon == CSW_SCOUT && is_user_alive(id)
) {
// do extra damage
new extraDamage = floatround(damage * get_cvar_float("arcticpredator_sco
utmult") - damage)
if (extraDamage > 0) shExtraDamage(id, attacker, extraDamage, "scout", h
eadshot)
}
else if(gHasArcPredPowers[attacker] && weapon == CSW_AWP && is_user_alive(id
) ){
new extraDamage = floatround(damage * get_cvar_float("arcticpredator_awp
mult") - damage)
if(extraDamage > 0) shExtraDamage(id, attacker, extraDamage, "awp", head
shot)
}
else if(gHasArcPredPowers[attacker] && weapon == CSW_KNIFE && is_user_alive(
id) ){
new extraDamage = floatround(damage * get_cvar_float("arcticpredator_kni
femult") - damage)
if(extraDamage > 0) shExtraDamage(id, attacker, extraDamage, "knife", he
adshot)
}
}
//--------------------------------------------------------------------------------------------pred_Morph(id)
{
if ( gmorphed[id] || !is_user_alive(id) || !gHasArcPredPowers[id] )
return
if ( gHasArcPredPowers[id] == true && is_user_connected(id) )
{
if ( get_user_team(id) ==
{
cs_set_user_model(id,
}
if ( get_user_team(id) ==
{
cs_set_user_model(id,
}
1 )
"arcpredct")
2 )
"arcpred")
}
// Message
set_hudmessage(50, 205, 50, -1.0, 0.40, 2, 0.02, 4.0, 0.01, 0.1, 7)
show_hudmessage(id, "Arctic Predator - Are you gonna give me orders?!")
gmorphed[id] = true
}
//--------------------------------------------------------------------------------------------public arcticpredator_unmorph(id)
{
if ( gmorphed[id] && is_user_connected(id) )
{
if ( is_user_alive(id) )
{
// Message
set_hudmessage(50, 205, 50, -1.0, 0.40, 2, 0.02, 4.0, 0.01, 0.1, 7)
show_hudmessage(id, "Arctic Predator - T_T")
}
cs_reset_user_model(id)
gmorphed[id] = false
}
}
//--------------------------------------------------------------------------------------------//--------------------------------------------------------------------------------------------public arcticpredator_death()
{
new id = read_data(2)
if ( !gHasArcPredPowers[id] )
return
arcticpredator_unmorph(id)
}
//--------------------------------------------------------------------------------------------public client_connect(id)
{
gmorphed[id] = false
gHasArcPredPowers[id] = false
}
//---------------------------------------------------------------------------------------------