Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Flyff > Flyff Private Server
You last visited: Today at 07:08

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



help about some fix code..

Discussion on help about some fix code.. within the Flyff Private Server forum part of the Flyff category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
help about some fix code..

i would like to ask does anyone knows what kind of fix is this?

PHP Code:
int CMover::GetHitPoint()
{
#ifdef    __FIX_GET_HP_MP_FP
    
int hitPoint GetParam(DST_HPm_nHitPoint);
    
int maxHitPoint GetMaxHitPoint();

    if (
hitPoint maxHitPoint)
        return 
maxHitPoint;
    else
        return 
hitPoint;
#endif  //__FIX_GET_HP_MP_FP
    
return GetParamDST_HPm_nHitPoint );

my world.exe crashed every 5hrs to 10hrs... when i debug it! this code is the reason why it crashes.. does anyone know about this code? tnx...
RhisisChaos is offline  
Old 11/12/2017, 20:21   #2


 
- Major's Avatar
 
elite*gold: 7
Join Date: Sep 2012
Posts: 4,462
Received Thanks: 3,213
Quote:
Originally Posted by RhisisChaos View Post
i would like to ask does anyone knows what kind of fix is this?

PHP Code:
int CMover::GetHitPoint()
{
#ifdef    __FIX_GET_HP_MP_FP
    
int hitPoint GetParam(DST_HPm_nHitPoint);
    
int maxHitPoint GetMaxHitPoint();

    if (
hitPoint maxHitPoint)
        return 
maxHitPoint;
    else
        return 
hitPoint;
#endif  //__FIX_GET_HP_MP_FP
    
return GetParamDST_HPm_nHitPoint );

my world.exe crashed every 5hrs to 10hrs... when i debug it! this code is the reason why it crashes.. does anyone know about this code? tnx...

-> This Code set the HP , MP and FP to the maximal of your character, when you have more then your maximal hp. Example you had STA Buff and the Buff times out.. Then you had more hp then your maximal hp.. This Fix remove this bug and set it to the new max HP.
- Major is offline  
Thanks
1 User
Old 11/13/2017, 09:58   #3
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
Quote:
Originally Posted by DK ACE View Post
-> This Code set the HP , MP and FP to the maximal of your character, when you have more then your maximal hp. Example you had STA Buff and the Buff times out.. Then you had more hp then your maximal hp.. This Fix remove this bug and set it to the new max HP.
ahh i see.. but why is it that my world.exe crashes because of this code?
RhisisChaos is offline  
Old 11/13/2017, 10:02   #4
 
elite*gold: 32
Join Date: Dec 2015
Posts: 2,275
Received Thanks: 1,113
Quote:
Originally Posted by RhisisChaos View Post
ahh i see.. but why is it that my world.exe crashes because of this code?
More details of the crash please.
FlyffServices is offline  
Old 11/13/2017, 10:22   #5
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
Quote:
Originally Posted by FlyffServices View Post
More details of the crash please.
i'm going to view the full error later after it crashes again... but i have a picture here...



i've checked my versioncommon.h and it was not define there so what i did is that i defined it... then my server became stable.. it did not crash anymore but when i added edit some files on my resources just like changing the stats/Damge/HP of the monster from the Tower siege (Propmover) new error came out and when i returned the stats/damage/HP of the monster to the original... that error came back... and until now it wont stop... so my server has only 5hrs to 10hrs or if im lucky it will last for 15hrs before it crashes again...
RhisisChaos is offline  
Old 11/13/2017, 10:28   #6
 
elite*gold: 32
Join Date: Dec 2015
Posts: 2,275
Received Thanks: 1,113
Quote:
Originally Posted by RhisisChaos View Post
i'm going to view the full error later after it crashes again... but i have a picture here...



