Jump to content
×
×
  • Create New...
  • 1

Energy System Bug


yagokurt

Question

Hi, i'm having a strange bug with the energy system. If i use an energy crystal and then use a mount the bonus just get double, and even after remove all my armor i still having the bugged effect. Someone have any clue how i could fix it? I'm using a self-compiled game. Here is an video with an example.

 

Link to comment
Share on other sites

  • Answers 8
  • Created
  • Last Reply

Top Posters For This Question

8 answers to this question

Recommended Posts

  • 0

I think this bug due from mount so is not energy

 

Try this

Find pc_mount_bonus function in questlua_pc.cpp

if( NULL != ch )
{
	ch->RemoveAffect(AFFECT_MOUNT_BONUS);
	ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
}

Replace

if(ch)
{
	if (!ch->GetMountVnum())
		return 0;
	ch->RemoveAffect(AFFECT_MOUNT_BONUS);
	ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
}

 

Link to comment
Share on other sites

  • 0

I think this bug due from mount so is not energy

 

Try this

Find pc_mount_bonus function in questlua_pc.cpp

if( NULL != ch )
{
	ch->RemoveAffect(AFFECT_MOUNT_BONUS);
	ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
}

Replace

if(ch)
{
	if (!ch->GetMountVnum())
		return 0;
	ch->RemoveAffect(AFFECT_MOUNT_BONUS);
	ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
}

 

 

Hi, the problem happen even using the command "/mount_test ID" then should be on the quest commands. Sure? But i'm going to try it.

Edited by yagokurt
Link to comment
Share on other sites

  • 0

I think this bug due from mount so is not energy

 

Try this

Find pc_mount_bonus function in questlua_pc.cpp

if( NULL != ch )
{
	ch->RemoveAffect(AFFECT_MOUNT_BONUS);
	ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
}

Replace

if(ch)
{
	if (!ch->GetMountVnum())
		return 0;
	ch->RemoveAffect(AFFECT_MOUNT_BONUS);
	ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
}

 

 

Hi, the problem happen even using the command "/mount_test ID" then should be on the quest commands. Sure? But i'm going to try it.

​Because mount affect values not correct calculated

Link to comment
Share on other sites

  • 0

I think this bug due from mount so is not energy

 

Try this

Find pc_mount_bonus function in questlua_pc.cpp

if( NULL != ch )
{
	ch->RemoveAffect(AFFECT_MOUNT_BONUS);
	ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
}

Replace

if(ch)
{
	if (!ch->GetMountVnum())
		return 0;
	ch->RemoveAffect(AFFECT_MOUNT_BONUS);
	ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
}

 

 

Hi, the problem happen even using the command "/mount_test ID" then should be on the quest commands. Sure? But i'm going to try it.

​Because mount affect values not correct calculated

​Well, dont work. And isnt mount affect. If i havent energy activated this dont happen. It make duble the energy effect.

Edited by yagokurt
Link to comment
Share on other sites

  • 0
On 6/18/2015 at 5:45 PM, Koray said:

I think this bug due from mount so is not energy

Nope, the problem within the energy system, not for the mounts.

For example:

  1. get naked?
  2. use the energy crystal (51002)
  3. equip a piece of equipment which has APPLY_ENERGY (18060-18069 has by default)
  4. equip for example your armor which has 2000 HP
  5. now start unequip and equip your belt -> your HP will start to decrease each time ?

The problem probably within the calculation of the energy or something.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.