Stworzyłem zatrute strzały i dodałem do assess_damege i niby działa ale jak jakiś npc dostaje strzałą to trucizna nie zabiera mu życia co chwilę oto fragmenty skryptów
if trucizna==true
&& czas_zatrucia!=5
{
other.attribute[ATR_HITPOINTS] = other.attribute[ATR_HITPOINTS] - zatrucie;
czas_zatrucia = czas_zatrucia+1;
PrintScreen (" trucizna on", -2, 81, FONT_Screensmall, 1000);// tym testuje że działa i to jest w tick tocku
};
a teraz z assess_damege
func void equip_bow_ammo (var C_NPC oth, var C_NPC slf)
{
if (Hlp_GetInstanceID(oth) == Hlp_GetInstanceID(hero))
{
var C_ITEM ready;
var c_item equip_bow;
equip_bow = Npc_GetEquippedrangedWeapon(self);
ready = Npc_GetReadiedWeapon(hero);
if (Npc_HasItems(hero, ItRw_Bow_L_01) == TRUE
&& Hlp_IsItem(ready, ItRw_Bow_L_01) == TRUE)
{
if (slf.flags != NPC_FLAG_IMMORTAL)
{
if ogniste == true
{
equip_bow.damagetype = DAM_fire;
B_MagicHurtNpc (other, self, 30);
Wld_PlayEffect("spellFX_Firestorm_SPREAD", other, self, 0, 0, 0, FALSE );
}
else if zatrute==true
{
trucizna=true;
czas_zatrucia=0;
}
else
{
};
};
}
else
{
equip_bow.damagetype = DAM_point;
};
if (Npc_HasItems(hero, ItRw_Bow_L_01) == TRUE
&& Hlp_IsItem(ready, ItRw_Bow_L_01) == TRUE)
{
};
};
};
i czemu życia mu nie zabiera ?