Submit Your Article


 
RPG Maker

Welcome Guest ( Log In | Register )


  Games Resources RPG Maker VX RPG Maker XP Scripts Tutorials Downloads

2 Pages V   1 2 >  
Reply to this topicStart new topic
> how do i create a gauge, variables wont do
andreasaspenberg
post Jun 19 2011, 12:28 PM
Post #1


Level 8
Group Icon

Group: Revolutionary
Posts: 115
Type: None
RM Skill: Undisclosed




variables is just too limited. creating a gauge by using variables would require up to 100 variables per character. that is just too much to keep track of due to my damaged memory. i can barely keep track of a few variables.
Go to the top of the page
 
+Quote Post
   
Zinx10
post Jun 19 2011, 07:15 PM
Post #2


Master of Darkness
Group Icon

Group: Revolutionary
Posts: 1,196
Type: Developer
RM Skill: Advanced
Rev Points: 5




IT is dependent of how complex the gauge is...a few variables can be perfectly fine! Btw...it isn't good to recreate a thread that was locked not too long ago.


__________________________
My Games
Phelxyre: Time Unbound (Current Project)
Game Thread
A game where you start in the future, but you go to the past, to make things right, hopefully.

The Hidden World
Game Thread
An Arcade-style game where you must go through various puzzles to see if you go home.

Here are all the things I Support (They Include Links!)




Go to the top of the page
 
+Quote Post
   
Kread-EX
post Jun 19 2011, 09:36 PM
Post #3


(=___=)/
Group Icon

Group: +Gold Member
Posts: 4,136
Type: Scripter
RM Skill: Undisclosed




I'll let it go, for now.


__________________________
FRACTURE - a SMT inspired game (demo) made by Rhyme, Karsuman and me. Weep and ragequit.

My blog.

Click here for my e-peen


Go to the top of the page
 
+Quote Post
   
Kazesui
post Jun 19 2011, 10:39 PM
Post #4


Level 9
Group Icon

Group: Revolutionary
Posts: 141
Type: Event Designer
RM Skill: Advanced




You're still the one who's limited, not the variables. How do you manage to need 100 variables for 1 gauge?
A single variable per gauge should be enough. Storing a value in a variable and then adding or subtracting from it to decide how filled the gauge should be.
download and open this project in your editor

The example shows how to create a very simple gauge with one variable and a couple of events. The events are commented, so it should be understandable, but feel free to ask if it's still unclear as long as you don't ask how to solve it without using variables.

Om du fremdeles mener at du ikke kan bruke variabler for å løse dette, så kan du egentlig bare gi opp. Det er ikke uten grunn at forrige topic ble låst for at du var vrang angående det med variabler. Det er så enkelt som at enten så lærer du deg å bruke variabler, eller så får du bare finne deg i at du ikke kommer til å greie å lage noe sånt.
Go to the top of the page
 
+Quote Post
   
andreasaspenberg
post Jun 20 2011, 03:46 AM
Post #5


Level 8
Group Icon

Group: Revolutionary
Posts: 115
Type: None
RM Skill: Undisclosed




i understand norwegian but many people dont. therefore if anybody want to speak norwegian with me they should do it through personal messages. how do i create a gauge that increase based on steps, then depletes once it have gone above a certain value.

This post has been edited by andreasaspenberg: Jun 20 2011, 04:11 AM
Go to the top of the page
 
+Quote Post
   
Kazesui
post Jun 20 2011, 04:40 AM
Post #6


Level 9
Group Icon

Group: Revolutionary
Posts: 141
Type: Event Designer
RM Skill: Advanced




Since the gauge in the demonstration decreased by subtraction, it would be obvious to think that it will increase by addition.
You could use a conditional branch checking for a switch "increase".
If increase is on, you will add to the gauge, to make it increase.
if increase is off (i.e. the condition "else" handler), you will subtract from gauge.

After you've performed the addition, you have another branch check if the value is at it's maximum. If yes, then turn the switch "increase" off.
Likewise, after the subtraction you'd check if the gauge is empty (i.e. if gauge = 0), and turn the switch "increase" on if it is.
Go to the top of the page
 
+Quote Post
   
andreasaspenberg
post Jun 20 2011, 11:20 AM
Post #7


