RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
Comprehensive Tutorial: Simple Ruby

0 Members and 1 Guest are viewing this topic.

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Simple Ruby
Learning the language

Okay, both RPG Maker VX and XP run some form of RGSS, which stands for Ruby Game Scripting System. Most people see this system as 'go on to the internet, find a cool script and put it in the editor'. And that's okay, it's pretty much why we have scripters.
But some people want to make an effort to learn the programming. Truth be told; it's not that hard. I went from modding a simple script to writing my own systems within about a month, without taking any tutorials.
One thing I wish I did do, though, was learn simple ruby, not RGSS. Now that I've done this, I can help people get that one step closer to whatever it is they want out of this.


Chapter 1: Maths and String
Lesson 1: Mathematics

Spoiler for Lesson 1:
Open up VX or XP, it doesn't matter. Make a new, empty project. Nothing. Get the script editor up, by either pressing F11 or placing your preferred hand on your mouse or touch-pad, altering the position of your hand, thereby moving the cursor on your computer's screen, in a fashion that would take it to the icon of the pencil writing on the paper, and striking the left mouse button with your index finger (or middle finger, if you are burdened with left-handedness or you just like it that way), thus opening the script editor. I prefer pressing F11.
I want you to delete EVERYTHING in the script editor. Yes, everything. You don't need any of these scripts, they're all utterly useless as of this moment. Now, enter the editor proper.
Ruby is a very language centered around simplicity and elegance, or so I believe. As such, you can try out some impressive mathematics skills in the editor. If you enter one line, something like this:
Code: [Select]
1 + 2
and run the game, guess what happens? Did you guess nothing? You're right!
To make it display your super-amazing equation, you must add something. A command, that comes with Ruby, every installation. It's one of the most useful commands in the entire language. It is the almighty "p" function. Alternatively, you could use "print". Here's an example.
Code: [Select]
p 1 + 2
Did you see that? Awesome! It knows what maths is. Ruby can perform pretty much every mathematical procedure you can think of. For multiplication, it uses * (asterisk), for division, it uses / (slash), addition and subtraction should be pretty obvious (+ and -), for exponents it uses ** (TWO asterisks), and for brackets it uses... umm... brackets. Give maths a shot now. Once you're done with that, move on to lesson 2.


Lesson 2: String

Spoiler for Lesson 2:
If you know nothing about programming whatsoever, you won't have the faintest clue what in the world this 'String' thing is all about. In programming, at least. String is, quite basically, any series of characters contained within quotation marks, so that the computer can process it. "This is string." is a perfect example of string. What purpose does it serve here though?
Urr... well, give it a shot! Try using the 'p' or 'print' command with your name. Without using string. I dare you. This is what I put:
Code: [Select]
p Tim
I definitely get a prompt showing up, but it's an error. Oh no. It says: "Script '' line 1: NameError occurred. uninitialized constant Tim" WHAT DOES THIS MEAN?!
It means that your name doesn't exist, really. However, if we put it in string, we get something completely different.
Code: [Select]
p "Tim"
The prompt is much nicer now: it says my name and nothing else, like I wanted it to.
That's all good and fancy, but what can we do with it? It's useless so far!
Lots of cool stuff and lots more boring stuff can be done with string. Ever wanted to know what your name backwards is, but never had the time to check? Now's your chance. Use the reverse method on your name string to check. I'll show you what I mean:
Code: [Select]
p "Tim".reverse
Hang on, why's there a dot there?!
Good question, me. The period not only acts as a decimal point in mathematics and a punctuation mark in language, it is an method operand. Whatever method is written after the dot is performed on what is before the dot. So, let's give it a shot. Does it give you a prompt saying something like this?
Code: [Select]
"miT"
If so, good! If not, reread the instructions.
Well, we reversed our names. Fantastic. How many letters are in our names? I wonder! There's a way to find out, the length method. It goes a little something like this:
Code: [Select]
p "Tim".length
That will print the number of characters in the string, my name. It will come with a prompt that says "3".
My names not long at all. Let's multiply it. To see what's happening, I'll use 2 prompts this time.
Code: [Select]
p "Tim" * 5
p ("Tim" * 5).length
WHAT?! Let's take a look at this. I printed my name 5 times in the same prompt, i.e. "TimTimTimTimTim", and then I printed the number of characters in the print, 15. All good?


