Announcement

Collapse
No announcement yet.

Tell me basics on variables and shared varibles

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Tell me basics on variables and shared varibles

    Okay im new to RPG maker 3 and i got everything down except what are these varibles and shared varibles all about im completley confused about them and they keep keeping me from making any events so please ne one with patience could ya give me a briefing

    #2
    Re: Tell me basics on variables and shared varibles

    Simply put, a variable is a stored number. The variable could be the number 3, or the number 300, or whatever. When an event checks the value of a variable, it checks to see if the number is what you want it to be in order to start the event or go into a branch with the variable branch command.

    Internal variables are variables that are used by each person/object in your game individually. Person A could have the third variable be 5, and Person B could have the third variable be 17, for example. Shared variables are variables that can be used by any person or object. You could have two persons and an object act a certain way if shared variable #4 equals 6, for example.

    So, an example use. Say you want to have a person that says something different if you talk to him three times. On the first page, have him say something like
    "Hello, person I don't know."
    And increase that person's internal variable by 1.

    On the second page of that person, have it activated by that internal variable be over 2. Then you can have that person say
    "Please stop talking to me!!!"

    Try out using a variable like I described, fiddle around with the numbers and conditions a bit. You'll understand it soon enough.
    "What if like...there was an exact copy of you somewhere, except they're the opposite gender, like you guys could literally have a freaky friday moment and nothing would change. Imagine the best friendship that could be found there."

    Comment


      #3
      Re: Tell me basics on variables and shared varibles

      Originally posted by Draygone
      Try out using a variable like I described, fiddle around with the numbers and conditions a bit. You'll understand it soon enough.
      I couldn't agree more. I set up a test character and started playing with the variables until it worked and I must say I really learned a lot about how to make things work. Once you start to get the hang of how the variables work
      it really does start to make sense. Now if I could only name the damn things

      Comment


        #4
        Re: Tell me basics on variables and shared varibles

        Write it down in a notebook. That's what I'm doing.

        I'm also going to post some useful advice about variables here. They won't work unless you establish the variable first. To do that you use the Modify Shared Variable Command. So like if people are having problems continuing on Testplays and wondering why it's not working, that's your cause.

        Comment


          #5
          Re: Tell me basics on variables and shared varibles

          Originally posted by Omnislash024
          Write it down in a notebook. That's what I'm doing.
          This will be a must when using many variables. You will loose track of them easily if you do not write them down somewhere.
          Current Project: Writing the story for my next game. That is all.

          Comment


            #6
            Re: Tell me basics on variables and shared varibles

            I have 14% done and so far i've only used 2 shared variables. Internal ones are much more conveinient, as they are easy to link with the event.

            Comment


              #7
              Re: Tell me basics on variables and shared varibles

              thanks guys i think i get it al little bit no ill just work wit it

              Comment


                #8
                Re: Tell me basics on variables and shared varibles

                Wow, thats a great tutorial. It cleared a lot up for me as well =)
                theghostORG -- My Collective Domain
                **Coming Soon** Cyber Graffiti's official website!

                Comment


                  #9
                  Re: Tell me basics on variables and shared varibles

                  well heres another ? lol sorry to ask but what can you really do with variables why are they so special to the game (little side note thank the damb god flags arn't used in this fgame RPGmaker 2 was complete hell)

                  Comment


                    #10
                    Re: Tell me basics on variables and shared varibles

                    Flags are easier than variables. They're either on or off.

                    Anyway...um, I don't think I could name many uses for variables with RPGM3. If this were for RPGM2, then I could name SOOOOO many. The biggest reason I can think of is to keep track of where you are in the game. Like if you got through the first scene, set a shared variable to 1, and everything that you set to be different after that first scene will be. After the second scene, the variable will be 2, and so forth.

                    The sample game makes another use of variables, by keeping track of how many times your card is stamped in and around Sample Town. It increases some variable by one, and once it reached 4, the King would do something special for you.
                    "What if like...there was an exact copy of you somewhere, except they're the opposite gender, like you guys could literally have a freaky friday moment and nothing would change. Imagine the best friendship that could be found there."

                    Comment


                      #11
                      Re: Tell me basics on variables and shared varibles

                      Can someone tell me how to use a variable to make a charactor event, that when they tell you to go get a crystal for example. when you return they will react. I cant seem to make it happen? they just say whatever they did before I get the item? Basically any examples for variables would be great.
                      PS rpgmaker 3 has a ver limited amount of graphics? I waited 2 years thinking I would get a great game..so far im a little disappointed.

                      Comment


                        #12
                        Re: Tell me basics on variables and shared varibles

                        Have a shared variable in the val condition branch in the characters event code. This will put on two parts. Have one be a number that will be there by that part of the game. Then set the other one to a number that will be the value of the shared variable when you get the crystal. When he recieves this crystal make sure in the event code for when he gets the crystal it raises the shared variable amount to this number. Then it should work. Go play around with it and you will understand what I mean. You can also have it so he will say this if the variable is greater than the amount or less than the amount. It really depends on what you want him to do.


                        Oh and when you put in the val condition branch you can choose how many there are. In what you said I would use two but if you want him to say something different after you give him the crystal too or whatever you do make it three choices and have him say something else. Hope I was of some help.
                        I was like a Cloud once!!!!

                        Comment


                          #13
                          Re: Tell me basics on variables and shared varibles

                          I've got an idea of using the variables. I think on a game like Fable. You could use shared variables to be a "reputation" of the character. So, after completing a quest, you may add some points in the shared variable. That way, some quests are available when the shared variable are in some level. In the same idea, peoples could talk different things depending on your "reputation" level.

                          In the other hand your could use another shared variable to be the "morals" of the character. Certain actions (like killing a child, help blinds cross the streets, and so on) could give or take points in the "morals" variable. That way some quests are available depending on "morals" and people could even attack bad characters!

                          It's hard to do this, but it's not impossible!
                          What do you think?

                          PS: I'm brazilian so, sorry for bad english...
                          Last edited by Gandalf; 11-04-2005, 09:48 AM.

                          Comment


                            #14
                            Re: Tell me basics on variables and shared varibles

                            Really? I couldn't tell english wasn't your first language.

                            And that's a pretty good example of how one might use variables right there.
                            "What if like...there was an exact copy of you somewhere, except they're the opposite gender, like you guys could literally have a freaky friday moment and nothing would change. Imagine the best friendship that could be found there."

                            Comment


                              #15
                              Re: Tell me basics on variables and shared varibles

                              Variables are not that hard.

                              If you want to compare them to there own language then you have to think they are one of the easiest to learn.

                              Oh and don't worry about how bad your English sounds. There are a few people, an example being me, that there primary language is English and they still can't use correct grammar. I like to say to people that I don't speek English but I do however speek Slain English. I don't even think I spelled Slain correctly. I just spell it how it sounds.
                              I was like a Cloud once!!!!

                              Comment

                              Working...
                              X