Level 8
Group Icon

Group: Revolutionary
Posts: 115
Type: None
RM Skill: Undisclosed




sounds interesting. please explain further. i still need more information in order to create a working gauge. i really want to finish the gameplay in my game soon but it wont work without the gauge.

This post has been edited by andreasaspenberg: Jun 22 2011, 03:24 AM
Go to the top of the page
 
+Quote Post
   
Jparker1984
post Jun 27 2011, 04:52 AM
Post #8


Level 8
Group Icon

Group: Revolutionary
Posts: 132
Type: Developer
RM Skill: Skilled




wow, i never ever talk bad about anyone but really, how dumb is this guy. if some one can understand switches they can understand variables. I am sorry dude, but you seriously need to stop using RPG Maker if you cant do the very basics aspects of the program.


__________________________
"If you say you can't, you wont. So never give up on your dreams"
Go to the top of the page
 
+Quote Post
   
andreasaspenberg
post Jun 27 2011, 05:20 AM
Post #9


Level 8
Group Icon

Group: Revolutionary
Posts: 115
Type: None
RM Skill: Undisclosed




i did manage to create several different gauges. 1 that fills with kills and 1 that fills by using keys. i still cant fully figure out how to fill it with steps. i still dont have the graphics for them though.
Go to the top of the page
 
+Quote Post
   
Holder
post Jun 27 2011, 05:46 AM
Post #10


Spoilers.
Group Icon

Group: Revolutionary
Posts: 4,204
Type: Developer
RM Skill: Advanced
Rev Points: 250




QUOTE (Jparker1984 @ Jun 27 2011, 01:52 PM) *
wow, i never ever talk bad about anyone but really, how dumb is this guy. if some one can understand switches they can understand variables. I am sorry dude, but you seriously need to stop using RPG Maker if you cant do the very basics aspects of the program.

You never talk bad about anyone... try to keep it that way.
Everyone has their own skill levels and learning curve, this topic is for help and support, not telling them to stop using the program.


__________________________

 I'm running the Great North Run in September in aid of NACC. A condition my wife has in it's severe form.
Please sponsor me with whatever you can, thank you.
If you'd like to help spread the word please share the image and link to my fundraising page.

Go to the top of the page
 
+Quote Post
   
Vanit
post Jun 27 2011, 06:12 AM
Post #11


Level 15
Group Icon

Group: Revolutionary
Posts: 291
Type: Developer
RM Skill: Undisclosed




Checking to see if the hero has taken a step is surprisingly easy!

You'll need 5 variables:
Hero X - Holds the Hero's current X coordinate
Hero Y - Holds the Hero's current Y coordinate
Last X - Holds the Hero's previous X coordinate
Last Y - Holds the Hero's previous Y coordinate
Steps - Amount of steps taken

The idea is that when we detect that Hero X/Y and Last X/Y have different values, it means the character would've moved one space! Then all you need is a parallel process enabled by a switch that does the following:

CODE
Last X = Hero X
Last Y = Hero Y
Hero X = Hero's Current X Coordinate
Hero Y = Hero's Current Y Coordinate
IF Hero X is not equal to Last X
    Steps + 1
Else
    IF Hero Y is not equal to Last Y
          Steps + 1
    End IF
End IF
IF Steps greater than 100
    Steps = 100
End IF


