Jump to content
  • 0

Wrong stat points given on "set Baselevel"


johnbond

Question


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  457
  • Reputation:   11
  • Joined:  02/17/13
  • Last Seen:  

I have this leechmaster script by LordKiel I got from before:

//Leech Master by LordKiel
//This is my 1st script
//Enjoy

prontera,126,81,0	script	Leech Master	48,{
	set @npcname$, "^FF0000[Leech Master]^000000";
	mes "[Leech Master]";
	mes "I am the Leech Master";
	mes "I can help you leeching in exchange for some zeny";
	mes "1 Levelup: 10,000,000z";
	mes "5 Levelup: 50,000,000z";
	mes "10 Levelup: 100,000,000z";
	mes "So,what do you want?:";
	next;
	menu "^FF33551 Levelup",L0,"5 Levelup",L1,"10 Levelup^000000",L2,"Quit",LEnd;
	
	L0:
		mes "[Leech Master]";
		if (Zeny < 10000000) goto NeedZenys;
		mes "Alright, here we go now.. Remember, changes won't take effect until you log back on!";
		set Zeny,zeny-10000000;
		set	Baselevel,Baselevel+1;
		set	Joblevel,Joblevel+1;
		close;
	L1:
		mes "[Leech Master]";
		if (Zeny < 50000000) goto NeedZenys;
		mes "Alright, here we go now.. Remember, changes won't take effect until you log back on!";
		set Zeny,zeny-50000000;
		set	Baselevel,Baselevel+5;
		set	Joblevel,Joblevel+5;
		close;
	L2:
		mes "[Leech Master]";
		if (Zeny < 100000000) goto NeedZenys;
		mes "Alright, here we go now.. Remember, changes won't take effect until you log back on!";
		set Zeny,zeny-100000000;
		set	Baselevel,Baselevel+10;
		set	Joblevel,Joblevel+10;
		close;

		NeedZenys:
			mes "Sorry, you don't have enough Zeny.";
			close;
	LEnd:
		close;	
}

It gives the option of :

 

        mes "I can help you leeching in exchange for some zeny";
        mes "1 Levelup: 10,000,000z";
        mes "5 Levelup: 50,000,000z";
        mes "10 Levelup: 100,000,000z";

 

 

Now my problem is why is it that when players at level 99 3rd job then they use the leechmaster to level up 10 levels for 5 times then 1 level for 1 time to reach official max level of 150 for 3rd jobs, the stat points given is more than it should. With all stats at 1 the official stat points should be 2545 but instead when using this leechmaster their stat points becomes 2670? It is 125 stat points more than what it should.

 

When they reset stats using some other NPC then all will be back to normal at 2545 stat points.

 

I think there is no special line in the leechmaster script which will do this error (set     Baselevel,Baselevel+10;)  so maybe I suspect that perhaps its some wrong values in my DB folder or somewhere else? Maybe when the script uses the "set     Baselevel,Baselevel+10;" command then my DB gives out wrong values.

 

Does anybody know how and where to fix this??? My players found out about this exploit and everyone is doing it which I think should be fixed.

 

Please give me enlightenment about the matter.

 

 

Thank you in advance guys.

 

 

 

 

Link to comment
Share on other sites

11 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  18
  • Topics Per Day:  0.00
  • Content Count:  2044
  • Reputation:   682
  • Joined:  10/09/12
  • Last Seen:  

// Use the contents of db/statpoint.txt when doing a stats reset and leveling up? (Note 1)

// If no, an equation will be used which preserves statpoints earned/lost

// through external means (ie: stat point buyers/sellers)

use_statpoint_table: yes

what's your value here ?

also ... I think its better to calculate the zeny requirement based on the player's current level ...

like level1->2 = 1,000,000 zeny

level80->81 = 80,000,000 zeny

Edited by AnnieRuru
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  457
  • Reputation:   11
  • Joined:  02/17/13
  • Last Seen:  

 

// Use the contents of db/statpoint.txt when doing a stats reset and leveling up? (Note 1)

// If no, an equation will be used which preserves statpoints earned/lost

