Blizz ABS Stealth Attacks

Started by CriticalHit, April 01, 2017, 04:11:15 pm

Previous topic - Next topic

CriticalHit

Hi,

Something that has been driving me nuts for a long time is how to implement a stealth attack system in Blizz ABS. I am using RPG Maker XP with Blizz ABS 2.84. I am using a custom event trigger that runs a common event to check if the player is sneaking and the enemy has not detected the player, if so, deal bonus damage. I set this to trigger only on Trigger:Weapon=1 which is a dagger. Ideally, I only want daggers and bows to deal bonus stealth damage.
The problem is that the enemy event just disappears, no item drop, no xp gain, no gold. How can I make this so the enemy dies normally with item, gold and xp gain? My suspicion is that it has something to do with the script call to change the enemy's HP I also tried enemy_deal_damage, same thing, no xp, gold or item drop. I think using these script calls to drop the enemy's health ignores the normal death stuff somehow.
Any assistance or advice on how to implement a stealth attack system will be greatly appreciated.

Here is a link to my project in github:
https://github.com/antlaw0/RMXP-Blizz-ABS

The latest commit should be the best example.
If you go to Testing room 2, sneak behind the enemy and hit it with the dagger. You might need to put \move in its name to stop it from moving to make it easier to sneak up on it.

KK20

Not 100% sure what the cause is, but it fails to call this line under event_removal
remove_enemy(event) if !event.valid?

The enemy battler still exists, even after calling $BlizzABS.enemy_deal_damage to kill it. This might be a bug.

But at the same time it kinda makes sense that the enemy wouldn't give anything in return since it doesn't know WHAT damaged it. Like, if you had a map tile that dealt damage and you made it so that you call $BlizzABS.enemy_deal_damage on the enemy when it walks on it, why should it give the player experience? The player did nothing in killing the enemy.

Other Projects
RPG Maker XP Ace  Upgrade RMXP to RMVXA performance!
XPA Tilemap  Tilemap rewrite with many features, including custom resolution!

Nintendo Switch Friend Code: 8310-1917-5318
Discord: KK20 Tyler#8901

Join the CP Discord Server!

CriticalHit

Drat, I was afraid something like that was going on. Yeah, that makes sense that the player would not gain xp, gold because no actor dealt the damage. I will go back to the drawing board and see how I can get this to work. If you have any suggestions, let me know. My last resort is to use the system I have in place where Blizz ABS battle music script turns a variable on and off when the battle music triggers and stops. Then, I have a global parallel process that adds and removes the "stealth" state based on the variables. My only concern with this method is if it will introduce lag.
Again, let me know if you have a better way of doing this.
Thanks.

Blizzard

enemy_deal_damage only deals and processes the damage (e.g. setting up sprites). If I remember right, the removal is done in a global update instead.

There is an alternative solution. You could boost the stats of the player while he's sneaking. e.g. If you increase ATK while they are sneaking, the bonus damage will apply automatically. Of course it's harder to control how much extra damage will be done.
Check out Daygames and our games:

King of Booze 2      King of Booze: Never Ever
Drinking Game for Android      Never have I ever for Android
Drinking Game for iOS      Never have I ever for iOS


Quote from: winkioI do not speak to bricks, either as individuals or in wall form.

Quote from: Barney StinsonWhen I get sad, I stop being sad and be awesome instead. True story.