Jump to content
The forums will be going offline for an extended maintenance period at 1400hrs GMT on 19th June 2025. The number of hours for this downtime is intentionally not advertised due to the nature of these upgrades. ×
  • 0

[solved] Add Zeny Cost to Custom Warper


jamesandrew

Question


  • Group:  Members
  • Topic Count:  23
  • Topics Per Day:  0.03
  • Content Count:  60
  • Reputation:   3
  • Joined:  06/21/23
  • Last Seen:  

I need help changing the default rathena custom warper. I want to add a 1.000 zeny cost for level 50 and above but keep it free for levels below 50.
https://github.com/rathena/rathena/blob/8740574ae349e516c5d3914bfaf13db13539327e/npc/custom/warper.txt#L19

Edited by jamesandrew
Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  63
  • Topics Per Day:  0.02
  • Content Count:  1016
  • Reputation:   191
  • Joined:  11/27/14
  • Last Seen:  

Add set zeny then add condition statement

Link to comment
Share on other sites

  • 1

  • Group:  Members
  • Topic Count:  13
  • Topics Per Day:  0.02
  • Content Count:  51
  • Reputation:   35
  • Joined:  09/09/23
  • Last Seen:  

You can add your checks here

function Go {
	set lastwarp$, getarg(0);
	set lastwarpx, getarg(1,0);
	set lastwarpy, getarg(2,0);
	if(BaseLevel > 50 && Zeny < 1000){
    	mes "You need 1,000 Zeny.";
		close;
    }
    if(BaseLevel > 50) Zeny -= 1000;
	warp getarg(0),getarg(1,0),getarg(2,0);
	end;
}

 

Edited by Nyaniverse
edit snippet
  • Upvote 1
  • MVP 1
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...