• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

[Release] Honor kill on NPC Kill

EpiNemx

Respected Member
What does this do?
This script adds a honorable kill (lifetime) upon killing monsters,
or a certain NPC in game and adds a PvP Title upon reaching amount of required kills.

Credits:
Foereaper - For the list of titles.
Tommy - For helping me and correcting the code to get it to work.

-- code temp removed, doesnt work properly.
 
Last edited:

Tommy

Founder
It won't work. I edited it to go by

TitleId/Kills/TeamId

So the table would have to look like:

Code:
local T =
{
    -- Alliance
    {1, 15, 0}, -- Private
    {2, 2000, 0}, -- Corporal
    {3, 5000, 0}, -- Sergeant
    {4, 10000, 0}, -- Master
    {5, 15000, 0}, -- Sergeant Major
    {6, 20000, 0}, -- Knight
    {7, 25000, 0}, -- Knight-Lieutenant
    {8, 30000, 0}, -- Knight-Captain
    {9, 35000, 0}, -- Knight-Champion
    {10, 40000, 0}, -- Lieutenant Commander
    {11, 45000, 0}, -- Commander
    {12, 50000, 0}, -- Marshal
    {13, 55000, 0}, -- Field Marshal
    {14, 60000, 0}, -- Grand Marshal
    {62, 75000, 0}, -- Warbringer
   -- Horde
   {15, 15, 1}, -- Scout
   {16, 2000, 1}, -- Grunt
   {17, 5000, 1}, -- Sergeant
   {18, 10000, 1}, -- Senior Sergeant
   {19, 15000, 1}, -- First Sergeant
   {20, 20000, 1}, -- Stone Guard
   {21, 25000, 1}, -- Blood Guard
   {22, 30000, 1}, -- Legionnaire
   {23, 35000, 1}, -- Centurion
   {24, 40000, 1}, -- Champion
   {25, 45000, 1}, -- Lieutenant General
   {26, 50000, 1}, -- General
   {27, 55000, 1}, -- Warlord
   {28, 60000, 1}, -- High Warlord
   {62, 75000, 1} -- Warbringer
}

You'd still have to store the NPC kills so it doesn't give you the title on each kill. The script doesn't go by kills considering there's no storage for it. :/
 

Foereaper

Founder
This wouldn't work;

if (killer:GetTeam() == T[k][3])

This points to the third field of the table structure, which in the original script is required honorable kills. A player's team cannot be 15 as an example :p
 

EpiNemx

Respected Member
After testing it indeed doesnt seem to work neither with your updates. On killing it gives me all the ranks instead of just one. I'll have a closer look into this and update it asap. :p
 

Tommy

Founder
After testing it indeed doesnt seem to work neither with your updates. On killing it gives me all the ranks instead of just one. I'll have a closer look into this and update it asap. :p

Because there isn't a check to see what the player's Lifetime kills are.

Code:
if (killer:GetLifetimeKills() >= T[k][2]) then
    -- Continue
 
Top