You can try the confused state in the original demo first. If it works I will look into my code, I think my move method and AoE animation plugin may have something to do with this... If it doesn't work in the original demo, I guess it will be very hard to fix...
Yep, just confirmed with the original demo confuse doesn't work. Did mass confuse on a group of enemies and every single one keeps attacking actors anyway. Reset multiple times to see if i had bad luck and same results.
Yep, just confirmed with the original demo confuse doesn't work. Did mass confuse on a group of enemies and every single one keeps attacking actors anyway. Reset multiple times to see if i had bad luck and same results.
i tested the defaultdemo&added charmed state on all units in battle via script,.. Charm woks, they attack theirselfs and their friends. but they always use the normal attack skill..
even if they only have a mage skill in their enemy setup. ( i dont know why they only use attack skill, also i guess "srpg teams" and "AIControll" is needed to avoid attacking theirself if the AIControll Setup is made correctly allowing only to attack the other team )
=>btw the enemy used fire at actors if not charmed
-> if the charm doesnt work, the state setup is probably wrong..
State SETUP Charm
Enemy Setup (only have fireskill) this enemy has also the needed mana,skilltype magic and skill fire added, which is no visible on that img (but if charmed only normal attacks are used)
-confusion has by default the order to attack all units (actor or enemy unit)
-> thats why i used charm ,and "attack friend" in the state setup .. (img in spoiler)
i tested the defaultdemo&added charmed state on all units in battle via script,.. Charm woks, they attack theirselfs and their friends. but they always use the normal attack skill..
even if they only have a mage skill in their enemy setup. ( i dont know why they only use attack skill, also i guess "srpg teams" and "AIControll" is needed to avoid attacking theirself if the AIControll Setup is made correctly allowing only to attack the other team )
=>btw the enemy used fire at actors if not charmed
-> if the charm doesnt work, the state setup is probably wrong..
Enemy Setup (only have fireskill) View attachment 205454 this enemy has also the needed mana,skilltype magic and skill fire added, which is no visible on that img (but if charmed only normal attacks are used)
-confusion has by default the order to attack all units (actor or enemy unit)
-> thats why i used charm ,and "attack friend" in the state setup .. (img in spoiler)
Could you show me the formula I should use for aiTarget note tag for a healing skill? I set <anyTarget> with the Position plugin and <aiTarget: 1 + a.sameTeam(b)> for the note tag (using SRPG_Teams) and the enemy keeps targeting the same 1 actor. And yes, his target rate is the same as everyone else.
no it doesnt require any plugin.. its inspired by it.
I took this code from my plugin and edited a little bit.. (i will double check it ,perhaps i made a mistake..)
Edit info i checked it 3times:
1. using the code in a parrallel event which deletes itself, at map start. Has problems with the "dmg.popup"-part (probabbly because its triggered to early)
2. using this a little bit later triggered by
JavaScript:
<type:playerEvent>
// i often use this one when testing stuff
works fine.
3. Using it in the same "<type:turnEnd>" Event like you did.. works fine.. (i used state nr 3 instead,but that should not be the problem)
=> If it doesnt work for you pls hit f8 after the turn end, and make a screenshot if there is any error
EDIT 2 Perhaps this is the problem in your Setup?
I am not sure if that makes so much difference ,but i got no other Idea at the moment View attachment 205243
------------- @moldy
you could also try to add the "deathState" if its not added from having 0 hp..
if that doesnt work pls try to explain more detailed what you are trying to do and at what timing.
I tested again witch yours sugestions and the damage is executed, but not work the timing and the focus in the enemy/actor showing the damage. Pressing F8 not showing any erro for some reason...
Using the SRPG_MoveAfterAction gave me a idea for a system when the player use a attack or a skill, the command will be disappear, because is quite confuse for the player after attack can move, showing the attack command again.
I know little about javascript, so I tried to solve the issue in another way. Using the BOB_BattleCommandList edited by waynee95(post), is possible to create conditions in the commands, so I made a condition when the skill is used with Yanfly_SkillCore, result in determinated switch off (need switch off because how work the plugin) like this:
<Custom Execution>
$gameSwitches.setValue(switch, false);
</Custom Execution>
The class setup needs to be configured like this(is possible use other conditions, the plugin explain):
<Battle Commands>
Attack!{s[switch]}
Skills!{s[switch]}
Wait
</Battle Commands>
In the battleStart and endTurn is necessary reset the switch for true, so the commands will be showing again in the next turn.
Another thing: because of how SRPG_core works, it is necessary to add this script inside the BOB_BattleCommandList in this part for the Wait command to appear to the players:
JavaScript:
Window_ActorCommand.prototype.processCommandEntry = function(cmd) {
switch (cmd.command.toLowerCase()) {
case "attack":
return this.addAttackCommand();
break;
case "skills":
return this.addSkillCommands();
break;
case "guard":
return this.addGuardCommand();
break;
case "items":
return this.addItemCommand();
break;
case "wait":
return this.addWaitCommand();
break;
case "skill":
return this.addCustomSkillCommand();
break;
case "item":
return this.addCustomItemCommand();
break;
case "stype":
return this.addSkillCommand();
break;
case "stypes":
return this.addMultiSkillCommand();
break;
case "skillfirst":
return this.addFirstSkillCommand();
break;
case "skilllast":
return this.addLastSkillCommand();
break;
case "itemfirst":
return this.addFirstItemCommand();
break;
case "itemlast":
return this.addLastItemCommand();
break;
default:
return false;
break;
}
return false;
};
The other alternative is just making a hidden status that blocks the attack and skill. This status would be inflicted on the actor who uses a skill and on turnEnd it would be enough to remove the status. This alternative does not hide the command, it just blocks it, however.
If anyone has a more simpler alternative, I would appreciate it.
Could you show me the formula I should use for aiTarget note tag for a healing skill? I set <anyTarget> with the Position plugin and <aiTarget: 1 + a.sameTeam(b)> for the note tag (using SRPG_Teams) and the enemy keeps targeting the same 1 actor. And yes, his target rate is the same as everyone else.
no i cant, i already explained that my skill with the AIControll plugin is very low,i can only advice to read what doctor Q wrote about it in this thread & studying the plugin help info. The problem is that i never used it much aswell as more complicated battle formulas..
about the charm formula
But i guess that this can be solved by puting the right setup into the "target formula" from the AIControll param. (which is by default 1)
=> it should be something like : (thats only the context but i dont know the formula for that)
"from both teams "actor" & "enemy" ,check what team the user is and attack units of the other team..if "true" resulting in 1"
-------------------------
about your error:
"isAnimationPlaying of null" and the "waitmode" stuff.. sounds like its related to a mapEvent.. (or Battler if thats in SV mode ,but i think its about the event)
in other words i guess for whatever reason the system cant get the EventID, of the Event that should play an Animation. The waitmode stuff is part of the default "waiting for the animation to end" codechain..
@dopan could you check ActorUnit.js again? I added 2 new members to the party in the same test map I've been using and the last member ID isn't being saved (similar to when Harold the 1st actor wasn't being saved). I switched variables to different # to double check and the same thing keeps happening. and I made sure this.allAxSetEventID(); is properly called when they join the party
@dopan could you check ActorUnit.js again? I added 2 new members to the party in the same test map I've been using and the last member ID isn't being saved (similar to when Harold the 1st actor wasn't being saved). I switched variables to different # to double check and the same thing keeps happening. and I made sure this.allAxSetEventID(); is properly called when they join the party
@moldy I am trying to explain more detailed how the plugin works, perhaps that helps you to find out whats wrong in your project..
The plugin seems to be fine, i also tested it in a project..
Every Unit needs an "eventID_variable" and a "disable-switch" added to the plugin param setup.
When i summon Units, this happen with the action of a skill.. so i use the "Battlestart" & event "after action" to trigger the plugin Scriptcalls..
When you check your Variables to find out if it works, also check the related Switches: A correctly working Unit has the event_ID number in the Variable,
and the "disable_switch" must be "Off".
While Units that are not on map have no eventID(=0) stored in the variableValue
and "disable_switch" set to "On"
The scriptcall "this.allAxSetEventID();" only works for Units that have : - "disable_switch" , "On".
- no eventID(=0) stored in the variable ("this.allAxSetEventID();" will add the event ID into the variable & set the switch to "Off")
because the plugin only should add Units that are new , thats why the Plugin Command "SRPG_ActorUnits Reset" exist. -> it sets the switches to "ON" and variablesValue to 0 (in order to reset everything so that the "this.allAxSetEventID();" can work properly)
edit
the "check ID" scriptcall is used incase that some Units have already added EventID in the Variable,but still Switch to "ON"..
If thats the case the related Switch will be set to "OFF"
-> thats because i used also other ways to add the event id into the Variable,but without changing the Switch.. (by eventing on the Events of the Units itself)
=> so in most cases that scriptcall is not needed
@moldy I am trying to explain more detailed how the plugin works, perhaps that helps you to find out whats wrong in your project..
The plugin seems to be fine, i also tested it in a project..
Every Unit needs an "eventID_variable" and a "disable-switch" added to the plugin param setup.
When i summon Units, this happen with the action of a skill.. so i use the "Battlestart" & event "after action" to trigger the plugin Scriptcalls..
When you check your Variables to find out if it works, also check the related Switches: A correctly working Unit has the event_ID number in the Variable,
and the "disable_switch" must be "Off".
While Units that are not on map have no eventID(=0) stored in the variableValue
and "disable_switch" set to "On"
The scriptcall "this.allAxSetEventID();" only works for Units that have : - "disable_switch" , "On".
- no eventID(=0) stored in the variable ("this.allAxSetEventID();" will add the event ID into the variable & set the switch to "Off")
because the plugin only should add Units that are new , thats why the Plugin Command "SRPG_ActorUnits Reset" exist. -> it sets the switches to "ON" and variablesValue to 0 (in order to reset everything so that the "this.allAxSetEventID();" can work properly)
edit
the "check ID" scriptcall is used incase that some Units have already added EventID in the Variable,but still Switch to "ON"..
If thats the case the related Switch will be set to "OFF"
-> thats because i used also other ways to add the event id into the Variable,but without changing the Switch.. (by eventing on the Events of the Units itself)
=> so in most cases that scriptcall is not needed
I figured out what happened. All my set up was correct, as all other units besides the one had their variables updated. I tried fiddling with my map to see what was happening, so I decided to use Event Commands to move the event that I wanted to turn into the "missing actor". When I used the drop down menu in my event command to select that event so I can move it, I noticed it was gone. My list of event ID's that I was allowed to move was 1 less than the event ID I was looking for (it wasn't listed!) so I "cut" the event from my map and repasted it, and it updated its event ID from 32 to 22 now. So now everything works and his variable ID has been saved now. To anyone reading this, if you run into any issues with ActorUnits.js, be mindful that RPG Maker MV handles event IDs weird if you delete any events (especially premade ones that came with the demo) so make sure your event IDs are updated! The plugin works as intended, RPG Maker just has a weird way of handling Event ID's in real time. Sometimes the map keeps straggler events that should be deleted and remade so it gets a "valid" event ID.
I figured out what happened. All my set up was correct, as all other units besides the one had their variables updated. I tried fiddling with my map to see what was happening, so I decided to use Event Commands to move the event that I wanted to turn into the "missing actor". When I used the drop down menu in my event command to select that event so I can move it, I noticed it was gone. My list of event ID's that I was allowed to move was 1 less than the event ID I was looking for (it wasn't listed!) so I "cut" the event from my map and repasted it, and it updated its event ID from 32 to 22 now. So now everything works and his variable ID has been saved now. To anyone reading this, if you run into any issues with ActorUnits.js, be mindful that RPG Maker MV handles event IDs weird if you delete any events (especially premade ones that came with the demo) so make sure your event IDs are updated! The plugin works as intended, RPG Maker just has a weird way of handling Event ID's in real time. Sometimes the map keeps straggler events that should be deleted and remade so it gets a "valid" event ID.
To be honest, this simple thing doesn't worth a plugin with 3000 lines of code. I hope Dopan could think of more possible ways to do things before using any brute-force approach...
To get the event id of an actor simply use $gameActors.actor(actorId).event().eventId();
Maybe you will also need to check if the actor is assigned to an event, to avoid error when calling the .eventId(), but that's pretty much it...
Basically: $gameActors.actor(actorId) give you the actor with corresponding actor id, the actor has a method .event() (implemented in srpg core at Game_Actor.prototype.event) which gives you the corresponding event.
To get the event id of an actor simply use $gameActors.actor(actorId).event().eventId();
Maybe you will also need to check if the actor is assigned to an event, to avoid error when calling the .eventId(), but that's pretty much it...
Basically: $gameActors.actor(actorId) give you the actor with corresponding actor id, the actor has a method .event() (implemented in srpg core at Game_Actor.prototype.event) which gives you the corresponding event.
Thanks, Shou. Are you good with the AiControl + Teams combination of plugins? I've been banging my head on the desk trying to get this to work and I feel so close. I have a healing skill that targets anyone because I want a charm state to allow for skill usage and it works (sometimes). Here's my skill note tag
<aiTarget: a.sameTeam(b) ? 2-b.hpRate() : 0>
If on the same team, heal the target with the least HP. Ignore targets who aren't in your team. The enemy seems to exclusively heal my team when she's not even charmed. I've tried swapping the values between the colon and get the same result. My basic Attack skill has pretty much the same formula and seems to work perfectly so far, so I'm utterly lost with this. Maybe @NatePlays can chime in too, he seems to have a good grasp of the plugin too
I should also mention I am using Nate's AiControl patch
Thanks, Shou. Are you good with the AiControl + Teams combination of plugins? I've been banging my head on the desk trying to get this to work and I feel so close.
I can take a look this weekend. It's going to take some time. If you don't mind you can share with me your project, or a project for the test, with the same note tags, skills, and plugins. That will make debugging much faster.
To be honest, this simple thing doesn't worth a plugin with 3000 lines of code. I hope Dopan could think of more possible ways to do things before using any brute-force approach... To get the event id of an actor simply use "$gameActors.actor(actorId).event().eventId();" Maybe you will also need to check if the actor is assigned to an event, to avoid error when calling the "eventId()", but that's pretty much it...
(...)
Another way to get the Event ID of an Actor and checking if the Actor is assigned to an Event,is:
JavaScript:
// This Returns the Event ID based on the Actor ID
//----------------------------------------------------------------------
$gameSystem.ActorToEvent(ActorID);
// Incase the Actor isnt in srpgBattle it will return 0
// incase the Actor is in battle & deathState affected,it will still return the event id..
// deathState affeted Units have Event with the status "erased",
// but the eventID is still there & can be used to revive Units for example..
-> this way it needs only a simple if condtion that asks if the EventID of the Actor is bigger than 0
JavaScript:
if ($gameSystem.ActorToEvent(ActorID) > 0) { put execution order stuff here };
//example with add state:
if ($gameSystem.ActorToEvent(ActorID) > 0) {
$gameSystem.EventToUnit($gameSystem.ActorToEvent(ActorID))[1].addState(StateID))
};
// pls note "$gameSystem.EventToUnit(EventID)[1].addState(StateID);"
// needs a valid event ID other than 0, thats solved with the "if condition"
// also this Example still needs a State ID,
// but however this way we can use Actor ID instead of Event ID
.. the ActorUnits plugin has so much lines because it stores so much Gamevariables&GameSwitches. I used them for several skills like revive & other stuff.. also these were the first plugins i made, and i am planing to rework them anyway..it wasnt brute force, i just didnt know much about JS^^ => however i still preffer to use GameVariables&Switches at the moment even if its pretty easy to handle Actor Units aslong they are NOT cloned
SideNote: $gameActors.actor(actorId).event().eventId(); should work similar and return 0 if the unit is not in battle & has no event used
Edit-Info: So why do we have to 2 Functions in the SRPG Core that do the same thing? -> as far i understand it:
- both Function work a bit different ,but resulting in the same thing
- $gameSystem.ActorToEvent(ActorID); is Part of the Default SRPG Core
- $gameActors.actor(actorId).event().eventId(); is Part of the "mapBattle Part" in the SRPG Core which was made by DrQ - In that Case,i guess DrQ needed such Function for his Mapbattle Plugin and didnt recognized that the srpgCore has already a similar function..
-> Or the other Function didnt work in a seperated Plugin when Mapbattle plugin was made..
SideNote: (i recognized similar things a few times, like check death with "isDead" or "isAlive" ) ->Using "!" at the beginning of code, means "Not".. .. so we just need one of those two, but we have both and both work^^
I can take a look this weekend. It's going to take some time. If you don't mind you can share with me your project, or a project for the test, with the same note tags, skills, and plugins. That will make debugging much faster.
@dopan I forgot to ask about MapStateOverlay, for some reason line 120 is causing issues when I boot the game at start up
Code:
//Dopan INFO=> edited part starts here, stuff above is the Default Function Content
if ($gameSystem.isSRPGMode() == true) { //Game crashes at start up because of this line for some reason
if (SceneManager._scene instanceof Scene_Menu === true) {
_checkSOS = false;
}
if (SceneManager._scene instanceof Scene_Battle === true) {
_checkSOS = false;
}
if (SceneManager._scene instanceof Scene_Map === true) {
if (_checkSOS === false) {
Game_Interpreter.prototype.srpgStateOverlay.call(this);
_checkSOS = true;
}
}
}
};
@dopan I forgot to ask about MapStateOverlay, for some reason line 120 is causing issues when I boot the game at start up
Code:
//Dopan INFO=> edited part starts here, stuff above is the Default Function Content
if ($gameSystem.isSRPGMode() == true) { //Game crashes at start up because of this line for some reason
if (SceneManager._scene instanceof Scene_Menu === true) {
_checkSOS = false;
}
if (SceneManager._scene instanceof Scene_Battle === true) {
_checkSOS = false;
}
if (SceneManager._scene instanceof Scene_Map === true) {
if (_checkSOS === false) {
Game_Interpreter.prototype.srpgStateOverlay.call(this);
_checkSOS = true;
}
}
}
};
EDIT I figured it out, my Github had an older buged Version, and i must have forgoten to upload the Final Version..sry. (or i uploaded the wrong version in the first place idk) The line you mentioned should NOT be there. (funfact line 120 is empty in my projects Version,
that gave me the hint to compare both Versions again)
EDIT I figured it out, my Github had an older buged Version, and i must have forgoten to upload the Final Version..sry. (or i uploaded the wrong version in the first place idk) The line you mentioned should NOT be there. (funfact line 120 is empty in my projects Version,
that gave me the hint to compare both Versions again)
Works great! I had some issues getting it to work initially thanks to our good old Event-IDs-Not-Updating problem again from my last post lol. It's a good thing I discovered that annoying bug since that's the first thing that came to mind. If there's any way to force events to fill in any missing event numbers via plugin or any other way, let me know.
Repeat PSA for any readers out there: If anyone has issues with plugins/script code that require looping through all event on maps, be sure to check your event ID's once again! What I did (kinda tedious) is make a list in notepad of the event numbers currently on the map by double clicking each and every one of them and take note of any missing event ID numbers you come across. In my case, event IDs 16 and 28 were unaccounted for (due to me deleting and creating events), so I made 2 blank events on the side of the map, the game assigned ID 16 and 28 to them to fill in the gaps, and that did the trick!
SIDE NOTE: Anyone been able to get StatBasedCounter to work? I don't want all my units to counter unless they have a passive (that adds cnt to their stats). I've verified all my units have 0% counter rate and counter still activates.
Works great! I had some issues getting it to work initially thanks to our good old Event-IDs-Not-Updating problem again from my last post lol. It's a good thing I discovered that annoying bug since that's the first thing that came to mind. If there's any way to force events to fill in any missing event numbers via plugin or any other way, let me know.
Repeat PSA for any readers out there: If anyone has issues with plugins/script code that require looping through all event on maps, be sure to check your event ID's once again! What I did (kinda tedious) is make a list in notepad of the event numbers currently on the map by double clicking each and every one of them and take note of any missing event ID numbers you come across. In my case, event IDs 16 and 28 were unaccounted for (due to me deleting and creating events), so I made 2 blank events on the side of the map, the game assigned ID 16 and 28 to them to fill in the gaps, and that did the trick!
SIDE NOTE: Anyone been able to get StatBasedCounter to work? I don't want all my units to counter unless they have a passive (that adds cnt to their stats). I've verified all my units have 0% counter rate and counter still activates.
if you put the cursor at an event it shows the id and x y data info..
Events do always use the left-open event ids, if for example event 3 is missing and the highest event is 9.The next event will be 3 and after that the next one will be 10 (thats why we used "placeholder"- events)
about statbased counter: this needs the counterstat and ist NOT compatible with agi extra +. (check if "agi_extra_+" is still active)
Isnt agi+ built into the core? I have that setting turned off already in parameters
Also I know how to get an event ID, I was just saying the game doesn't account for when you delete an event with an ID that happens to be sandwiched between 2 others. For example, lets say you have 30 events and you decide you dont want an enemy on the map anymore so you delete its event with an ID of 15, the game doesn't assign another event ID 15 so there's a gap in the "length" of the events, so anytime you try to loop through the events, it doesn't do it properly. The second you replace event id 15 (by creating a blank new one), the game does the for loop properly. Test it out with your map overlay plugin. Delete an event that isn't first or last on the ID list, then use a status effect on an enemy whose ID is greater than the event you deleted, and it suddenly doesn't work.
I'm not sure what's your need for this plugin? change counter-attack skill or use the direction to determine counter rate? If you need the latter I don't think it will work with my AoE animation or agi attack control, you will need to do direction checks in the agi attack control--agi attack formula.
Alright, I have other aesthetic thing that I want to do.
how I do get rid of this stats window, so it doesn't show up when I click on an actor?
I also want to know if it's replacable with static images for each actor
I'm not sure what's your need for this plugin? change counter-attack skill or use the direction to determine counter rate? If you need the latter I don't think it will work with my AoE animation or agi attack control, you will need to do direction checks in the agi attack control--agi attack formula.
I'm not concerned with directionals really, I just want it so only certain units can counter attack. The problem is, agi attack+ has been active this whole time (even though I turned it off in the plugin parameter) and thought it was triggering counter attack anyway.
Basically I want to *completely* remove the function of agility where "whoever has higher agility will strike first".
Lunesis has started a trend of doing homages to me by putting a trilobite fossil in your game somewhere and I have to say I love this and encourage everyone who wants to credit me to do it too. XD
Rebuilding isn't going terribly so far. I caught some things that I was definitely overcomplicating in the original project. Here's to hoping the plugins play nice when testing starts.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.