// through external means (ie: stat point buyers/sellers)

use_statpoint_table: yes

what's your value here ?

also ... I think its better to calculate the zeny requirement based on the player's current level ...

like level1->2 = 1,000,000 zeny

level80->81 = 80,000,000 zeny

 

 

 

Sorry forthe alte reply.

 

Here is what I have in exp.conf:

// Use the contents of db/statpoint.txt when doing a stats reset and leveling up? (Note 1)
// If no, an equation will be used which preserves statpoints earned/lost 
// through external means (ie: stat point buyers/sellers)
use_statpoint_table: yes

What do you think is the problem?

 

Ah yes, maybe I will set those new zeny prices someday but I think the script I have does not support it.

 

Thank you for your reply. :)

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  18
  • Topics Per Day:  0.00
  • Content Count:  2044
  • Reputation:   682
  • Joined:  10/09/12
  • Last Seen:  

http://www.eathena.ws/board/index.php?s=&showtopic=190718&view=findpost&p=1048274

prontera,156,186,5	script	stat calc	100,{
	input .@a;
	set .@i, 1;
	while ( .@i <= .@a ) {
		set .@stpoint, .@stpoint + ( .@i + 14 ) /5;
		set .@i, .@i +1;
	}
	set .@stpoint, .@stpoint - 3;
	if ( upper & 1 ) set .@stpoint, .@stpoint + 100;
	else set .@stpoint, .@stpoint + 48;
	dispbottom .@stpoint;
	end;
}
yes, I'm using this script that ripped from source code

the formula only correct up until level 105

above level 106, the value starts to go differently

I think this should belongs to bug report ...

I dunno ... I don't know anything about official info

EDIT:

http://www.eathena.ws/board/index.php?s=&showtopic=169635&view=findpost&p=998982

I think I lost that script ... I wish I can dig it out

dig out already

prontera,158,181,5	script	point	100,{
	mes "You have "+ statuspstore +" remaining stat points in vault.";
	if ( statuspstore && statuspoint > 2000 ) {
		mes "Please use up your stat points until you have less than 2000.";
	} else if ( statuspstore ) {
		if ( statuspstore >= 30000 )
			mes "Do you need another 30000 stat points?";
		else
			mes "Do you need another "+ statuspstore +" ?";
		next;
		if ( select ( "Yes:No" ) == 2 ) close;
		if ( statuspstore >= 30000 ) {
			set statuspoint, statuspoint + 30000;
			set statuspstore, statuspstore - 30000;
		} else {
			set statuspoint, statuspoint + statuspstore;
			set statuspstore, 0;
		}
	} else {
		set .@i, 1;
		while ( .@i <= baselevel ) {
			set .@stpoint, .@stpoint + ( .@i + 14 ) /5 ;
			set .@i, .@i +1 ;
		}
		set .@stpoint, .@stpoint - 3;
		if ( upper == 1 ) set .@stpoint, .@stpoint + 100;
		else set .@stpoint, .@stpoint + 48;
		mes "Stat Points you should have = "+ .@stpoint;
		mes "Reset now ?";
		next;
		if ( select ( "Yes:No" ) == 2 ) close;
		resetstatus;
		if ( .@stpoint > 30000 ) {
			set statuspoint, 30000;
			set statuspstore, .@stpoint - 30000;
		} else
			set statuspoint, .@stpoint;
		mes "Done.";
	}
	close;
}
doesn't change the fact it is using wrong stat table too
Edited by AnnieRuru
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  457
  • Reputation:   11
  • Joined:  02/17/13
  • Last Seen:  

Ohh.. Is there some way to fix it? Isnt it because of my db/exp table?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  18
  • Topics Per Day:  0.00
  • Content Count:  2044
  • Reputation:   682
  • Joined:  10/09/12
  • Last Seen:  

dig out another topic

http://www.eathena.ws/board/index.php?s=&showtopic=192349&view=findpost&p=1330355

 

