Jump to content
  • 0

Couple of Warnings and Debug on PRIVATE MVP room :(


Question

14 answers to this question

Recommended Posts

Posted

The script you can download is not really tabulated, hard to check.

Anyway I'm pretty sure that error comes from a command who needs a string to be used, and passing just an integer. Sure way to correct it is:

set .@num, atoi(getarg(0)+"");

Same for getstrlen command.

Posted

Can you tell me where to put that statement?

set .rentitemid, 674; // item id use for rent a room - 674 - mithil coin

set .rentitemamount, 0; // amount of items to rent a room

set .rentcost, 10000000; // otherwise, zeny cost to rent a room

It is like this..

so i need to remove the rentcost

I did find this on top of the script

//	....... if your server has { Overwriting user function [int__] } don't blame me ..........
function	script	int__	{
set .@num, atoi(getarg(0));
if ( .@num == 0 || .@num >= 2147483647 ) return getarg(0);
set .@l, getstrlen(.@num);
for ( set .@i,0; .@i < .@l; set .@i, .@i + 1 ) {
	set .@num$, .@num % pow(10,.@i+1) / pow(10,.@i) + .@num$;
	if ( (.@i+1) % 3 == 0 && .@i+1 != .@l ) set .@num$, ","+ .@num$;
}
return .@num$;

Posted

try with

OnInit:
set .rentitemid, 674; // item id use for rent a room - 674 - mithil coin
set .rentitemamount, 0; // amount of items to rent a room
set .rentcost, 10000000; // otherwise, zeny cost to rent a room
end;

at the end of the script, before the last } (not in the function of course)

I can't really read your script as in the txt file it's not well tabulated and have no time to retabulate :< Try to pastebin for me please :3

Posted

First, do the changes I told you to do to fiz the warnings.

then, just change the values of those 3 variables as you like.

set .rentitemid, 674; // item id use for rent a room - 674 - mithil coin

set .rentitemamount, 0; // amount of items to rent a room

set .rentcost, 10000000; // otherwise, zeny cost to rent a room

Set a '0' as .rentcost if you want players not to pay Zeny for renting the room.

Also, set a number X>0 as the amount of .rentitem item you want players to pay for renting.

If you want a "free" renting, just leave .rentitem = 674 and the other 2 at 0.

  • Upvote 1

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...