EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Support::Linux Servers (https://www.eqemulator.org/forums/forumdisplay.php?f=588)
-   -   LDON Merchant Caps? (https://www.eqemulator.org/forums/showthread.php?t=30393)

KingMort 01-24-2010 08:12 PM

LDON Merchant Caps?
 
Seems a player has gotten up to 58,000+ Guks (he can't remember exact number) and the total lifetime points under Guk's Reset to 700...

Seems like the system is highly unstable atm, including Ruj merchants not working just general point issues..

King

cavedude 01-24-2010 09:00 PM

Quote:

Originally Posted by KingMort (Post 183259)
Seems like the system is highly unstable atm, including Ruj merchants not working just general point issues..

King

Ruj works just fine, that's the theme I am doing now.

KingMort 01-25-2010 01:16 AM

Hmm are you 32bit ? I'm 64bit and it doesn't seem to function at all...

I'm also getting the recipe components not showing in tradeskill items..

Also have you tried to give yourself like say 100,000 points in a particular theme? it seems to wig out


Is there some way to compile in 32bit mode under a 64 bit os ? Because i'm just totally lost i'll admit

jkennedy 01-25-2010 02:02 AM

i have windows xp 64bit prof and i used all 32 bit programs to do my server

KingMort 01-25-2010 05:05 PM

We use Debian x64

And I do not know how to compile with 32bit... I really wish I did though due to all the weird problems it causes

Derision 01-25-2010 05:23 PM

Quote:

Originally Posted by KingMort (Post 183259)
Seems a player has gotten up to 58,000+ Guks (he can't remember exact number) and the total lifetime points under Guk's Reset to 700...

There is a check in client_packet.cpp around line 7735 which resets your ldon points to zero if any of them exceed 65535. Maybe that's causing your issue.

client_packet.cpp
Code:

        //validate adventure points, this cap is arbitrary
        if(m_pp.ldon_points_guk < 0 || m_pp.ldon_points_guk > 0xFFFF) m_pp.ldon_points_guk = 0;
        if(m_pp.ldon_points_mir < 0 || m_pp.ldon_points_mir > 0xFFFF) m_pp.ldon_points_mir = 0;
        if(m_pp.ldon_points_mmc < 0 || m_pp.ldon_points_mmc > 0xFFFF) m_pp.ldon_points_mmc = 0;
        if(m_pp.ldon_points_ruj < 0 || m_pp.ldon_points_ruj > 0xFFFF) m_pp.ldon_points_ruj = 0;
        if(m_pp.ldon_points_tak < 0 || m_pp.ldon_points_tak > 0xFFFF) m_pp.ldon_points_tak = 0;
        if(m_pp.ldon_points_available < 0 || m_pp.ldon_points_available > 0xFFFF) m_pp.ldon_points_available = 0;

the ldon points fields in the Player Profile are signed 32 bit integers, which can hold values up to +2,147,483,647

KingMort 01-26-2010 12:15 AM

Is there anyway to fix this ?

pfyon 01-26-2010 09:53 AM

Quote:

//validate adventure points, this cap is arbitrary
As derision said, the db entries are signed 32 bit integers, so you can change the 'reset cap' to 2,147,483,647 if you want.

KingMort 01-26-2010 05:11 PM

I'm sorry to be a n00blet but what exactly do I change.. And what do i change it too..

trevius 01-26-2010 06:56 PM

You should be able to change this:

Code:

        //validate adventure points, this cap is arbitrary
        if(m_pp.ldon_points_guk < 0 || m_pp.ldon_points_guk > 0xFFFF) m_pp.ldon_points_guk = 0;
        if(m_pp.ldon_points_mir < 0 || m_pp.ldon_points_mir > 0xFFFF) m_pp.ldon_points_mir = 0;
        if(m_pp.ldon_points_mmc < 0 || m_pp.ldon_points_mmc > 0xFFFF) m_pp.ldon_points_mmc = 0;
        if(m_pp.ldon_points_ruj < 0 || m_pp.ldon_points_ruj > 0xFFFF) m_pp.ldon_points_ruj = 0;
        if(m_pp.ldon_points_tak < 0 || m_pp.ldon_points_tak > 0xFFFF) m_pp.ldon_points_tak = 0;
        if(m_pp.ldon_points_available < 0 || m_pp.ldon_points_available > 0xFFFF) m_pp.ldon_points_available = 0;

To this:

Code:

        //validate adventure points, this cap is arbitrary
        if(m_pp.ldon_points_guk < 0 || m_pp.ldon_points_guk > 0xFFFFFFFF) m_pp.ldon_points_guk = 0;
        if(m_pp.ldon_points_mir < 0 || m_pp.ldon_points_mir > 0xFFFFFFFF) m_pp.ldon_points_mir = 0;
        if(m_pp.ldon_points_mmc < 0 || m_pp.ldon_points_mmc > 0xFFFFFFFF) m_pp.ldon_points_mmc = 0;
        if(m_pp.ldon_points_ruj < 0 || m_pp.ldon_points_ruj > 0xFFFFFFFF) m_pp.ldon_points_ruj = 0;
        if(m_pp.ldon_points_tak < 0 || m_pp.ldon_points_tak > 0xFFFFFFFF) m_pp.ldon_points_tak = 0;
        if(m_pp.ldon_points_available < 0 || m_pp.ldon_points_available > 0xFFFFFFFF) m_pp.ldon_points_available = 0;


KingMort 01-26-2010 08:52 PM

Awesome thanks a ton :)

pfyon 01-26-2010 09:02 PM

Out of curiosity sake, why is the code comparing to a hex value? I know 0xFFFFFFFF is equivalent to 2,147,483,647. Did the original programmer just do that for legibility purposes?

trevius 01-26-2010 11:11 PM

Just a guess, but I think it would be easier to remember 0xFFFFFFFF than 2147483647. It is also probably easier to make sure the number is correct when reading over the code.

KingMort 01-27-2010 05:05 PM

Alright put the code in and compiled and it worked great I was able to give myself Millions of points in a certain theme.. Really appreciate the help !

Is the same type of limiting also on stuff like Maxdmg ? if so how would i go about adjusting that..

King


All times are GMT -4. The time now is 08:06 AM.

Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.