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

How Debug skill sure (enchanted blade) Game 34k


DevelopeR

Question

Hello, people.

 

I won't ask how debug the skill -(enchanted blade)- on game 34

 

 

someone can help ?

 

 

I'm sorry my Inglesh is so bad.

:ph34r:

 

 

And if the post not must here on this direction, I'm sorry but i don't  know where to post.

 

Link to comment
Share on other sites

10 answers to this question

Recommended Posts

  • 0

He meant the bug that when you overkill someone, you'll loose hp in cause of the hp drain.

 

In 34083 you'll need a lib because there's no room for further number checkings.

 

 

It's in the source, you may search for the applying bonus. There the hp drain will be calculated but not checked if it's < 0. Just make a check and if it's less than zero, multiply it with -1. This will revert the value and makes sure you'll always gain hp, not loose some.

We are the tortured.
We're not your friends.
As long as we're not visible.
We are unfixable.

Link to comment
Share on other sites

  • 0

He meant the bug that when you overkill someone, you'll loose hp in cause of the hp drain.

 

In 34083 you'll need a lib because there's no room for further number checkings.

 

 

It's in the source, you may search for the applying bonus. There the hp drain will be calculated but not checked if it's < 0. Just make a check and if it's less than zero, multiply it with -1. This will revert the value and makes sure you'll always gain hp, not loose some.

 

Can you make a how to please?

 

Regards.

Link to comment
Share on other sites

  • 0

yes, I'll explain how you can do it.

Either I'll edit it here or make a new topic for the how to. Depends on if it's better to make a new topic or if it's not enough to be a own topic.

We are the tortured.
We're not your friends.
As long as we're not visible.
We are unfixable.

Link to comment
Share on other sites

  • 0

It's quite easy, doesn't require a new thread for it. Sorry for the late answer I didn't noticed you replying (need to get used to the board).

 

Opfen char_battle.cpp and search for POINT_HIT_SP_RECOVERY

You'll find this one:

 

 


if (pAttacker->GetPoint(POINT_HIT_HP_RECOVERY) && number(0, 4) > 0) // 80% È®·ü
            {
                int i = MIN(dam, iCurHP) * pAttacker->GetPoint(POINT_HIT_HP_RECOVERY) / 100;

                if (i)
                {
                    CreateFly(FLY_HP_SMALL, pAttacker);
                    pAttacker->PointChange(POINT_HP, i);
                }
            }

 

The problem with this is, as you may noticed, that if you manage to overkill someone his tp goes < 0 and the hp drained will become negative too. An easy way to go around this is the following:

if(i<0)

   i *= -1;

 

This will check if the value you'll get is lesser than 0. And if it's the case, your core will multiply it with -1 so it won't be negative anymore and you'll still be healed. Just put it before you create the Fly event.

  • Love 1

We are the tortured.
We're not your friends.
As long as we're not visible.
We are unfixable.

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
  • Recently Browsing   0 members

    • No registered users viewing this page.


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.