VB6 RPG

Started by
15 comments, last by gamechampionx 22 years, 1 month ago
Maybe you should try writing a text rpg first. This way you get the basic game logic and then you will feel more confortable messing with graphics stuff
Advertisement
What are GDI calls, and why would you need to use arrays for? Anyway, why is it so hard to make an RPG with form objects. I really need help with making tilesets, though, how is it done?
Check out Drunken Brawl at http://www.angelfire.com/games6/drunken_brawl!
You need a array for the map.

Make a simple 2d array:

integer as Map(100,100) (If I remember VB right?)

and then make a map editor to change those 100x100 tiles.
Save the map, load it in the game and make some freaking quest in it

/MindWipe

"If it doesn''t fit, force it; if it breaks, it needed replacement anyway."
"To some its a six-pack, to me it's a support group."

dim MyMap(100,100) as integer close but no cigar :D

i used VB for about 2 years, still give it evil glances every so often, but i used to love it , anyway, nuff about that If i was you i''d start off learning to an intermediate level non game specifics, like.. file access, data manipulation, data types, that sort of thing. Machairas'' rpg tutorial is a must try, haven''t looked at it yet, but any tutorial is a help


DarkStar
hey, here is a website dedicated to developing RPGs in VB... although half the time i can''t access the site, i dunno if they have a crappy server or what... but if you go there and it is actually working they have some things that would help you a lot...
good luck.

--- krez (krezisback@aol.com)
--- krez ([email="krez_AT_optonline_DOT_net"]krez_AT_optonline_DOT_net[/email])
quote:Original post by gamechampionx
Hey, I''m only uising this as a learning experience. By the way, I need help with moving text around, I''ts horribly choppy, even using an interval of 1 on a timer object. Need help! By the way, I don''t mind constructive criticism, I''m going to try to work on writing to files as I make my game. Any help from anyone would be appreciated.


Let me be the one voice in your favor here gamechampionx . I think it''s great to pick a goal and work toward it and learn along the way. That''s how I learn best. And an RPG is, I think, a good choice because it can be as simple or complex as you want it to be. You might only get as far as drawing a 10x10 array of tiles and moving a character around on that map, but you will have learned many important things in the process, and you can continue to build on it if you choose. Let me take a risk by saying, VB is not a bad language for RPG games and GDI/VB graphics calls are not a bad interface to do RPG graphics with. As a matter of fact, if you''re going to make a graphical game in VB using GDI/VB graphics, RPG is the way to go because it doesn''t require frequent screen updates and the character can move 1 whole tile at a time, keeping things simple.

Anyway, let me add some real value to this by trying to answer your question(s):
1) Are you trying to scroll text? Maybe you should leave smooth animation features until later and finish the basics. But if you really want to scroll text now I can take a look at what you got and recommend an alternative. I just made a simple VB program that scrolls text and it seems to be pretty smooth, so you''ll have to show me what you''re doing.
2) If you''re going to save large hierarchies of data to a file, may I suggest using user defined types. It doesn''t deal with verifying the file format, but it''s relatively easy to implement. For instance, if your file needs to contain a player position and an array of map tiles, you can create 3 user defined types. The following code defines the types, initializes them with some data, saves the data and re-loads the data. (You may want to make your types public instead of private if you''ll be using them accross modules.)

Private Type Player   X As Integer   Y As IntegerEnd TypePrivate Type Map   Title As String   Tiles(0 To 99, 0 To 99) As ByteEnd TypePrivate Type FileData   PlayerData As Player   MapData As MapEnd TypePrivate Sub Form_Load()   Dim MyFileData As FileData      With MyFileData      With .PlayerData         .X = 50         .Y = 50      End With      With .MapData         .Title = "My First Map"         .Tiles(0, 0) = 1         '' Fill in more map here      End With   End With      '' I hard code the file number as 1 because I know that I will only have   '' one file open at any time and I want VB errors to notify me if I forgot   '' to close a file.  Others like to use FreeFile to get the next available   '' file number.   Open "TestFile.dat" For Binary As #1      Put #1, , MyFileData   Close      Open "TestFile.dat" For Binary Access Read As #1      Get #1, , MyFileData   CloseEnd Sub 


"All you need to do to learn circular logic is learn circular logic"
"All you need to do to learn circular logic is learn circular logic"
another idea is to use a relational database for storing your stuff. they are ideal for RPG type things, and with VB it is fairly easy to use them (Microsoft Windows comes with JET i think, and there are both controls and API for dealing with a database built right into VB). VB also comes with VisData (at least the older versions did) for building the database.
--- krez ([email="krez_AT_optonline_DOT_net"]krez_AT_optonline_DOT_net[/email])

This topic is closed to new replies.

Advertisement