Looking for a script

I'm looking for a script that shows all status effects while you're on the map.

So, if you get poisoned in battle, on the map, the player's sprite will be all purple or a certain color to show that they are poisoned.

Thanks in advance.  BD
Are you using an abs on the map aka Zelda Style or are you using a battle where it goes into another scene ala default or sideview?
I'm using Yanfly's visual battlers!  BD

Oh, and I have Yanfly's Ace Battle System.

Visual Battlers.png
So you want the status symbols to be on screen when not in a battle?
I've moved this thread to RGSS3 Script Requests. Please be sure to post your threads in the correct forum next time. Thank you.
Sorry Shaz.

And yeah, that could work. But what I meant was..

I would like to have the player to have a certain hue or shade to him while he is poisoned. So like, you're walking around on the map, and you're not your usual color, you're purple because you're posioned.

Something like this!  BD

Poison.png
You need to create a new character sheet for your actor with a purple colour for the poison status. Then you need to set up an event that will change your actor's graphic to the 'poisoned' one when the state is applied, and change it back again when the state is removed.


You might find this script useful.
I'm not exactly sure how to use your script. I'm a noob when it comes to scripts so please bear with me  😀

What should I do to make it so that he becomes purple when he's poisoned? Could you please give me a mini tutorial on what to do?
Alright. First, I need some information from you.


Can you make me a screenshot like the one in the spoiler? Go to your Actor's tab, choose an actor, double click on their sprite. Then move the Character Graphic window to the side a bit so I can still see the list of actor names in the database window.

Spoiler
AceActorTab_zps23fd6bd2.png
That should give me all the info I need to give you the exact commands to use.
Here you go!

Spoiler.png
Excellent! So based on that, I'm assuming each of your actor character sheets contains sprites for 8 different characters.

Here's what you need to do:

1. Make copies of each of those, and edit the copy in a graphics editing program so the characters are purple. Save them with -poison at the end of the filename. So your modern5.png file will be copied to modern5-poison.png and the same for the others.

2. Add that script into your game's scripts (F11 gets you to the script editor - find the section on the left called Materials, create a new slot by clicking BELOW Materials and pressing Insert, click in the script name box at the bottom and name it, then click in the script window on the right and paste the script, which you've copied from pastebin).

3. Go to your Poison state, and copy and paste the following into the Notes box. Don't retype it, in case you make any typos. It will wrap over several lines, but that's okay.

Code:
onadd: set_graphic(sprintf('%s-poison', @character_name), @character_index, @face_name, @face_index); $game_player.refreshonremove: case @character_name; when /(.*)-poison/i; set_graphic($1, @character_index, @face_name, @face_index); $game_player.refresh; end
Note - this only changes the sprite, not the face as well. If you want the face changed too, let me know (it'll only change it in the menu, not in message boxes).
Woahhh! It worked, you're a genius!  BD

But wait, is it possible to make the sprite change during the battle? 
That would depend on your battle script. Post a link to it and if I can see it quickly, I'll give you a modified version of the state notes.
Yanfly Visual Battlers: https://dl.dropboxusercontent.com/u/17078211/Scripts/YEA/Visual_Battlers.rb
Here you go. In addition to adding in the refresh for Yanfly's Visual Battlers, I also added a check to only do this for the actors, not the enemies. Running the above note may have resulted in an error if an enemy had been poisoned.

Again, just copy and paste into notes. Don't even try to retype it 🙂

onadd: if actor?; set_graphic(sprintf('%s-poison', @character_name), @character_index, @face_name, @face_index); $game_player.refresh; SceneManager.scene.spriteset.actor_sprites[index].character_base.set_graphic(@character_name, @character_index) if $game_party.in_battle; endonremove: if actor?; case @character_name; when /(.*)-poison/i; set_graphic($1, @character_index, @face_name, @face_index); $game_player.refresh; SceneManager.scene.spriteset.actor_sprites[index].character_base.set_graphic(@character_name, @character_index) if $game_party.in_battle; end; endYou should test this as well ... what happens if a character is poisoned, and then gets poisoned again? Will the game crash or something weird happen to the actor because it's trying to set the sprite a second time? I THINK states will only be applied if they don't already exist. But you should check and confirm that 🙂
No way!! You did it! It works perfectly 😀D 

Let me show you, check this out!

You did itt.png

You're super smart, this is awesome thank you so much 😀 I tested to see if it would crash when the player get's poisoned again, and it didn't  BD Thanks Shaz
awesome 🙂


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.

Original thread: https://forums.rpgmakerweb.com/threads/looking-for-a-script.21557/