Enemy AI State (Ace)

● ARCHIVED · READ-ONLY
Started by Mr. Bubble 15 posts View original ↗
  1. Enemy AI State (Ace)


    Original VX Script by Mithran


    Ported to VX Ace by Mr. Bubble


    Summary


    This script makes an actor mimic the Action Patterns of an enemy by using a state. When the state is inflicted, the character will auto-battle using the Action Patterns of the enemy specified by the state. Certain enemy actions can be excluded altogether.


    Script


    Get it here: http://db.tt/oPQSKYDK


    Credits & Thanks


    Thanks to Mithran for the original script and giving permission to port over to Ace. Please do not redistribute without asking.
  2. Very interesting script, i will test it in my project.
  3. CWells said:
    Hello, I was working on using the auto-battle script by Mithran as ported to VX ace by Mr. Bubble. And after adding the

    enemy ai to my auto-battle state, I get this

     

    Game_action' line 100: NoMethodError occurred.

     

    undefined method 'for_dead_friend?' for nil:NilClass

     

    and the battle test crashes. What does this mean?
     

    It means that Game_Action#item is returning nil.

     

    Standard questionnaire:

     

    Are you using other custom scripts? If so, what are they? How do you know it is or isn't a script compatibility issue? Can you isolate the culprit script if you are using other custom scripts?
  4. Mr. Bubble said:
     

     

    It means that Game_Action#item is returning nil.

     

    Standard questionnaire:

     

    Are you using other custom scripts? If so, what are they? How do you know it is or isn't a script compatibility issue? Can you isolate the culprit script if you are using other custom scripts?
    It wasn't until I applied your script that this error message occurred, Which led me to believe that it was this auto-battle script causing the problem. However, I am using other scripts as well. Since this state, the auto battle state should be applied instantly to some actors given the type of game I am making, I have used the auto-effect script from Tsukihime to apply this state directly to characters that are meant to be auto-battle only. So I have Tsukihimes Effect Manager.

    I did not place your script below Tsukihimes Effect Manager though because your script is different.

    This auto-battle script is a biggie for my project. I hope I can get this working. I am going to see what happens when I push your script under Tsukihime's Effect Manager...

    Nope. No change when I move the scripts around. i still have the error.
  5. Link to the scripts you're using please.
  6. It wasn't until I applied your script that this error message occurred
    ofc, becoz it was most probably that this script is incompatible with other scripts ur using...

    Since it relies on Tsukihime's script, you can still try to put it below tsukihime's script...

    btw, what are ALL of the custom scripts that ur using? especially the battle related ones
  7. @Mr. Bubble: Looked at the script... I have a question: Is it fine not to have Game_Battler not inherit Game_BattlerBase?

    @CWells: have you tried running it on playtest rather than battle test?
  8. CWells said:
    Sorry it was taking me a while to find my other one:

    http://www.rpgmakervxace.net/topic/7596-auto-states/

    And this one:

    http://himeworks.wordpress.com/2013/06/20/effect-reflect-damage/

    That's it. There are no more custom scripts other than these. Tsuki so far has been so helpful with all of these scripts.
    I've updated the script to v1.01.

    It was a compatibility issue with the Auto-States script. I don't know what the exact problem was, but I was able to check for the error and avoid it. It looks like everything works fine, but more testing is needed.

    Please remember to provide all pertinent information next time you ask for help.

    adiktuzmiko said:
    @Mr. Bubble: Looked at the script... I have a question: Is it fine not to have Game_Battler not inherit Game_BattlerBase?
    A VX remnant I didn't notice in the conversion since there's no Game_BattlerBase in VX. It doesn't produce errors and I'm not referencing anything outside the scope of Game_Battler in that section. I don't know if there are side-effects, but I've fixed it regardless.
  9. So far things are indeed better thank you.

    After some time mixing and matching with an enemy. Changing skills and testing action patterns. It isn't that much different from normal auto-battle. I am not seeing my enemy state Actor use any support abilities on its own at all. It will do the basic guard and attack but everything else that has to do with other kinds of state actions or common event skills, it will not use them. I would love to see the AI pay more attention to these sorts of things too, especially the support skills. Maybe in future versions if you work on it some more, this could be an addition?
  10. Mr. Bubble said:
    Enemy AI State (Ace)

    Original VX Script by Mithran

    Ported to VX Ace by Mr. Bubble

    Summary

    This script makes an actor mimic the Action Patterns of an enemy by using a state. When the state is inflicted, the character will auto-battle using the Action Patterns of the enemy specified by the state. Certain enemy actions can be excluded altogether.

    Script

    Get it here: http://db.tt/oPQSKYDK

    Credits & Thanks

    Thanks to Mithran for the original script and giving permission to port over to Ace. Please do not redistribute without asking.
    This script is indeed awesome and has been such great use for me. And yet there is one thing that has just come up when finally putting in all the meat to my actors and enemy states.

    They will not use skills that require TP use.

    I did several tests to see what the issue is. My last guess is it must be the scripted state to use Enemy AI. Here is what I did:

    First, I tried just giving the actors the enemy AI states with the desired skill set. I noticed they were not casting certain skills. I checked various things, even removed all the skills they would cast to see if it would increase the odds of them using the ignored skills. They did not do anything.

    I then checked the skills, noticed they all required TP for use. I changed the TP to MP and finally they started casting. But this means that in order for any character, enemy or not, to use a skill like an uppercut, or a charging attack which wouldn't require MP, so long as I have this scripted state applied, I would have to make it use up MP.

    I then checked to see what an enemy would do without your script. Just a normal enemy. They were casting their TP skills with no problem.

    So if I applied the enemy state to an actor, they would completely ignore TP. If a default enemy were to use the TP using skills, they would do so just fine...
  11. So this thread has been untouched for... quite a while ... So I've been having some issues with the script. When I use the skill that gives you a state that has
    <enemy ai: 200> - this in it's note it gives out this error - if anyone knows how to fix it please tell me .
    Also here is the game : https://www.dropbox.com/s/fo55rd74oknwj94/Five Nights at boy's Delivery.rar?dl=0
    The skill using the state : Full Moon , The state : Lunatic

    Please answer as soon as possible
  12. This indicates you have probably added an enemy to a troop, but then deleted them from the enemy tab.