Issue information

Issue ID
#4207
Status
Fixed
Severity
None
Started
Hercules Elf Bot
Apr 25, 2010 20:25
Last Post
Hercules Elf Bot
Apr 4, 2012 9:50
Confirmation
Yes (1)
No (0)

Hercules Elf Bot - Apr 25, 2010 20:25

Originally posted by [b]DeePee[/b]
http://www.eathena.ws/board/index.php?autocom=bugtracker&showbug=4207

Tribal Solidarity (659), script being:

CODE
guildgetexp rand(600000,1200000);


With eA's/C's rand function having 32k as a max between the two values, the exp obtained from this never goes above 632k.

Suggesting to change the script to something like:

CODE
guildgetexp rand(6000,12000)*100;


Or to somehow increase the rand() range, obviously.

This post has been edited by DeePee: Apr 25 2010, 01:37 PM

Hercules Elf Bot - Dec 13, 2011 15:48

Originally posted by [b]Kenpachi[/b]
Tested and confirmed.

-> Moving to core section since fixing this requires modifying the cores internal rand() function.

Hercules Elf Bot - Dec 13, 2011 17:32

Originally posted by [b]Epoque[/b]
Fixed in [rev=15090]. The script command rand() now uses a two-step mechanism to parse a value as two unsigned short values, rather than as a single block.

This post has been edited by Kenpachi on Apr 4, 2012 9:45