Chapter 1 Summary

Spoiler for Summary:
So far, we've taken a look at the prompt, which we'll be using for pretty much this entire tutorial. We've demonstrated and learned about numbers and string; Ruby's mathematics and text objects. And though you might not know it, we've taken a look at 2 types of methods: English-language methods (reverse, length, p and print) and symbolic methods (*, +, -, /, "").
You should be pretty comfortable with string, numbers and some simple methods by now, so let's do something uncomfortable.


Chapter 2: Errors, Arrays and Variables
Lesson 3: Stop, you fool!

Spoiler for Lesson 3:
If we can reverse string, we can reverse anything, right? So, try reversing a number. Just a number. You can trust me.
Code: [Select]
p 32.reverse
No, you imbecile! You can't just do anything to anything! Reverse is a method that works for string, but not everything. The yummy error message you got was telling you that you can't just plonk down a number and reverse it. But you can't be bothered putting it into quotation marks, so here's a lazier way.
Code: [Select]
p 40.to_s.reverse
._.
The to_s method converts anything that isn't a string into string. Which means we can then reverse it. With me?
The reason all this is happening is because while you can use methods on any object in Ruby, some methods only work on certain types of things. This is why we convert types using the built-in 'to' methods. To put it as simply as possible:
to_s converts things into string.
to_i converts things into integers (numbers).
to_a converts thing into arrays.
Slow down, man. What are arrays?


Lesson 4: Arrays

Spoiler for Lesson 4:
Arrays are lists that are contained in square brackets []. Type in a command to print an empty pair of brackets. I used
Code: [Select]
p []
because it's the most obvious one.
CONGRATULATIONS! You've successfully created an empty list of nothing. Let's try putting something in there. Arrays store things in order. That's important; they won't change unless something changes them. That's right, they follow Newton's first law of motion. Spit out three random numbers of different values and put them in an array as such, in no specific order.
Code: [Select]
[15, 93, 76]
Note that entries in an array are separated with a comma.
Let's do something with this list. I want to know what the largest number in this array is, for some nondescript programming person-type reason. There's a built-in method that can be performed on arrays for that.
Code: [Select]
p [15, 93, 76].max
That code will print out the largest number, in this case 93.
That's getting rather annoying to retype, so let's do something to make it easier. At the top of the editor, type a line that says something like
Code: [Select]
list = [15, 93, 76]
Hang on, what did we just do?


Lesson 5: Variables

Spoiler for Lesson 5:
We created a variable, that's what. This variable stores the array so we can play with it without typing everything every time. Hooray! To put this variable to the test, put a line after you define the variable that says p list or whatever your variable is called. Success, the prompt came up with "[15, 93, 76]"! Fantastic.
Now that we know that works, let's do something to appease my OCD. Let's sort the list. Use the sort! command to do this, i.e.
Code: [Select]
list.sort!
You don't even have to print it, though you can if you want to see its effect.
Now, print the sorted list. For me, it came up with "[15, 76, 93]". It sorted the numbers numerically in ascending order.
We had a list, we changed the list; the list has been changed. We changed a variable! Forever! Did you notice that the sort! method has a happy exclamation mark at the end, as if it's yelling at the interpreter to sort the list? Most Ruby methods have that exclamation mark if they change a variable for good. It doesn't change the method at all, it's just a recognizable naming protocol for the commands.


Chapter 2 Summary

Spoiler for Summary:
We saw an error. Wasn't it scary? We looked at why it happened, and how to avoid it. We looked at lists; arrays. We can do simple methods to arrays (.max, .sort!) and can store them in a variable. We now know how variables work, how to change them and use them for convenience. Lastly, we understand why there is an exclamation point at the end of some methods.


Chapter 3: The Object
Lesson 6: When God saw his creation...

