Jump to content
  • 0

Help me with this script.


Zayn Anthony

Question


  • Group:  Members
  • Topic Count:  11
  • Topics Per Day:  0.00
  • Content Count:  18
  • Reputation:   0
  • Joined:  04/20/17
  • Last Seen:  

can you help me with this script instead of PLAYERS NAME can you change it to PARTY NAME every time the party kill an MVP monster.


-    script    Test    -1,{

OnNPCKillEvent:

setarray .mobid[0],1039,1046,1059,1086,1087,1096,1112,1115,1120,1147,1150,1157,1159,1190,1251,1252,1272,1312,1373,1388,1389,1418,1492,1511,1582,1583,1623,1630,1658,1685,1688,1708,1719,1734,1751,1768,1779,1785,1832,1871,1873,1885,2022,1096,1873,1830,1839,1307,1283,1302,1582,1093,1205,1783,1681,1120,1259,1626,1720,1920,1918,1921,1919,1833,1090,1289,1262,1203,1870,1700,1295,1320,1702,1831,1701,1755,1754,1703,1829,1710,1705,1707,1712,1711,1706,1704,1709,1204,1089,1092,1765; // Add MvP Ids

set .a, 1;

for (set .@c, 0; .@c < getarraysize(.mobid); set .@c, .@c + 1)

if (killedrid == .mobid[.@c])

set .@s, 1;

if (!.@s) end;

if (.a)

if (getgmlevel() >= 1) {

announce "[ GM ] "+strcharinfo(0)+" has killed MVP Monster named [ "+getmonsterinfo(killedrid,0)+" ] which located at the map of [ "+strcharinfo(3)+" ]",0;

end;

}

}
Edited by Cyro
USE CODE BOX
Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10015
  • Reputation:   2351
  • Joined:  10/28/11
  • Last Seen:  

if (getgmlevel() >= 1) {
announce "[ GM ] "+strcharinfo(0)+" has killed MVP Monster named [ "+getmonsterinfo(killedrid,0)+" ] which located at the map of [ "+strcharinfo(3)+" ]",0;
end;
}

change to

if (getgmlevel() >= 1) {
	announce "[ GM ] "+strcharinfo(0)+" has killed MVP Monster named [ "+getmonsterinfo(killedrid,0)+" ] which located at the map of [ "+strcharinfo(3)+" ]",0;
	end;
}
else if ( getcharid(1) ) {
	announce "[ Party ] "+strcharinfo(1)+" has killed MVP Monster named [ "+getmonsterinfo(killedrid,0)+" ] which located at the map of [ "+strcharinfo(3)+" ]",0;
	end;
}

 

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  8
  • Topics Per Day:  0.00
  • Content Count:  1137
  • Reputation:   290
  • Joined:  04/29/13
  • Last Seen:  

-    script    Test    -1,{

OnNPCKillEvent:

setarray .mobid[0],1039,1046,1059,1086,1087,1096,1112,1115,1120,1147,1150,1157,1159,1190,1251,1252,1272,1312,1373,1388,1389,1418,1492,1511,1582,1583,1623,1630,1658,1685,1688,1708,1719,1734,1751,1768,1779,1785,1832,1871,1873,1885,2022,1096,1873,1830,1839,1307,1283,1302,1582,1093,1205,1783,1681,1120,1259,1626,1720,1920,1918,1921,1919,1833,1090,1289,1262,1203,1870,1700,1295,1320,1702,1831,1701,1755,1754,1703,1829,1710,1705,1707,1712,1711,1706,1704,1709,1204,1089,1092,1765; // Add MvP Ids

set .a, 1;

for (set .@c, 0; .@c < getarraysize(.mobid); set .@c, .@c + 1)

if (killedrid == .mobid[.@c])

set .@s, 1;

if (!.@s) end;

if (.a)
 if ( getcharid(1) ) {
  
if (getgmlevel() >= 1) {

 announce "Party ["+ strcharinfo(1) +"] has killed "+ getmonsterinfo( killedrid, MOB_NAME ) +"at "+ strcharinfo(3),0,0x00FF00;   
}
  else {
        if (getgmlevel() >= 1)
        announce "GM ["+ strcharinfo(0) +"] has killed "+ getmonsterinfo( killedrid, MOB_NAME ) +" at "+ strcharinfo(3),0,0x00FF00; }
end;

}

}

 

Edited by Cyro
fixed the party along with existing gm kill announcement
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...