i've checked my versioncommon.h and it was not define there so what i did is that i defined it... then my server became stable.. it did not crash anymore but when i added edit some files on my resources just like changing the stats/Damge/HP of the monster from the Tower siege (Propmover) new error came out and when i returned the stats/damage/HP of the monster to the original... that error came back... and until now it wont stop... so my server has only 5hrs to 10hrs or if im lucky it will last for 15hrs before it crashes again...

Code:
int CMover::GetChgParam( int nDestParameter )
{
	if( nDestParameter < MAX_ADJPARAMARY )
		return m_chgParamAry[ nDestParameter ];
	return 0x7FFFFFFF;
}
Code:
#define MAX_ADJPARAMARY             117
Code:
LONG			m_chgParamAry[ MAX_ADJPARAMARY ];
Did u changed something here?

Can you post your defineAttribute.h (its in the resource folder)?
FlyffServices is offline  
Old 11/13/2017, 10:44   #7
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
Quote:
Originally Posted by FlyffServices View Post
Code:
int CMover::GetChgParam( int nDestParameter )
{
	if( nDestParameter < MAX_ADJPARAMARY )
		return m_chgParamAry[ nDestParameter ];
	return 0x7FFFFFFF;
}
Code:
#define MAX_ADJPARAMARY             117
Code:
LONG			m_chgParamAry[ MAX_ADJPARAMARY ];
Did u changed something here?

Can you post your defineAttribute.h (its in the resource folder)?
no i did not change any codes from there.. i've checked the defineattribute.h and MAX_ADJPARAMARY was defined...

RhisisChaos is offline  
Old 11/13/2017, 11:17   #8
 
elite*gold: 0
Join Date: Jun 2017
Posts: 46
Received Thanks: 29
This is nullptr.

Well, to fix the crash immediately, you can move the access to the CUser class till after checking if it is valid. Guessing you are using the released Swap bug fix which likes to check before the pUser is checked to be a nullptr.
Hekmatyar is offline  
Old 11/13/2017, 15:24   #9
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
Quote:
Originally Posted by Hekmatyar View Post
This is nullptr.

Well, to fix the crash immediately, you can move the access to the CUser class till after checking if it is valid. Guessing you are using the released Swap bug fix which likes to check before the pUser is checked to be a nullptr.
what is nullptr? sorry about that i don't get it.. pls educate me i'm just a newbie when in terms of codes....

my former developer put that fix on my source... and he abandoned me for a personal reason...
RhisisChaos is offline  
Old 11/13/2017, 16:45   #10
 
elite*gold: 50
Join Date: Jun 2015
Posts: 100
Received Thanks: 210
Show us your CDPSrvr::OnDoEquip (pMover or pUser or however that variable is called obviously is null)
ディオニュソス is offline  
Old 11/13/2017, 17:43   #11
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
Quote:
Originally Posted by ディオニュソス View Post
Show us your CDPSrvr::OnDoEquip (pMover or pUser or however that variable is called obviously is null)
you mean this sir?

PHP Code:
void CDPSrvr::OnDoEquipCAr arDPID dpidCacheDPID dpidUserLPBYTE lpBufu_long uBufSize )
{
    
DWORD nId;
    
int nPart;

    
ar >> nId;
    
ar >> nPart;        
    
    if( 
nPart >= MAX_HUMAN_PARTS )    
        return;

    
CUserpUser g_UserMng.GetUserdpidCachedpidUser );

#ifdef __SWITCH_FIX
    
if( pUser->GetHitPoint() >  pUser->GetMaxHitPoint() )
        
pUser->SetHitPointpUser->GetMaxHitPoint());

    if( 
pUser->GetManaPoint() >  pUser->GetMaxManaPoint() )
        
pUser->SetManaPointpUser->GetMaxManaPoint() );

    if( 
pUser->GetFatiguePoint() >  pUser->GetMaxFatiguePoint() )
        
pUser->SetFatiguePointpUser->GetMaxFatiguePoint() );
#endif //__SWITCH_FIX

    
if( IsValidObjpUser ) == FALSE )
        return;

    