Spoiler for Lesson 6:
...he knew it was all object-oriented. Ruby is an object-oriented language, meaning that everything ever used at all to do anything is an 'object'. Let's take a look.
I'm using VX, but the exact same stuff applies in XP. I want you to take a dive through the default scripts, and say, go to Game_Party. You're probably quite confused by what's happening here, but not as confused as you would've been before.
Any line in scripts that don't have anything on them are ignored, as are comments (anything following a hash '#'). So, let's take a look at the first actual line of the script, shall we?
Code: [Select]
class Game_Party < Game_Unit
Well, I should tell you what a class is.


Lesson 7: <Insert schooling pun here>

Spoiler for Lesson 7:
A class is basically a template for an instance of something. If I create a hash, like so: {}, I just made an instance of the Hash class. All classes are templates like this; each game contains hundreds upon hundreds of instances, all created for lengths of anywhere between half a second to over an hour. There are some instances that are used throughout the entire game, instances of the Game_ classes. Now, back to Game_Party.
That first line. You'll see that the word 'class' is highlighted light blue, it is an important syntax word. Therefore, any word following it is highlighted in dark blue. This is the name of the class.
Fun (useless) fact: There is a built-in class could the Class class. From the help guide: "The class of classes. More accurately speaking, each class has its own unnamed "metaclass", and Class is the class of these metaclasses. This relationship is a little complicated, but it is not especially important to keep in mind while using Ruby." Which means it exists not only to act as a class of the metaclass of all classes, but also to confuse you pantsless. More importantly, you'll see that it is a 'subclass' of Module, meaning that Module is its 'superclass'. More on that later.
Something you should know about modules, though, is that you cannot create an instance of a module.
Anyway, that dang first line. So, Game_Party is the class we are entering, i.e. anything written between this declaration and the 'end' of the declaration is contained within that class. And the rest of that line? < means that it is inheriting from the following class, meaning that Game_Party is a subclass of Game_Unit.
A subclass contains all methods and constants contained in the superclass. You can overwrite them, use super (we'll talk about that later), and use this 'inheritance' thing to keep common traits throughout all subclasses. The most evident case of this is every single Window_ class. In VX, Window_Base inherits from Window, a built-in class that defines windows. Then, Window_Selectable inherits from Window_Base, which still inherits from Window. Thus, Window_Selectable gets traits from Window, its superclass' superclass. Looking further along, EVERY SINGLE WINDOW CLASS inherits from Window_Base, Window_Selectable or another window class that inherits from those two. That means every god dang window class shares traits established in the built-in window class.


Lesson 8: Damn Algebra

Spoiler for Lesson 8:
If you participated in attending school up to the age of 11, or seen our resident scripting god around here, you know what algebra is. And if you know what algebra is, you damn well know what x is. X is anything it needs to be. X is the pro-numeral used most commonly in algebra, used in innumerable amounts of equations. It is a constant that changes or is altered by the outcome of the equation. X is a constant.
But what's a constant? A constant is something that is put into an equation that does not change during the equation. Something that does change in the equation is a variable. Now, how to make a constant...
You already know half of it! Remember when we made our 'list' and did some stuff with that? We do the exact same thing, with one specification: they begin with a capital letter.
Code: [Select]
x = 10 # This is a variable.
N = 5 # This is a constant.
The idea of making a distinct separation between the two is for a good reason; if a value begins with a capital letter it is a constant, if it begins with a lowercase letter it is a variable.
For more information on constants, you can read this article.

Constants in RGSS are defined at the beginning of the class declaration and are not changed. For an example, see WLH in Window_Base. It is used throughout the class to change the height of the window lines, and is used for many things in all the Window_ classes.

Lesson 9: Advanced Variables - Local, Instance, Class and Global

Spoiler for Lesson 9:
Constants are one of the main types of values, another is variables. There are many types of variables, and here's a basic introduction to some of them. You'll have to use most of these if you ever write a script.
A local variable is a variable only accessible to the method or block in which it is defined. Don't worry about what a block is, we'll get to them eventually. To show you what I mean, I'll give you an example of improper use of a local variable. You'll also get to see some important syntax in use.
Code: [Select]
class Tutorial # -> Declaring the class
  def local_variable # -> Defining a method: def method_name
    x = 4  # -> Define x variable as 4
  end # End method definition
  def show # -> Defining a method
    print x # -> Print variable x (4)
  end # End method definition
end # End class declaration

t = Tutorial.new # -> Create instance of Tutorial class, store in variable
t.local_variable # -> Set the x variable
t.show # -> Throws an error
Now, if you didn't know any better, you'd assume that the last line would print '4' in a message. But it doesn't. It gives you an error. This is because the defined variable x is a local variable, only accessible to the method in which it is defined. The 'show' method attempts to access the x variable, but it does not exist for that method so it gives you an error.

Instance variables give you a way around that. Instance variables can be accessed throughout the entirety of an instance of a class. They are usually defined in the 'initialize' method of a class, because that is the method that is run as soon as you create the instance. Instance variables always begin with an @ symbol. Watch an instance variable in action.
Code: [Select]
class Tutorial # -> Declaring the class
  def initialize # -> Defining a method
    @x = 4 # -> Define instance variable as 4
  end # End method definition
  def show # -> Defining a method
    print @x # -> Print instance variable '@x'
  end # End method definition
  def add_to_x # -> Defining a method
    @x += 1 # -> Add one to instance variable '@x'
  end # End method definition
end # End class declaration

t = Tutorial.new # -> Create instance of Tutorial class, creating with it the '@x' variable and storing it in a variable
t.show # -> Works, prints 4
t.add_to_x # -> Add 1 to @x
t.show # -> Works, prints 5
print t.x # -> Does not work, throws an error
You may notice that the last line there doesn't work. This is because instance variables are not accessible from outside of the instance. There is, however, a way around this. attr_reader, attr_writer and attr_accessor are all methods to fix this problem. attr_reader creates a method that allows you to read the variable from outside the instance, attr_writer creates a method that allows you to write the variable from outside the instance, and attr_accessor does both. In short, attr_reader creates a 'get' method for the variable, attr_writer creates a 'set' method for the variable, and attr_accessor creates both a 'get' and a 'set' method. Here is how you use them.
Code: [Select]
class Tutorial # -> Declaring the class
  attr_reader :x # -> Creates a 'get' method for '@x'. Syntax: attr_reader :variable
  def initialize # -> Defining a method
    @x = 4 # -> Define instance variable as 4
  end # End method definition
end # End class declaration

t = Tutorial.new # -> Create instance of Tutorial class, creating with it the '@x' variable and storing it in a variable
print t.x # -> Successfully prints '4'
t.x = 5 # -> Does not work.
Now, I think you might be getting the hang of this, so I won't comment every line, just the important ones.
Code: [Select]
class Tutorial
  attr_writer :x # -> Creates a 'set' method for '@x'. Syntax: attr_writer :variable
  def initialize
    @x = 4
  end
end

t = Tutorial.new
t.x = 5 # -> Works. Variable '@x' of t is now 5.
print t.x # -> Does not work.
We can now set the variable, but no longer read it. Here's the most efficient way to create both the 'get' and 'set' methods.
Code: [Select]
class Tutorial
  attr_accessor :x
  def initialize
    @x = 4
  end
end

t = Tutorial.new
print t.x # -> Prints 4
t.x += 1 # -> t.x = 5
print t.x # -> Prints 5
t.x = "We can make variables whatever we want!"
print t.x # -> "We can make variables whatever we want!"
So now that all works. Good. That's instance variables, very very useful variables.

The next thing we'll be looking at in this mammoth of a lesson is class variables. You won't use these very often, but it's still good to know how to use them. A class variable is a bit like an instance variable, they are always made as such by two @ symbols, '@@', and are accessible from all instances of the class in which they are made. This means that if we have 2 instances of the same class that use this same variable, changing it in one will change it in the other. This would not happen with instance variables. Here's a demonstration:
Code: [Select]
class Tutorial
  def initialize
    @@x = 4 # -> Define class variable as 4
  end
  def show
    print @@x # -> Print class variable '@@x'
  end
  def add
    @@x += 1 # -> Add 1 to class variable '@@x'
  end
end

t = Tutorial.new
s = Tutorial.new # -> Create another, separate instance of the class
t.show # -> 4
t.add # -> @@x now equals 5
s.show # -> 5 (it was altered by the add method, even though it was in a different instance)

Global variables is the last type of variables we'll be looking at. You'll definitely be using these if you take up RGSS. Global variables are denoted by a '$' at the beginning of the name. Global variables are accessible from anywhere. All classes, all modules, all methods, everything. They are used in RGSS to store important instances of classes that need to be used everywhere, like $data_system, $game_party, $game_temp, etc.
Code: [Select]
class Tutorial
  def say
    print "This is a global variable!"
  end
end

$tut = Tutorial.new # -> Create global variable
$tut.say # -> "This is a global variable!"

class Something
  def say
    $tut.say
  end
end

s = Something.new
s.say # -> "This is a global variable!"
When using global variables, be aware of their downsides.

And that's variables in a nutshell.


I hope you've learned something about the basics of Ruby. I know I have.
« Last Edit: January 18, 2012, 01:06:50 PM by Pacman »
it's like a metaphor or something i don't know

***
Rep:
Level 69
RMRK Junior
OMG!! Thank you so much Pacman! This is what I've been looking for! 

**
Rep:
Level 83
Nice and easy to understand .

But well , i think the first chapter should explain first what is class , module , attribute , methods (initialize is the most important one)  , ... because most of the makers stop reading at the word "class" :) I know that this is not specific to ruby and it is a little theoric (someone say boring ?) , but it's the most important part to understand . It could be another tutorial of course but a prerequisite to this one .
You can use my scripts freely . but not for commercial use .
:ccbync:
Don't encrypt your game !!!
Want to give me credit ? Easy ,add me in your game :

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
I understand what you're getting at, but this is teaching the very basics of Ruby. We'll get into classes, methods, different types of variables and modules later.
it's like a metaphor or something i don't know

