My game focuses heavily on magic, and learning said magic at intervals Many parts of the game will be story driven, but the action scenes require the use and management of spells. Unfortunately, I've hit a snag that breaks the game's flow. I'm unsure of why this is happening, but I cannot remove spells from my actors temporarily. Here's how it is meant to work;
1. Player selects from 1 of 3 characters
2. Long intro, tutorial boss, first magic class
3. Class starts, your magic is volatile. Splash damage (scripted event cause NPC is dumb and stood close) leads to NPC teaching you a new trick
4. Unlearn your first spell (@>Change Skills: [P1], - [skill 1] {Repeated for P2 and P3, despite not being present})
5. Learn new spell (@>Change Skills: [P1], + [skill 2] {Repeated for P2 and P3, despite not being present})
6.Use new spell, it doesn't do so well.
7. Unlearn Spell 2 (@>Change Skills: [P1], - [skill 2] {Repeated for P2 and P3, despite not being present})
8. Learn Spell 3 (@>Change Skills: [P1], + [skill 3] {Repeated for P2 and P3, despite not being present})
9. Test it, find it's strong but slow
10. NPC tells you that all 3 may have their own uses
11. Secretly add back Spells 1 and 2 without chat notice
12. Player now has all 3 spells available
The problem occurs at steps 4 and 7. Though I use the correct event contents, the spells are not removed via the event, yet the new spells are added without error. This breaks the continuity of my game's progression because I can just spam the first spell.
Is it not possible to remove spells when using SAS IV? Or am I doing something wrong? This method works in the base program without SAS IV, yet not when using the scripts.
[ACE] Sapphire Action System IV: Remove Spell event not working
● ARCHIVED · READ-ONLY
-
-
Can you provide a link to the script?
It will save us having to go searching before we can investigate.
-
And please show us the screenshots of the event code where the actor is supposed to unlearn a skill. Sometimes it's only a minor mistake in the use of the event command which you didn't even know about. (in addition to the script link requested above - but I don't think that the SAS breaks the event command for forgetting skills, most probably it is something else).
It might be that SAS stores the learned skills in it's own data, because it needs to convert them for ON-Map-use anyway - in that case you need to find the script command to update that internal list after you unlearned a skill. But that is the only thing I can think off - scripter usually don't add code to remove functions from the engine, but sometimes they cannot transfer all data to their script structure. -
Sorry, I thought I did post the link. I gotta stop posting early in the mornings lol
http://arcthunder.blogspot.com.br/p/rpg-maker.html
As for a screenshot, the following 12 images are the order I have.
1-3 are the first parts leading up to learning the first new skill, "Deep Wave." EV008 is available right from the start, and killing it starts the next lesson. 4 and 5 teach the next skill. EV011 works exactly the same as EV008, but spawns when the next skill is learned.. It ends with 6 and 7, which should award all 3 skills in the end.











-
I've had a quick look at this, and just used the Khas SAS IV demo that can be downloaded to test it.
Skills can be removed in exactly the way that you have done it, however if that skill is the currently equipped one (visible on the HUD) then it doesn't get removed from there until you cycle through the skills that you have. In the demo, at the point of adding the Tornado skill I got it to remove the Fireball skill that I already had, and the HUD showed the current skill as Fireball, but if I went into the Skills menu (Esc, Skills in the menu) I could no longer see the Fireball skill in my Magia list.
So, the removal is working, but the refresh of the HUD is not as it thinks you still have the skill equipped.
To get around this - but this really only works where you are going to have a single skill replaced with another one like you have - after you add your skills, add a script call with this in it:
$game_player.next_skillThis will change the currently selected skill to the next available one that the player has. It's not overly elegant, but it will work for the situation you are in.
Just don't use the script call when you are adding all the skills back in during your last event, otherwise the player will see the skills change (and that isn't what you are wanting). -
That worked just as I had hoped, thank you!
-
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.