RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
[XP] Monster behaviour help

0 Members and 1 Guest are viewing this topic.

**
Rep: +0/-0Level 86
Hello, I've made made a boss in my game and have an event where if his HP falls below 50% he starts using a skill. Now my problem is, when he uses up all his SP he still is able to "Select" the skill from his movelist but then cannot perform it, wasting a turn. I'd like to know if there's a way I can make it so that when he runs out of SP, a switch that enables him to use the skill is turned off. That or any similar solution would be much appreciated.

Thanks for your time.

****
Irock touched your custom title
Rep:
Level 89
I haven't actually done any common events programming so I don't know exactly how it's typed out. I'll type out what should work though in something similar to BASIC. You'll ahve to translate it into a common event.

What you have now
(HP = Current HP ~~ THP = Total HP)
If HP < .5 * TPH then
   Use skill
end if


What you should have
(Let's assume you need 50 SP to preform the move)
If HP < .5 * THP then
   If SP > 49 then
      use skill
   end if
end if


If I'm completely wrong please say so. I should get around to programming common events though so I can actually help properly. <_<

*
A Random Custom Title
Rep:
Level 96
wah
I've never been able to have a common event work in a battle, however.

**
Rep: +0/-0Level 86
Thank you, but I'm not sure how to apply to the monster. Its the right idea but I'm not very good at scripting so I can't seem to get it to work.

So far what I have is for its Behavior is:
Attack, No Preconditions, Rating 5
Big Slash, Switch [00017: Big Slash] is ON, Rating 5

On the Battle Events tab for the monster group I have:
Trigger: Monster [23. Blade Master]'s HP is below 50%       Frequency: Start Battle
Switch: [00017: Big Slash] = ON

Sorry for the trouble but I'm not sure of what to do now.

***
Rep:
Level 87
Things we fear the most have already happened 2 us
You can add another BATTLE EVENTS TAB to that monster group and have:

---------------------
Trigger: SWITCH [00017: Big Slash] = ON       Frequency: MOMENT (or whatever the translation says,,you know something that keeps repeating as long as the conditions are met)
---------------------
---------------------
Set Variable: [00001: Blade Master SP] = Blade Master's SP
If [00001: Blade Master SP] <= 0
Switch: [00017: Big Slash] = OFF
---------------------


And I assume that this BATTLE EVENT:
Trigger: Monster [23. Blade Master]'s HP is below 50%       Frequency: Start Battle <--- happens just once per battle i believe.
Switch: [00017: Big Slash] = ON

only happens once per battle.
"If u'r about to die,,then think of how good ur life has treated u up to this point.  On the
other hand,,if life hasn't treated u good up to this point,,then take joy in the fact that
it's not going to bother u for much longer."

**
Rep: +0/-0Level 86
Thank you!

********
Shadow Knight
Rep:
Level 91
Ruin that brick wall!
Project of the Month winner for October 2008
[Resolved]
Be kind, everyone you meet is fighting a hard battle.