***
You pie feeders!
Rep:
Level 68
Everyone... Actually Everyone hates me :)
2012 Biggest Drama Whore
Math that i understood... i think i might have a spasm now.
Final Statement: I chowder5lock am a dipshit and MA is a pretty cool dude.

***
Rep:
Level 69
RESIDENT ADONKADONK
Wow thanks Pacman! This is extremely useful!

I'm back.

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Why, thank you.
I'll be taking suggestions for what the next chapter is now. It's a large area of learning, and there's much to cover. What to do next?
it's like a metaphor or something i don't know

***
Rep:
Level 69
RESIDENT ADONKADONK
Also, I seem to be having problems with the list command.  Nevermind, that was intentional.
I am not sure what you should do next...
Though maybe I can write a serious script after I look at these tutorials you are writing us!
« Last Edit: August 06, 2011, 12:18:42 PM by Adon »

I'm back.

*
Rep:
Level 82
It's nice to see a quick guide to what stuff is in Ruby for those who aren't too familiar with programming languages. One thing to keep note of though, is to make sure you don't get it into people's minds that you achieve things in the wrong way - or get them stuck into a bad habit.

Like: "You've successfully created an empty list of nothing" after showing the "p []" command. It doesn't create anything, it just prints out an array. You can't actually make use of that array anywhere in the code because it doesn't actually exist as an object. You'd have to either create a variable that implicitly says it's an array:

