How do I create a state that has a chance to inflict other negative states?

I will get straight to the point, is it possible to place a character under a state such that when said character, let's say attacks, he/she has a chance to inflict a state on the target. (Imagine a skill named Apply poison , your character poisons his weapon placing him under a state named poisoned blades and underneath this state he will get a chance to inflict poison on the targeted enemy when he attacks)
yes and no

you can make a state give an actor an attack element and then it will be applied in the regular rules with all skills that use the "normal attack element", but it will also be subjected to the rules that apply when multiple attack elements will be available - I don't know if that's what you want.

And that does not include the option to give states to the target, that is something else as well.
So you'll need a plugin for this
@Icelord888 Go into the database, select the states tab, create a new state called "poisoned blades", double-click an empty line under traits, select the attack tab, select attack state, select Poison on the drop down menu, and adjust the + field to reflect the increased probability of inflicting Poison when your character is affected by "poisoned blades". Now go to skills and create a skill called "Apply poison", set scope to The User, change hit type to Certain Hit, double-click an empty line under Effects, select the State tab, select Add State, select "poisoned blades" on the drop down menu, and make sure it's at 100%. Now you can test it, but I'm relatively certain the skill will apply the "empowering" state to the user and the user will then have the added chance for the "inflicting" state, as set up, for the duration of time the "poisoned blades" state remains on the user (which you can set as desired). Of course, this just uses your example, but you can change the names of the skill, the "empowering state", and the "inflicting" state to suit your needs.

EDIT: I double-checked that Attack State does what I thought. There's apparently one more thing needed to make it work. You need to give "Apply poison" the effect of add state:normal attack, according to this quote I found of @caethyril ...

"Skills with an Add State: Normal Attack trait will add any "attack states" at the specified chances.

To specify a new attack state, just add an Attack State trait to a relevant object. In this case, add one to your weapon to make it contribute Paralyse with 30% success rate: double-click an empty row in the weapon's trait list, and you'll find Attack State on the Attack tab. 🙂"

As you can see...they were working on applying an inflict paralyze state to a weapon in that thread, so...pretty much the same. Oh, and yeah, one other thing to add as mentioned here, you could set the "poisoned blade" state on the weapon itself instead of the user, so only attacks with the actually "poisoned blade" would have the chance to inflict poison. Otherwise, the user could use a club and since they would have the state on their self, it would be like the club was poisoned too...kind of misapplying the effect.
@Icelord888 Go into the database, select the states tab, create a new state called "poisoned blades", double-click an empty line under traits, select the attack tab, select attack state, select Poison on the drop down menu, and adjust the + field to reflect the increased probability of inflicting Poison when your character is affected by "poisoned blades". Now go to skills and create a skill called "Apply poison", set scope to The User, change hit type to Certain Hit, double-click an empty line under Effects, select the State tab, select Add State, select "poisoned blades" on the drop down menu, and make sure it's at 100%. Now you can test it, but I'm relatively certain the skill will apply the "empowering" state to the user and the user will then have the added chance for the "inflicting" state, as set up, for the duration of time the "poisoned blades" state remains on the user (which you can set as desired). Of course, this just uses your example, but you can change the names of the skill, the "empowering state", and the "inflicting" state to suit your needs.

EDIT: I double-checked that Attack State does what I thought. There's apparently one more thing needed to make it work. You need to give "Apply poison" the effect of add state:normal attack, according to this quote I found of @caethyril ...

"Skills with an Add State: Normal Attack trait will add any "attack states" at the specified chances.

To specify a new attack state, just add an Attack State trait to a relevant object. In this case, add one to your weapon to make it contribute Paralyse with 30% success rate: double-click an empty row in the weapon's trait list, and you'll find Attack State on the Attack tab. 🙂"

As you can see...they were working on applying an inflict paralyze state to a weapon in that thread, so...pretty much the same. Oh, and yeah, one other thing to add as mentioned here, you could set the "poisoned blade" state on the weapon itself instead of the user, so only attacks with the actually "poisoned blade" would have the chance to inflict poison. Otherwise, the user could use a club and since they would have the state on their self, it would be like the club was poisoned too...kind of misapplying the effect.
I tried everything but my character either ends up poisoning himself or having a buff that dose nothing....

