HelpAS3 Enemy HP bars

Posts 1–9 of 9 · Page 1 of 1
AS3 Enemy HP bars
I don't know a lot about coding, but I know that when this line of code links back to protected function drawHpBar it isn't picking up the _local_ variables (I know that Local Variables only exist within a function)

How do I go about making this work?

Code:
        if (((((((((this.props_) && (((this.props_.isEnemy_) || (this.props_.isPlayer_))))) && (!(this.isInvisible())))) && (!(this.isInvulnerable())))) && (!(this.props_.noMiniMap_)))) {
            _local_9 = ((_local_4.getPixel32((_local_4.width / 4), (_local_4.height / 4)) | _local_4.getPixel32((_local_4.width / 2), (_local_4.height / 2))) | _local_4.getPixel32(((_local_4.width * 3) / 4), ((_local_4.height * 3) / 4)));
            _local_10 = (_local_9 >> 24);
            if (_local_10 != 0) {
                hasShadow_ = true;
                if (Parameters.data_.HPBar) {
                    this.drawHpBar(_arg_1, _arg_3);
                }
            }
            else {
                hasShadow_ = false;
            }
It's already working on your AS3 client (I suppose you're using AS3 such as DECA 27.7 for FSoD Version), you just need to export stats from enemies at your server side, so your game client will make HP Bar feature work properly.

Cheers, Devwarlt
I'm having a similar problem. The health bar goes down only on enemies such as the shtrs Abandoned Switch. I've checked, and all the same stats for enemies are in the client (max health, defense, etc.). I know the function can work, since it works on Abandoned Switches, however it doesn't work on pretty much any other monster, despite having the same types of stats.
How do you export Enemy stats?
Quote Originally Posted by Xandahhh View Post
How do you export Enemy stats?
look at player.cs and enemy.cs under ExportStats. Player.cs has what u need in enemy.cs which is an obvious answer.
Cheers Mike, i know exactly what you mean now
Quote Originally Posted by Xandahhh View Post
Cheers Mike, i know exactly what you mean now
So.... solved?
Solved, ty, idk how to change it to Solved
Quote Originally Posted by Xandahhh View Post
Solved, ty, idk how to change it to Solved
@Ahl @Raple OP solved it
Posts 1–9 of 9 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Need help?