my_array = []  #creates an empty array object assigned to variable my_array

or explicitly by creating a new object of the class you want:

my_array = Array.new #also creates an empty array object because Array is an inbuilt Ruby class structure.

I just have a thing of trying to be clear, especially if you intend to move onto the more nitty-gritty areas of programming.

That said, there's a good thing to include in your tutorials: Objects. Ruby is an Object Orientated Programming language, and if you can understand how they work the language becomes easier to work with in my opinion.
(Why do I always feel like it's the end of the world and I'm the last man standing?)

*
Rep:
Level 85
I solve practical problems.
For taking arms in the name of your breakfast.
Thank you pacman :3 This will help when i get off my ass to actually script something isntead of modyfying  one.

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
I knew that, Logan, I just wanted to show how arrays work. And, really, it is an empty list nonetheless.
Once I get off my ass, stretch, then get back on it to do stuff on the computer, I'll make the next lesson.
I'm thinking a simple introduction to modules and classes.
it's like a metaphor or something i don't know

*
Rep:
Level 82
I know you know that, but other's might not. Can't assume everyone will know and understand what you meant because you yourself know. Just something to keep in mind that's all; friendly advice and all that.
(Why do I always feel like it's the end of the world and I'm the last man standing?)

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Lessons 6 and 7 are up.
We're getting somewhere; we're looking at classes now. Lesson 8 will cover constants, Lesson 9 will cover various types of variables.
it's like a metaphor or something i don't know

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
Well, 5 months later and I've finally gotten around to updating this. I've added lesson 8 and 9, where you'll learn about constants and all kinds of variables. Anyone who finds errors, please say so. I don't want to be teaching wrong things.