I created a skill called "Poison Coating" that adds the state "poisoned blades" (till this step everything works) then this state has under traits Attack State: Poison+100% (if i add the normal attack at the previous step, my character only poisons himself)(else nothing he recives a buff that is useless).
@Icelord888 Try this if you haven't already because it may have been an oversight on my part not to mention it sooner: set the Restriction on the Poison state to: Attack an Enemy. This might help get the desired effect. Let me know your results.
@mathmaster74 you misunderstood how the "normal attack" works. It cannot inflict states that way.
If the SKILL has the setting "normal attack", then that will be replaced by an attack state that has been applied as a trait to the actor (usually from a weapon).
so for this to work, the state "poisoned blade" needs to be applied to the actor, and it needs to give the trait of "add attack state poison"
If you apply the "poisoned blade" to the weapon, then that weapon has a chance of giving that state to the targets it hits - not what the OP wants.

That has absolutely NOTHING to do with the restrictions on a state - those restrictions are what will be applied as restrictions to the actor or enemy that will receive the state, so adding the restriction "attack an enemy" to the poison will make the enemy who receives the poison attack other enemies.
@Icelord888 Okay. I'm thinking in light of a new understanding about how things work in MV, you really will need a plugin after all. 🙁

adding the restriction "attack an enemy" to the poison will make the enemy who receives the poison attack other enemies

@Andar Ah...so I was confused about the restriction that usually applies to...confusion. 🤣 Silly me. 🙄

you misunderstood how the "normal attack" works. It cannot inflict states that way.
If the SKILL has the setting "normal attack", then that will be replaced by an attack state that has been applied as a trait to the actor (usually from a weapon).

If you apply the "poisoned blade" to the weapon, then that weapon has a chance of giving that state to the targets it hits - not what the OP wants.

Okay. So based on these quotes put together...if the skill has the Effect: Add State: Normal Attack, then that will be replaced by an Attack State: Poison if applied as a trait to the actor from a weapon, so if I apply "Poison" to the weapon, then that weapon has a chance of giving that state to the targets it hits - which then would be what the OP wants. Correct? 🤔

but it will also be subjected to the rules that apply when multiple attack elements will be available - I don't know if that's what you want.

And that does not include the option to give states to the target

Ah. So that may have been correct...but there's more to it than that. I see. Hmmm...

for this to work, the state "poisoned blade" needs to be applied to the actor, and it needs to give the trait of "add attack state poison"

Okay. So then the original instructions I gave were for "poisoned blade" to have the trait Attack State: Poison, not give it. Alright. I see. 🙂 Thanks Andar. 👍 (btw, as an aside, I haven't gotten far into the reading yet, but I'm enjoying The General Core, and think so far it lends itself well to a video game. 😉)
Summary ("ID" is an item's position in its database list):
  • Two states:
    1. Poison
      ID: not 1 (state 1 is the death state)

    2. Poisoned Weapon
      ID: not 1 (state 1 is the death state)
      Trait: Attack State: Poison +100%

  • Two skills:
    1. Attack
      ID: 1 (normal attack)
      Scope: 1 Enemy
      Effect: Add State: Normal Attack 100% (present by default)

    2. Poison Weapon
      ID: not 1 (skill 1 is normal attack)
      Scope: User
      Effect: Add State: Poisoned Weapon 100%

  • Result:
    • Using the Poison Weapon skill will add the Poisoned Weapon state to the skill user.
    • The Poisoned Weapon state will add Poison to the list of Attack States.
    • The Attack skill will proc all Attack States on hit because it applies the Normal Attack effect 100% of the time.
If you still can't get it working, it may help if you can share screenshots of the relevant states and skills from your database. 🙂
@Icelord888 Since what @caethyril says here matches my original instructions (before the edit), I did my due diligence and set up a test battle following these instructions. It worked like a charm. You spend 1 round using Poison Blade and on the next round you Attack. With the attack state poison set at +100% you will give the state of poison to the enemy every time. If you lower the % when you set up the attack state poison, that % will reflect the chance of giving the state of poison to the enemy. If you tried this setup before and thought it failed, then you likely set the % low and didn't test it enough times to see that it would work. If you first do what caethyril says here and set it at 100%, you'll see it works...then you can play with the % until you have it working about as often as you'd like. If it's still failing, then as caethyril suggests, we need to see those screenshots.

Original thread: https://forums.rpgmakerweb.com/threads/how-do-i-create-a-state-that-has-a-chance-to-inflict-other-negative-states.110079/