I need the command to give experience on death. Anyone know what it is?
Need to get EXP on kill
Débuté par
Asmius
, juil. 01 2011 02:38
#1
Posté 01 juillet 2011 - 02:38
#2
Posté 01 juillet 2011 - 03:08
The command (function) is RewardPartyXP (#include "nw_i0_tool") and GiveXPToCreature.
That's what you were looking for, right? Or did you want to give xp on the OnDeath of some creature?
That's what you were looking for, right? Or did you want to give xp on the OnDeath of some creature?
#3
Posté 01 juillet 2011 - 03:24
hrm..
I was using RewardPartyXP(1, oPC, TRUE); but it siad that 'RewardPartyXP' was invalid.
I was using RewardPartyXP(1, oPC, TRUE); but it siad that 'RewardPartyXP' was invalid.
#4
Posté 01 juillet 2011 - 03:28
I want the experience to go to the kilelr, btw.
#5
Posté 01 juillet 2011 - 09:18
RewardPartyXP is not a default function, and as mwplayer said, you must include a script so you can use it.
( #include "nw_i0_tool" )
Put that before void main()
This command gives XP to a whole party.
GiveXPToCreature is a default function, and thus you need not include anything. It only gives XP to a single creature at a time though.
( #include "nw_i0_tool" )
Put that before void main()
This command gives XP to a whole party.
GiveXPToCreature is a default function, and thus you need not include anything. It only gives XP to a single creature at a time though.
Modifié par Xardex, 01 juillet 2011 - 09:20 .
#6
Posté 01 juillet 2011 - 08:43
Something like this in the creatures OnDeath:
void main()
{
object oPC = GetLastKiller();
if (GetIsObjectValid(GetMaster(oPC)))
{
oPC = GetMaster(oPC);
}
GiveXPToCreature(oPC, 100);
}
void main()
{
object oPC = GetLastKiller();
if (GetIsObjectValid(GetMaster(oPC)))
{
oPC = GetMaster(oPC);
}
GiveXPToCreature(oPC, 100);
}
#7
Posté 04 juillet 2011 - 04:16
But take care, if your xp rate is not at 0, it will give extra xp to the killer and normal xp to the group.





Retour en haut






