CLAVISANIMA'S PROFILE
Search
Filter
[RMVX ACE] [RGSS] State that seals learned skills until recovery
Thank you, that clears up a lot for me!
Btw I didn't know State was a class of its own. I tried searching for a class like it in the script editor but I couldn't find anything. Maybe I'm not searching for the right thing but are there any other classes like it that I should know about?
I also think that setting a state to seal the skills might be a challenge. I might look at some scripts that deal with states and maybe that'll help me get some ideas for tacking those questions.
For the game I intended to make this script for, I might have to use a different method to achieve the effect I'm looking for since I'm working on a deadline and I realise that I wont be using the feature that much. Nonetheless, I'll keep working on this script as a side project just in case I might need it for another game. I'll try and post updates as I work on it. Thanks again Marrend for your help ^^
Btw I didn't know State was a class of its own. I tried searching for a class like it in the script editor but I couldn't find anything. Maybe I'm not searching for the right thing but are there any other classes like it that I should know about?
I also think that setting a state to seal the skills might be a challenge. I might look at some scripts that deal with states and maybe that'll help me get some ideas for tacking those questions.
For the game I intended to make this script for, I might have to use a different method to achieve the effect I'm looking for since I'm working on a deadline and I realise that I wont be using the feature that much. Nonetheless, I'll keep working on this script as a side project just in case I might need it for another game. I'll try and post updates as I work on it. Thanks again Marrend for your help ^^
[RMVX ACE] [RGSS] State that seals learned skills until recovery
author=Marrend
A state can have a feature that seals specific skills, or a skill category, with no additional coding. The tricky part is where you're sealing a certain number skills at random, given a skill category. I haven't quite figured out all the details, but, I do have...def sealrandomskills(actor, num, stype_id) if actor.added_skill_types.include(stype_id) disable_array = [] i = 0 while i < actor.skills.size skill = actor.skills[i] if skill.s_type == s_type disable_array.push(skill) end i += 1 end if disable_array.size <= num #feature = RPG::Feature.new(code, data_id, value) # "code" variable can be looked up via Game_BattlerBase # FEATURE_STYPE_SEAL = 42; FEATURE_SKILL_SEAL = 44 # "data_id" variable is, probably, in this case, either the skill, or # skill cateogry, to seal. # No clue what "value" would be in this case. Doing nothing will set # it to 0, so, maybe doing nothing is what should be done? feature = RPG::Feature.new(42, stype_id) else #later end end end
...this?
Thanks for the reply and the explanations ^^
I'll keep those variables in mind. If you don't mind me asking, how would you go about writing a script call for this? Every time I write something like $Game_CustomStateEffects.sealrandomskills(actor, 3, 1) I receive a syntax error.
[RMVX ACE] [RGSS] State that seals learned skills until recovery
Hey all,
I'm a bit stumped atm. I have a very basic knowledge of RGSS3 and I was wondering if anyone could help me learn how to go about forming a script.
Here is an idea of what I'd like it to do but I'm not sure is this is a good way to go about it:
I'm a bit stumped atm. I have a very basic knowledge of RGSS3 and I was wondering if anyone could help me learn how to go about forming a script.
Here is an idea of what I'd like it to do but I'm not sure is this is a good way to go about it:
class Game_CustomStateEffects < Game_BattlerBase #---- # seal skills # - disable learned skills based on specific or random SkillID or TypeID # - disable a specific number of skills #---- # def get_learnedskills #checks all currently learned skills and their type end def sealskill (SkillID) #disables specific skill based on ID end def sealskilltype (SkilltypeID) #disables skill type based on ID end def sealrandomskill (x,SkilltypeID) #seals x number of skills at random, limited to type end end
Push / Pull objects (no-script method)
I managed to get it working when moving forwards and backwards by applying your idea when the player is facing certain directions: I used a conditional branch that reads the terrain ID (if terrain ID is 0/ not 1, the player will not move). This branch is only used when the player is facing certain directions whilst moving the box. For example, if the down button is pressed, the conditional branch is only used for when the player is facing up and vice versa when up was pressed. This allowed the player to move forward with the box if they were standing one tile away from the passable tile.
I still have yet to try this out when moving sideways, but I'm sure it will work if I apply the same principles.
Edit: Yup, it definitely works sideways too. My only problem now is that there's a delay when pulling.
Edit 2: I realised that the delay was caused by a 'wait until movement finishes' when the player is pulling the box. Everything works great now :)
Here's a snippet of the event for anyone who's interested:

I still have yet to try this out when moving sideways, but I'm sure it will work if I apply the same principles.
Edit: Yup, it definitely works sideways too. My only problem now is that there's a delay when pulling.
Edit 2: I realised that the delay was caused by a 'wait until movement finishes' when the player is pulling the box. Everything works great now :)
Here's a snippet of the event for anyone who's interested:

Push / Pull objects (no-script method)
This makes sense. It seems to be working quite well so far when the player is pushing an object.
Though, I have no idea how to implement this when a player is pulling an object. Since pulling involves the player having to step away from the object before the object moves, the variables for the event id won't be read until after the player has moved away from the object.
Here's a short snippet of my event page. Pushing down on the block works fine as expected, however pulling doesn't do anything at all. I had tried switching the object move event with the player's move event, however this causes a delay before the object moves and the player is unable to move further than one tile down.

