So i would add that right under this?
void main()
{
object oDamager = GetLastDamager();
int nWaypoint;
object oWaypoint;
<----------------------
Current script edited by bargg with nothing new....................................
#include "i420_s_inc_pstat"
void BuffDamager(object oDamager)
{
SetPCKillStats(oDamager, OBJECT_SELF);
effect eHeal = EffectHeal(1);
effect eHaste = (EffectHaste());
effect eStr = (EffectAbilityIncrease(ABILITY_STRENGTH, 1));
effect eVis = (EffectVisualEffect(VFX_DUR_GLOW_RED));'
ApplyEffectToObject(DURATION_TYPE_INSTANT, eHeal, oDamager);
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eVis, oDamager);
if (d100() > 50)ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eHaste, oDamager, 30.0);
}
void main()
{
object oDamager = GetLastDamager();
int nWaypoint;
object oWaypoint;
if ((GetIsPC(oDamager)) && (GetIsPossessedFamiliar(oDamager) == FALSE))
{
CreateItemOnObject("",oDamager,1); //need to add somethings resref here?
if (GetTimeHour() == 0)
{ //need to add somethings resref here?
CreateItemOnObject("",oDamager,1);
}
}
nWaypoint = 0;
oWaypoint = GetFirstObjectInArea();
while( GetIsObjectValid( oWaypoint))
{
if( GetObjectType( oWaypoint) == OBJECT_TYPE_WAYPOINT)
{
if( GetTag( oWaypoint) == GetTag( OBJECT_SELF))
{
++nWaypoint;
}
}
oWaypoint = GetNextObjectInArea();
}
/*if( nWaypoint <= 0)
{
nWaypoint = Random( nWaypoint) + 1;
}
while( GetIsObjectValid( oWaypoint))
{ if( GetObjectType( oWaypoint) == OBJECT_TYPE_WAYPOINT)
{ if( GetTag( oWaypoint) == GetTag( OBJECT_SELF))
{ if( (--nWaypoint) <= 0)
{ CreateObject( OBJECT_TYPE_CREATURE, GetResRef ( OBJECT_SELF), GetLocation( oWaypoint));
return;
}
}
}
oWaypoint = GetNextObjectInArea();*/
BuffDamager( oDamager );
//}
}
Modifié par Builder_Anthony, 23 août 2011 - 04:03 .