Add counter on the screen?

Koi

Veteran
Veteran
Joined
Aug 8, 2013
Messages
358
Reaction score
14
First Language
English
Primarily Uses
RMVXA
I have a shooting duck mini game where you shoot different ducks for different points (adding onto a "duck" variable), and I want to show a counter on the screen. Is there a way to do this?
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
39,163
Reaction score
12,436
First Language
English
Primarily Uses
RMMV
you will need a script
 

Koi

Veteran
Veteran
Joined
Aug 8, 2013
Messages
358
Reaction score
14
First Language
English
Primarily Uses
RMVXA
Should I make a thread in the script forum? Or can this be moved there?
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
39,163
Reaction score
12,436
First Language
English
Primarily Uses
RMMV
just report it and ask a mod to move it.
 

Koi

Veteran
Veteran
Joined
Aug 8, 2013
Messages
358
Reaction score
14
First Language
English
Primarily Uses
RMVXA
How do I do that?
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
39,163
Reaction score
12,436
First Language
English
Primarily Uses
RMMV
On your first post (on all your posts actually), there is a Report post link at the very top of the post.
 

Koi

Veteran
Veteran
Joined
Aug 8, 2013
Messages
358
Reaction score
14
First Language
English
Primarily Uses
RMVXA
Okay did that.
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
21,867
Reaction score
11,081
First Language
English
Primarily Uses
RMVXA
I've moved this thread to RGSS3 Script Requests. Please be sure to post your threads in the correct forum next time. Thank you.
 
Last edited by a moderator:

Koi

Veteran
Veteran
Joined
Aug 8, 2013
Messages
358
Reaction score
14
First Language
English
Primarily Uses
RMVXA

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
30,077
Reaction score
7,049
First Language
German
Primarily Uses
RMMV
you should look for a so-called HUD script on the master script list.


HUD is a general description of adding data displays to the screen, and most of the HUD-scripts will add a lot more than you want, but there should be some that can be configured to add only a few variables on the screen.
 

HexMozart88

The Master of Random Garbage
Veteran
Joined
May 15, 2016
Messages
1,813
Reaction score
3,227
First Language
English
Primarily Uses
RMVXA
There are one or two scripts that allow you to show the value of any given variable. Or, depending on exactly how many ducks there are going to be, you can use pictures. 
 

Koi

Veteran
Veteran
Joined
Aug 8, 2013
Messages
358
Reaction score
14
First Language
English
Primarily Uses
RMVXA
Well this is what it looks like.


ducks.png


Top duck scores 1 point, middle 2 points, and bottom 3 points. And I want a counter to appear in the corner showing the score. I was just looking at HUD scripts, and something that would display gold or an item could work because I'd just replace adding onto the variable with adding currency or an item each time. But, the only one I could find for gold requires a core script that could mess with the other scripts that I already have.
 
Last edited by a moderator:

HexMozart88

The Master of Random Garbage
Veteran
Joined
May 15, 2016
Messages
1,813
Reaction score
3,227
First Language
English
Primarily Uses
RMVXA
One: cool minigame! Two, I think you can use show picture for that.


1. Split the variable into digits. The way to do that is by using multiple variable commands. Variable 1 is the hundreds place. Do the original variable / 100.


Variable 2 is the tens place. The original variable % 100, then divide that by 10. Variable 3 is in the ones place. Original variable % 10. 


2. Once you have that done, make your pictures. They should be named "1", "2" etc. 


3. Make a series of conditional branches for each variable, example: if variable (such and such) is equal to 1, show picture 1, "1"


4. For the tens and hundreds places, if the variable equals 0, make another conditional branch inside of that conditional branch to check if the original variable is greater than or equal to 10 for the tens place and 100 for the hundreds place. If not, erase that picture. That's to avoid having leading zeroes. 


I find it looks ugly to see 001. I prefer just 1.  
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Here it is in all its leggy glory! I apologize in advance.
Suggestion for the name for the new RM, RPG Maker Re-MV (Re-Mastered Version)
A guide on Furry Potatoes.

I apparently need to send photo ID to Blizzard to change my phone number. I don't even need to do this to change my number with my bank or PayPal

Forum statistics

Threads
98,175
Messages
950,082
Members
129,473
Latest member
Soulbanana
Top