So... just gonna put this here and see what happens.
it's like a metaphor or something i don't know

**
Rep: +0/-0Level 83
Man, what a day....
Hey, What about "self.content"?
Can you post that please.....
I'm a little dizzy about that 'thing' like drawing picture and text.
Oh, and about (X and Y) line...
I want to draw window, i cannot know the graph.
Thanks...

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
This tutorial is more about learning Ruby than RGSS. I will tell you that contents is the property of every window that contain all the text, pictures, gauges, whatever. It is an instance of the Bitmap class. The X and Y coordinates of a window are, essentially, where on the horizontal and vertical axes (respectively) the window's top-left corner is.
To draw text in a window, use
Code: [Select]
self.contents.draw_text(x, y, width, height, str[, align])
or
self.contents.draw_text(rect, str[, align])
align doesn't need to be included, it is an optional argument. x, y, width and height are the x, y, width and height of the text to be drawn, str is the String to be drawn ("Text"), and align is the alignment the text will be drawn in (0 : Left, 1 : Center, 2 : Right). Rect is the Rect (rectangle) the text is drawn in.
Hope that helped.
it's like a metaphor or something i don't know

*
RMRK's dad
Rep:
Level 86
You know, I think its all gonna be okay.
For going the distance for a balanced breakfast.Project of the Month winner for June 2009For being a noted contributor to the RMRK Wiki2013 Best WriterSilver Writing ReviewerSecret Santa 2013 Participant
 :o

Pacman, I love you. Please keep going.
:tinysmile:

**
Rep: +0/-0Level 83
Man, what a day....
Thanks to you, Pacman....
I'm kindda understand right now.

***
Rep:
Level 70
RMRK Junior
This thread should be Stickied.
Heretic's Vehicles XP (Boat and Magic Carpet)

Heretic's Collection XP Ver 2.3 - Updated to include Dynamic Lighting, Moving Platforms, Vehicles, and much much more!

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
It could well be...
Eh, why not.

Stickies are overflowing though... Maybe it's time for some reorganization.
« Last Edit: March 04, 2012, 01:55:00 AM by Pacman »
it's like a metaphor or something i don't know

**
Rep:
Level 57
RMRK Junior
Hello,

I tried your tutorial on rpg maker Vx Ace and got stuck on chapter 1 because I get the same result with the 2 examples you gave : I launch the game, a black screen pop up for 1 sec then the game shutdown.

*
my name is Timothy what's yours
Rep:
Level 79
Hello
2014 Zero to Hero2014 Best IRC Quote2014 Most Missed Member2012 Zero To HeroSecret Santa 2012 ParticipantContestant - GIAW 9For frequently finding and reporting spam and spam bots2011 Zero to Hero
That's because Ace uses a different popup system to the other engines.
Instead of 'print', 'puts', or 'p', use 'msgbox'. I.e.,
Code: [Select]
msgbox 1 + 2
it's like a metaphor or something i don't know

**
Rep:
Level 57
RMRK Junior
Hi,

Thanks it worked.



« Last Edit: March 10, 2012, 05:01:44 PM by Chaos17 »

**
Rep: +0/-0Level 62
RMRK Junior
Thanks alot Pacman. Your tutorial is my first step in becoming less of a leech haha. Thanks again, I hope to see more.

**
Rep:
Level 66
RMRK Junior
I have a question about methods. You can name a method anything you want, right? Or are there specific methods that need specific commands? Can the method, Initialize, be anything I put after that or does it have to be something specific?

Thanks for the lessons!
addled = confused

I support


The Voice of the Gods
http://rmrk.net/index.php/topic,45053.0.html