And you can replace 100 with whatever the maximum amount of steps is (that is if you want a maximum, if not you'll need to adjust your code to cap the gauge out at a maximum or weird stuff will happen).

This post has been edited by Vanit: Jun 27 2011, 06:15 AM


__________________________
Go to the top of the page
 
+Quote Post
   
andreasaspenberg
post Jun 27 2011, 06:20 AM
Post #12


Level 8
Group Icon

Group: Revolutionary
Posts: 115
Type: None
RM Skill: Undisclosed




when the gauge reaches maximum it falls back to 0. dont worry, i know how to set it back to 0. though each character gets their own gauges. it doesnt exactly help that people call me stupid though or dumb.
Go to the top of the page
 
+Quote Post
   
Jparker1984
post Jun 27 2011, 06:57 AM
Post #13


Level 8
Group Icon

Group: Revolutionary
Posts: 132
Type: Developer
RM Skill: Skilled




I am sorry, a bit un called for, I just didn't get how you couldn't figure it out by the way people were explaining it.


__________________________
"If you say you can't, you wont. So never give up on your dreams"
Go to the top of the page
 
+Quote Post
   
Kread-EX
post Jun 27 2011, 08:15 AM
Post #14


(=___=)/
Group Icon

Group: +Gold Member
Posts: 4,136
Type: Scripter
RM Skill: Undisclosed




In addition to what Holder said, Jparker1984, andreasaspenberg finally overcame his aversion for variables and is learning how to use them. It may be difficult for him but he is trying now.

Don't insult people like that.


__________________________
FRACTURE - a SMT inspired game (demo) made by Rhyme, Karsuman and me. Weep and ragequit.

My blog.

Click here for my e-peen


Go to the top of the page
 
+Quote Post
   
andreasaspenberg
post Jun 27 2011, 10:50 AM
Post #15


Level 8
Group Icon

Group: Revolutionary
Posts: 115
Type: None
RM Skill: Undisclosed




i should be able to manage the rest of the script on my own. i still dont have a design for it though. the best would be a gauge that exist a single image that fill with color. i have seen it in a game but i dont have the slightest idea how to create that kind of effect.
Go to the top of the page
 
+Quote Post
   
Zinx10
post Jun 27 2011, 01:23 PM
Post #16


Master of Darkness
Group Icon

Group: Revolutionary
Posts: 1,196
Type: Developer
RM Skill: Advanced
Rev Points: 5




Wait...create what kind of effect?


__________________________
My Games
Phelxyre: Time Unbound (Current Project)
Game Thread
A game where you start in the future, but you go to the past, to make things right, hopefully.

The Hidden World
Game Thread
An Arcade-style game where you must go through various puzzles to see if you go home.

Here are all the things I Support (They Include Links!)




Go to the top of the page
 
+Quote Post
   
andreasaspenberg
post Jun 27 2011, 01:31 PM
Post #17


Level 8
Group Icon

Group: Revolutionary
Posts: 115
Type: None
RM Skill: Undisclosed




the effect of a gauge filling up without using pictures for the entire process.(just for the gauge itself.)
Go to the top of the page
 
+Quote Post
   
Vanit
post Jun 27 2011, 07:06 PM
Post #18


Level 15
Group Icon

Group: Revolutionary
Posts: 291
Type: Developer
RM Skill: Undisclosed




The only way you can do it with a single picture is if you conceal the unused part of the gauge by having it offscreen or underneath another picture. Personally I prefer the slightly more tedious method of having a picture for each state of the gauge and then using the picpointerpatch to easily animate them, and the benefit of doing it this way is that you don't need to hide the guage behind anything (which can look clunky depending on how your do it.


__________________________
Go to the top of the page
 
+Quote Post
   
kayden997
post Jun 28 2011, 01:05 AM
Post #19


>Glitched<
Group Icon

Group: Local Mod
Posts: 1,172
Type: Event Designer
RM Skill: Masterful
Rev Points: 30




Arg! Does no one look in the tutorial section anymore?
Or even payed a visit to the search button?
I took well over 2 hours creating a very easy-to-understand tutorial for variables
http://www.rpgrevolution.com/forums/index....showtopic=50943

If you still do not understand it, I suggest you look at the tutorial.

This post has been edited by kayden997: Jun 28 2011, 01:06 AM


__________________________


Runescape with Dyedfire




Go to the top of the page
 
+Quote Post
   
andreasaspenberg
post Jun 28 2011, 01:24 AM
Post #20


Level 8
Group Icon

Group: Revolutionary
Posts: 115
Type: None
RM Skill: Undisclosed




the gauge i saw was completely shown at all times. that proves that it is possible. i just dont know how. please dont get angry at me. i just want to set up a visible gauge.

This post has been edited by andreasaspenberg: Jun 28 2011, 01:24 AM
Go to the top of the page
 
+Quote Post
   

2 Pages V   1 2 >
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Lo-Fi Version Time is now: 20th June 2013 - 01:09 AM
RPG RPG Revolution is an Privacy Policy and Legal
eXTReMe Tracker