Jump to content
  • 0

Script Requests


Ninjamon

Question


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   2
  • Joined:  03/06/12
  • Last Seen:  

Can anyone help me about these scripts?

 

*Broadcast when mvp is pawned

*A custom warper that verify if you own the kriemhild castle he will warp you to a specific map

*Npc Daily Rewarder (1 Per IP)

 

Link to comment
Share on other sites

13 answers to this question

Recommended Posts


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

1. announce MVP when pawned

OnNPCKillEvent:
if( getmonsterinfo( killedrid,MOB_MVPEXP ) )
	announce strcharinfo(0)+" killed "+getmonsterinfo( killedrid,MOB_NAME ),0;
end;

 

2. verify castle + warp

if( getcastledata( "prtg_cas01",1 ) == getcharid(2) ){
	warp "prontera",155,181;
}

 

 

3. search the forum...got a few examples for daily reward....

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   2
  • Joined:  03/06/12
  • Last Seen:  

I am using the mvp announce which i found on eathena.

-	script	Announce	-1,{
OnNPCKillEvent: 
setarray .MVPID[0],1511,1647,1785,1630,1399,1039,1874,2068,1272,1719,1046,1389,1112,1115,1957,1418,1871,1252,1768,1086,1688,1646,1373,1147,1059,1150,1956,2022,1087,1190,1038,1157,1159,1502,1623,1650,1583,1708,1312,1751,1685,1648,1917,1658,1734;

for (set .@c, 0; .@c < getarraysize(.MVPID); set .@c, .@c + 1)
    if (killedrid == .MVPID[.@c])
        set .@s, 1; 
        
if (!.@s) end;
announce "[  " +strcharinfo(0) +"  ] has pawned the Legendary [ " +getmonsterinfo(killedrid,0) +" ]. Reward: [ Event Ticket x2 ].",0,0xDA70D6;
getitem 7711,2;
end;
}

 

Now the problem is how can i add a reward to your script and change the colors of the broadcast? Thanks :D



up



How can i make that announce to broadcast it only to your self. It means only you can see the broadcast.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  382
  • Reputation:   38
  • Joined:  01/17/12
  • Last Seen:  

Now the problem is how can i add a reward to your script and change the colors of the broadcast? Thanks :D

up

How can i make that announce to broadcast it only to your self. It means only you can see the broadcast.

 

1. Reward:

Add this line:

getitem <itemid>,<amount>;

 

2. Color:

add 0x<html color code> at the end of the announce command.

Link for color codes

 

3. Announce to Killer

Change the 0 at the end of the announce command to bc_self

 

 

Like this for Event Tickets and a red colored broadcast :

OnNPCKillEvent:
if( getmonsterinfo( killedrid,MOB_MVPEXP ) )
    announce strcharinfo(0)+" killed "+getmonsterinfo( killedrid,MOB_NAME ),bc_self,0xFF0000;
    getitem 7711,2;
end;
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   2
  • Joined:  03/06/12
  • Last Seen:  

Now the problem is how can i add a reward to your script and change the colors of the broadcast? Thanks :D

up

How can i make that announce to broadcast it only to your self. It means only you can see the broadcast.

 

1. Reward:

Add this line:

getitem <itemid>,<amount>;

 

2. Color:

add 0x<html color code> at the end of the announce command.

Link for color codes

 

3. Announce to Killer

Change the 0 at the end of the announce command to bc_self

 

 

Like this for Event Tickets and a red colored broadcast :

OnNPCKillEvent:
if( getmonsterinfo( killedrid,MOB_MVPEXP ) )
    announce strcharinfo(0)+" killed "+getmonsterinfo( killedrid,MOB_NAME ),bc_self,0xFF0000;
    getitem 7711,2;
end;

I tried getitem but even though you're killing a normal mob, It gives you the reward.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  382
  • Reputation:   38
  • Joined:  01/17/12
  • Last Seen:  

I tried getitem but even though you're killing a normal mob, It gives you the reward.

 

Try this:

OnNPCKillEvent:
if( getmonsterinfo( killedrid,MOB_MVPEXP ) > 0 )
    announce strcharinfo(0)+" killed "+getmonsterinfo( killedrid,MOB_NAME ),bc_self,0xFF0000;
    getitem 7711,2;
end;
Link to comment
Share on other sites


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

@Bahmut..

it's the same...the result will alway return true if the monster have MVP EXP.

 

@TS

make sure your getmonsterinfo have the extended parameter...

	MOB_MVPEXP	22
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   2
  • Joined:  03/06/12
  • Last Seen:  

OnNPCKillEvent:

if( getmonsterinfo( killedrid,MOB_MVPEXP ) > 22 )

    announce strcharinfo(0)+" killed "+getmonsterinfo( killedrid,MOB_NAME ),bc_self,0xFF0000;

    getitem 7711,2;

end;

 

 

 

 

 

Like this?

up

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  382
  • Reputation:   38
  • Joined:  01/17/12
  • Last Seen:  

What server software are you using?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   2
  • Joined:  03/06/12
  • Last Seen:  

Linux

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  382
  • Reputation:   38
  • Joined:  01/17/12
  • Last Seen:  

No I mean eAthena, rAthena, Hercules, etc. Also what revision are you using?

Link to comment
Share on other sites


  • Group:  Developer
  • Topic Count:  10
  • Topics Per Day:  0.00
  • Content Count:  2407
  • Reputation:   613
  • Joined:  07/05/12
  • Last Seen:  

OnNPCKillEvent:
    if( getmonsterinfo( killedrid,MOB_MVPEXP ) > 0 ) {
        announce strcharinfo(0)+" killed "+getmonsterinfo( killedrid,MOB_NAME ),bc_self,0xFF0000;
        getitem 7711,2;
    }
    end;

Bahmut forgot the brackets.

Theses lines don't work with eAthena servers.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  17
  • Topics Per Day:  0.00
  • Content Count:  382
  • Reputation:   38
  • Joined:  01/17/12
  • Last Seen:  

@Capuche

Oh you are right haven't checked that.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  295
  • Reputation:   2
  • Joined:  03/06/12
  • Last Seen:  

I am using rathena.

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...