prontera,156,186,5	script	stat calc	100,{
	input .@a;
	dispbottom ( ( upper == 1 )? 97:45 ) + ( .@a %5 ) * ( .@a /5 ) + .@a *3 + ( ( .@a -5 )/5 * ( 10 + ( ( ( .@a -5 )/5 )-1 ) * 5 ) ) /2;
	end;
}
now you have 2 options

1. follow the statpoint.txt table

- remove this buy base level script, since it causing exploit

- use OnPCLoginEvent and resetstatus; set resetted_stat, 1;

2. use the formula (don't follow statpoint.txt anymore)

- continue using this buy base level script, means everyone can gain extra stats from the formula

- use OnPCLoginEvent, put in this formula and set resetted_stat, 1;

- use_statpoint_table: no <-- change it

the problem is ... is the statpoint.txt follows the official value ...

if it follows the official one, then this has become an official bug, need to report this one

Edited by AnnieRuru
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  457
  • Reputation:   11
  • Joined:  02/17/13
  • Last Seen:  

dig out another topic

http://www.eathena.ws/board/index.php?s=&showtopic=192349&view=findpost&p=1330355

 

prontera,156,186,5	script	stat calc	100,{
	input .@a;
	dispbottom ( ( upper == 1 )? 97:45 ) + ( .@a %5 ) * ( .@a /5 ) + .@a *3 + ( ( .@a -5 )/5 * ( 10 + ( ( ( .@a -5 )/5 )-1 ) * 5 ) ) /2;
	end;
}
now you have 2 options

1. follow the statpoint.txt table

- remove this buy base level script, since it causing exploit

- use OnPCLoginEvent and resetstatus; set resetted_stat, 1;

2. use the formula (don't follow statpoint.txt anymore)

- continue using this buy base level script, means everyone can gain extra stats from the formula

- use OnPCLoginEvent, put in this formula and set resetted_stat, 1;

- use_statpoint_table: no <-- change it

the problem is ... is the statpoint.txt follows the official value ...

if it follows the official one, then this has become an official bug, need to report this one

 

 

 

Oh I am not good with #1. I still need that leveling script.

 

As for #2. I dont want to give everyone the extra stat points just to be fair to everyone because it will be a problem again with complaints when I take it out someday when this bug is fixed.

 

Maybe I will just have to wait until fixed? Or do we have other solutions?

 

Thank you for your reply.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  18
  • Topics Per Day:  0.00
  • Content Count:  2044
  • Reputation:   682
  • Joined:  10/09/12
  • Last Seen:  

after some digging through the source code ....

	for ( ; low < high; low++ )
#ifdef RENEWAL // renewal status point cost formula
		sp += (low < 100) ? (2 + (low - 1) / 10) : (16 + 4 * ((low - 100) / 5));
#else
		sp += ( 1 + (low + 9) / 10 );
#endif
means ... the statpoint.txt in \re\ folder is official ...

because the formula above I used, is actually correct in \pre-re\ folder

http://rathena.org/board/tracker/issue-4578-missing-bonus-infodocumentationblvlup-bug/?gopid=4578#entry4578

can you please try this

 

prontera,156,186,5	script	stat calc	100,{
	input .@a, -999, 999;
	baselevel = baselevel + .@a;
	end;
}
check if the atcommand "@lvup" and set baselevel are having any difference in stat

in my test, how come when my server set to renewal, but I'm getting 2670 instead of 2545

but you say you can get 2545 when reset ? my test shows 2670 when reset

getting more and more funny each time I do this research

and actually

I do reset, my statpoint is actually 0 instead of 48 ... wtf ...

EDIT:

http://rathena.org/board/tracker/issue-8429-bug-statpoint/

someone already reported, try post your result too

EDIT2:

confirmed now this is rathena bug, not from your custom script ...

waiting for the developer to fix it

Edited by AnnieRuru
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  457
  • Reputation:   11
  • Joined:  02/17/13
  • Last Seen:  

after some digging through the source code ....

	for ( ; low < high; low++ )
#ifdef RENEWAL // renewal status point cost formula
		sp += (low < 100) ? (2 + (low - 1) / 10) : (16 + 4 * ((low - 100) / 5));
#else
		sp += ( 1 + (low + 9) / 10 );
#endif
means ... the statpoint.txt in \re\ folder is official ...

because the formula above I used, is actually correct in \pre-re\ folder

http://rathena.org/board/tracker/issue-4578-missing-bonus-infodocumentationblvlup-bug/?gopid=4578#entry4578

can you please try this

 

prontera,156,186,5	script	stat calc	100,{
	input .@a, -999, 999;
	baselevel = baselevel + .@a;
	end;
}
check if the atcommand "@lvup" and set baselevel are having any difference in stat

in my test, how come when my server set to renewal, but I'm getting 2670 instead of 2545

but you say you can get 2545 when reset ? my test shows 2670 when reset

getting more and more funny each time I do this research

and actually

I do reset, my statpoint is actually 0 instead of 48 ... wtf ...

EDIT:

http://rathena.org/board/tracker/issue-8429-bug-statpoint/

someone already reported, try post your result too

EDIT2:

confirmed now this is rathena bug, not from your custom script ...

waiting for the developer to fix it

 

 

When I use @blvl 150 I get correct stat points at 2545 with all stats at 1. Umm maybe in renewal its really 2670? And in pre-re is 2545? I dunno.

 

Okay then so we shall wait until fixed by dev?

 

DO we have some alternate ways to solve this while waiting for dev fix?

 

Thank you.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  18
  • Topics Per Day:  0.00
  • Content Count:  2044
  • Reputation:   682
  • Joined:  10/09/12
  • Last Seen:  

Umm maybe in renewal its really 2670? And in pre-re is 2545? I dunno.

its the opposite

look into the file with \re\statpoint.txt and \pre-re\statpoint.txt

I can tell its the official values

this bug is probably caused by the recent implementation of import folder ... maybe

 

DO we have some alternate ways to solve this while waiting for dev fix?

alternative way, of course,

change

set baselevel, baselevel + 1;

set joblevel, joblevel + 1;

into

atcommand "@lvup 1";

atcommand "@joblvup 1";

Edit:

http://rathena.org/board/tracker/issue-8429-bug-statpoint/

seems to be just fixed few hours ago

however you still need some ways to reset the status points of the player who are currently having imba stats

Edited by AnnieRuru
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  113
  • Topics Per Day:  0.03
  • Content Count:  457
  • Reputation:   11
  • Joined:  02/17/13
  • Last Seen:  

 

Umm maybe in renewal its really 2670? And in pre-re is 2545? I dunno.

its the opposite

look into the file with \re\statpoint.txt and \pre-re\statpoint.txt

I can tell its the official values

this bug is probably caused by the recent implementation of import folder ... maybe

 

DO we have some alternate ways to solve this while waiting for dev fix?

alternative way, of course,

change

set baselevel, baselevel + 1;

set joblevel, joblevel + 1;

into

atcommand "@lvup 1";

atcommand "@joblvup 1";

Edit:

http://rathena.org/board/tracker/issue-8429-bug-statpoint/

seems to be just fixed few hours ago

however you still need some ways to reset the status points of the player who are currently having imba stats

 

 

 

Nice thanks!

 

About resetting, how about a SQL query while Server offline? A query that will reset stats of all characters above level 105?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  18
  • Topics Per Day:  0.00
  • Content Count:  2044
  • Reputation:   682
  • Joined:  10/09/12
  • Last Seen:  

Nice thanks!

say thanks to @Cydh, no me

he is the one who fixed it =/

About resetting, how about a SQL query while Server offline? A query that will reset stats of all characters above level 105?

I couldn't find any equation made for renewal stat point formula

... everywhere .. even google search

and its pain in the ass to create one ...

it seems like at 105->115, the difference goes like 1,2,3,4 ...

115->125 goes like 12,14,16,18, ....

I'm not a math genius ... maybe @KeyWorld can make one ... hahaha

its much easier if you do a reset from an npc script

-	script	kjhfksjfh	-1,{
OnPCLoginEvent:
	if ( baselevel < 105 || renewal_stat_reset ) end;
	dispbottom "Your status point has been reset";
	resetstatus;
	renewal_stat_reset = 1;
	end;
}
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...