Though, I have no idea how to implement this when a player is pulling an object. Since pulling involves the player having to step away from the object before the object moves, the variables for the event id won't be read until after the player has moved away from the object.
Here's a short snippet of my event page. Pushing down on the block works fine as expected, however pulling doesn't do anything at all. I had tried switching the object move event with the player's move event, however this causes a delay before the object moves and the player is unable to move further than one tile down.

Push / Pull objects (no-script method)
Hi again,
I was wondering if there was a way of making sure that the player stops moving when the box/object is unable to move.
So here's the scenario: I have coloured boxes that only move along paths of the same colour (red boxes move on red paths, blue boxes move on blue paths). The boxes cannot move out off the path. I was able to get this to work using a TheoAllen's Passability Terrain Script.
The problem is that the player will still be able to move in the direction that the box cannot move. I could make contact events where the player can't move in certain directions if the box is unable to move, however I think that method would be inefficient.
I attempted to make it so that the player stops moving when they step on a certain region, however, this makes it so that they cannot move the box at all.
I was wondering if there was a way of making sure that the player stops moving when the box/object is unable to move.
So here's the scenario: I have coloured boxes that only move along paths of the same colour (red boxes move on red paths, blue boxes move on blue paths). The boxes cannot move out off the path. I was able to get this to work using a TheoAllen's Passability Terrain Script.
The problem is that the player will still be able to move in the direction that the box cannot move. I could make contact events where the player can't move in certain directions if the box is unable to move, however I think that method would be inefficient.
I attempted to make it so that the player stops moving when they step on a certain region, however, this makes it so that they cannot move the box at all.
[RMVX ACE] Galv's timed button attacks: Evading states on successful button press
I am currently using Galv's Timed Button attacks. I need help in implementing a feature where the % rate chance of applying a state changes when a button is successfully pressed. The process I came up with was a little like this:
STATE_DEF_RATE = x
STATE_ATK_RATE = x
class RPG::BaseItem
def state_change_r
if @state_change_r.nil?
if @note =~ /<statechange(.*)>/i
@state_change_r = $1.to_i
else
if defending is active
@state_change_r = STATE_DEF_RATE
else
@state_change_r = STATE_ATK_RATE
end
end
end
end
end
class Game_BattlerBase
def state_rate
if state_change_r = value
state_rate = desired rate value
else
normal state_rate value specified in database menu will be applied
end
end
end
I'm a beginner at Ruby scripting, and this attempt only resulted in a lot of NoMethodErrors.
I have asked Galv about making a few edits to the script. Unfortunately, Galv is no longer working on the script.
You can view the working edited version of the script here: https://pastebin.com/ZzrZ2x84
This is Galv's original version https://galvs-scripts.com/galvs-timed-button-attacks/
STATE_DEF_RATE = x
STATE_ATK_RATE = x
class RPG::BaseItem
def state_change_r
if @state_change_r.nil?
if @note =~ /<statechange(.*)>/i
@state_change_r = $1.to_i
else
if defending is active
@state_change_r = STATE_DEF_RATE
else
@state_change_r = STATE_ATK_RATE
end
end
end
end
end
class Game_BattlerBase
def state_rate
if state_change_r = value
state_rate = desired rate value
else
normal state_rate value specified in database menu will be applied
end
end
end
I'm a beginner at Ruby scripting, and this attempt only resulted in a lot of NoMethodErrors.
I have asked Galv about making a few edits to the script. Unfortunately, Galv is no longer working on the script.
You can view the working edited version of the script here: https://pastebin.com/ZzrZ2x84
This is Galv's original version https://galvs-scripts.com/galvs-timed-button-attacks/
[RMVX ACE] States still added when skill misses

Here's a picture of the skill page.
I found a thread with a similar problem here: https://forums.rpgmakerweb.com/index.php?threads/attack-state-applying-on-miss.62488/ but no solution was found on that thread :(
Edit: even increasing EVA and LUCK won't cause the states to miss when an attack misses.
Edit 2: Ok I don't know what I did, but after playing around with it a bit more, I managed to fix the problem.
[RMVX ACE] States still added when skill misses
Hi all,
I have a skill which inflicts damage and a state. Whenever the skill misses, the state is still applied to the target.
This happened again when I opened up a new project, confirming that none of the scripts I'm using is causing the issue. This seems to be a flaw of the engine.
Any ideas for fixing this? I assumed that making a script for changing Game_ActionResult or Game_Battler would help, however all my attempts have failed since I'm not very good at scripting.
I have a skill which inflicts damage and a state. Whenever the skill misses, the state is still applied to the target.
This happened again when I opened up a new project, confirming that none of the scripts I'm using is causing the issue. This seems to be a flaw of the engine.
Any ideas for fixing this? I assumed that making a script for changing Game_ActionResult or Game_Battler would help, however all my attempts have failed since I'm not very good at scripting.