CItemElempItemElem pUser->m_Inventory.GetAtIdnId );
    if( 
IsUsableItempItemElem ) == FALSE )
            return;
    if( 
nPart )
    {
        if( 
pUser->m_Inventory.IsEquipnId ) )
        {
            if( 
pItemElem != pUser->m_Inventory.GetEquipnPart ) )
                return;
        }
    }
    else
    {
        if( 
pUser->m_Inventory.IsEquipnId ) )
            return;
    }
#ifdef __HACK_1023
    
ItemProppItemProp        pItemElem->GetProp();
    if( 
pItemProp && pItemProp->dwParts == PARTS_RIDE )
    {
        if( !
pUser->m_Inventory.IsEquipnId ) )
        {
            
FLOAT fVal;
            
ar >> fVal;
            if( 
fVal != pItemProp->fFlightSpeed )
            {
                
pUser->AddDefinedTextTID_GAME_MODIFY_FLIGHT_SPEED );
                return;
            }
        }
    }
#endif    // __HACK_1023

    
if( pUser->IsDie() == FALSE )
        
pUser->DoUseEquipmentItempItemElemnIdnPart );

RhisisChaos is offline  
Old 11/13/2017, 17:52   #12
 
elite*gold: 50
Join Date: Jun 2015
Posts: 100
Received Thanks: 210
Replace that with:
Code:
void CDPSrvr::OnDoEquip( CAr & ar, DPID dpidCache, DPID dpidUser, LPBYTE lpBuf, u_long uBufSize ) 
{ 
    DWORD nId; 
    int nPart; 

    ar >> nId; 
    ar >> nPart;         
     
    if( nPart >= MAX_HUMAN_PARTS )     
        return; 

    CUser* pUser = g_UserMng.GetUser( dpidCache, dpidUser ); 

    if( IsValidObj( pUser ) == FALSE ) 
        return; 

#ifdef __SWITCH_FIX 
    if( pUser->GetHitPoint() >  pUser->GetMaxHitPoint() ) 
        pUser->SetHitPoint( pUser->GetMaxHitPoint()); 

    if( pUser->GetManaPoint() >  pUser->GetMaxManaPoint() ) 
        pUser->SetManaPoint( pUser->GetMaxManaPoint() ); 

    if( pUser->GetFatiguePoint() >  pUser->GetMaxFatiguePoint() ) 
        pUser->SetFatiguePoint( pUser->GetMaxFatiguePoint() ); 
#endif //__SWITCH_FIX 

    CItemElem* pItemElem = pUser->m_Inventory.GetAtId( nId ); 
    if( IsUsableItem( pItemElem ) == FALSE ) 
            return; 
    if( nPart > 0 ) 
    { 
        if( pUser->m_Inventory.IsEquip( nId ) ) 
        { 
            if( pItemElem != pUser->m_Inventory.GetEquip( nPart ) ) 
                return; 
        } 
    } 
    else 
    { 
        if( pUser->m_Inventory.IsEquip( nId ) ) 
            return; 
    } 
#ifdef __HACK_1023 
    ItemProp* pItemProp        = pItemElem->GetProp(); 
    if( pItemProp && pItemProp->dwParts == PARTS_RIDE ) 
    { 
        if( !pUser->m_Inventory.IsEquip( nId ) ) 
        { 
            FLOAT fVal; 
            ar >> fVal; 
            if( fVal != pItemProp->fFlightSpeed ) 
            { 
                pUser->AddDefinedText( TID_GAME_MODIFY_FLIGHT_SPEED ); 
                return; 
            } 
        } 
    } 
#endif    // __HACK_1023 

    if( pUser->IsDie() == FALSE ) 
        pUser->DoUseEquipmentItem( pItemElem, nId, nPart ); 
}
ディオニュソス is offline  
Thanks
1 User
Old 11/13/2017, 18:05   #13
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
Quote:
Originally Posted by ディオニュソス View Post
Replace that with:
Code:
void CDPSrvr::OnDoEquip( CAr & ar, DPID dpidCache, DPID dpidUser, LPBYTE lpBuf, u_long uBufSize ) 
{ 
    DWORD nId; 
    int nPart; 

    ar >> nId; 
    ar >> nPart;         
     
    if( nPart >= MAX_HUMAN_PARTS )     
        return; 

    CUser* pUser = g_UserMng.GetUser( dpidCache, dpidUser ); 

    if( IsValidObj( pUser ) == FALSE ) 
        return; 

#ifdef __SWITCH_FIX 
    if( pUser->GetHitPoint() >  pUser->GetMaxHitPoint() ) 
        pUser->SetHitPoint( pUser->GetMaxHitPoint()); 

    if( pUser->GetManaPoint() >  pUser->GetMaxManaPoint() ) 
        pUser->SetManaPoint( pUser->GetMaxManaPoint() ); 

    if( pUser->GetFatiguePoint() >  pUser->GetMaxFatiguePoint() ) 
        pUser->SetFatiguePoint( pUser->GetMaxFatiguePoint() ); 
#endif //__SWITCH_FIX 

    CItemElem* pItemElem = pUser->m_Inventory.GetAtId( nId ); 
    if( IsUsableItem( pItemElem ) == FALSE ) 
            return; 
    if( nPart > 0 ) 
    { 
        if( pUser->m_Inventory.IsEquip( nId ) ) 
        { 
            if( pItemElem != pUser->m_Inventory.GetEquip( nPart ) ) 
                return; 
        } 
    } 
    else 
    { 
        if( pUser->m_Inventory.IsEquip( nId ) ) 
            return; 
    } 
#ifdef __HACK_1023 
    ItemProp* pItemProp        = pItemElem->GetProp(); 
    if( pItemProp && pItemProp->dwParts == PARTS_RIDE ) 
    { 
        if( !pUser->m_Inventory.IsEquip( nId ) ) 
        { 
            FLOAT fVal; 
            ar >> fVal; 
            if( fVal != pItemProp->fFlightSpeed ) 
            { 
                pUser->AddDefinedText( TID_GAME_MODIFY_FLIGHT_SPEED ); 
                return; 
            } 
        } 
    } 
#endif    // __HACK_1023 

    if( pUser->IsDie() == FALSE ) 
        pUser->DoUseEquipmentItem( pItemElem, nId, nPart ); 
}
ok sir.. i will try this and i will update you after... tnx...
RhisisChaos is offline  
Old 11/20/2017, 17:31   #14
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
here are the errors....
[IMG=expandable: 1] [/IMG]
[IMG=expandable: 1] [/IMG]
[IMG=expandable: 1] [/IMG]
[IMG=expandable: 1] [/IMG]
[IMG=expandable: 1] [/IMG]
[IMG=expandable: 1] [/IMG]
RhisisChaos is offline  
Old 11/26/2017, 17:03   #15
 
elite*gold: 0
Join Date: Aug 2017
Posts: 33
Received Thanks: 2
Quote:
Originally Posted by ディオニュソス View Post

I literally told you how to fix this, you ain't the sharpest tool in the shed, huh?
im putting the fix you gave me sir.. im just showing the full error...
RhisisChaos is offline  
Reply

« Flyff Model | help »

Similar Threads Similar Threads
[04.09.13] GigaByte v2.6 [FIX, FIX, FIX, FIX AND FIX]
09/11/2013 - WarRock Hacks, Bots, Cheats & Exploits - 79 Replies
http://www.elitepvpers.com/forum/warrock-hacks-bot s-cheats-exploits/2843300-11-09-gigabyte-public-v2 -7-a.html



All times are GMT +2. The time now is 07:08.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.