How to make RPG style?

Videogamez Boy
09 Jul 2013, 07:40
Anyone know how to make text based game in RPG style? Like turn-based combat, stats, equipment..
Also, I want to know if there are any ways to make day and night (and days to days) system in the game. Thanks.

jaynabonne
09 Jul 2013, 08:43
Check out the code samples here:

viewforum.php?f=18

There are basic RPG elements, time tracking, etc.

HegemonKhan
10 Jul 2013, 01:36
as JaynneBonne said and "shown" (linked), there's some libraries of rpg elments, but unfortunately, these are just small and "simple" pieces only (there's no entire RPG elements done yet, at least none shared publically, source code is valuable, lol):

(just off the top of my head, my apologies for anything I've left off, either due to forgetting or not knowing about it)

(pm me too, as I'm working on RPG's myself, working on combat coding and other RPG elements too, though I'm still trying to learn to code, as well as with Game Design, so it's very slow progress for me, along with the busy-ness of real life too, sighs)

the useful links:

1. http://quest5.net/wiki/Main_Page
2. http://quest5.net/wiki/Tutorial
3. http://quest5.net/wiki/How_to
4A. http://quest5.net/wiki/Category:All_Fun ... t_Commands (page 1, range A-S)
4B. http://quest5.net/w/index.php?title=Cat ... h#mw-pages (page 2, range S-Z)
5. viewforum.php?f=18
6. http://quest5.net/wiki/Libraries (small and maybe unneeded now, due to ~see~ link #5)

Combat:

Pertex' Combat Library (turn based combat)
Pixie's Combat Library
Pixie's Spell Library
(pm me too, as I'm working on it, turn based combat due to using pertex' code structure, all credit goes to Pertex)

Magic:

Pixie's Spell Library

Equipment:

Chase's Wearables Library
Pertex' Combat Library
Pixie's Clothing Library

Storage:

Sora's Stackable Library
My (HK's) Storage Coding (PM me for it, if interested)

NPCs:

Sgrieg's Following (and general moving) Code
the various libraries~guides of people on this site (conversation, dynamic conversation, and etc)

Journal Keeping:

again, see link(s) to the libraries~guides

Time:

Clock Library (again see this site's links)

Shopping:

Pixie's Shop Library

Transportation:

Lift (Elevator) Transport Library
Pixie's Rapid Transit System Library

Mapping:

JaynneBonnie's Map Generation Library

Character Creation:

Pixie's Character Creation Code
(you can also pm me too)

Stats:

this is just "basic" attribute and if~conditional coding (see tutorial, and~or other libraries~guides, etc), now doing good Game Mechanics (equations~formulas~algorithms), is an entirely diferrent matter, lol. It isn't easy, at least not for me, sighs, heh.

Etc RPG Elements:

??? (see the libraries~guide links, and~or search the forum here ~ this forum board)

Videogamez Boy
14 Jul 2013, 16:28
thank you for all of your assists. I may try to compile it in my games when I had such free times.

jaynabonne wrote:Check out the code samples here:

viewforum.php?f=18

There are basic RPG elements, time tracking, etc.


OK, will try to look at it later.

HegemonKhan:
For your information, I never learned about the game coding, so it's a difficult to me. But I will try to help you for anything in game project if I can. :?:

HegemonKhan
15 Jul 2013, 01:53
if you need anything explained via the GUI~Editor, say so, but it's MUCH easier and quicker for us to explain via code, lol. It's a lot hard to explain (show the steps) for doing it in the GUI~Editor.

Videogamez Boy
15 Jul 2013, 07:32
two more question, how to make a buy and sell choice in the game?

For example, the player are going inside the store when greeted by a cashier. Then a buy and sell choice are displayed after talking to the cashier.

and, how to enable 'Player Name Input' in the game? At least please give me some tips for that.

HegemonKhan
16 Jul 2013, 00:45
do you want the shopkeeper to initially not have the verb buttons (of buy~sell), and then after talking to him, he then does? Or, do you just want to create the options of buying~selling within the "talk" verb with the shopkeeper?

for having a list of choices:

(hopefully you can figure this out in the GUI~Editor, I think it's: Add a script -> Output or Script -> show menu -> click in its options)

in code, it is this (I went ahead and tried to write a script block for buying~selling):

<verb name="shopping">
show menu ("Do you want to buy or sell?", split ("buy;sell;exit",";"), false) {
switch (result) {
case ("buy") {
show menu ("What do you want to buy?", shop.item_list, false) {
shop_item = result
if (player.cash >= shop_item.price) {
player.cash = player.cash - shop_item.price
shop_item.parent = player
} else {
msg ("You can't afford that!")
}
on ready {
invoke (object_name.shopping)
}
}
}
case ("sell") {
show menu ("What do you want to sell?", player.inventory, false) {
player_item = result
player.cash = player.cash + (player_item.price / 2)
player_item.parent = game_storage_object
on ready {
invoke (object_name.shopping)
}
}
}
case ("exit") {
msg ("You're finished shopping.")
}
}
}
</verb>


---------------------------------

if you want to add buttons that weren't there initially, I think you HAVE TO do that via code, as it's the ONLY WAY:

here's how to do it...

this sets NEW (wipes out the previous verb buttons) verb buttons (Objects and Places):

<displayverbs type="simplestringlist">(the verbs you want, separate them by a semicolon)</displayverbs>

this sets NEW (wipes out the previous verb buttons) verb buttons (Inventory):

<inventoryverbs type="simplestringlist">(the verbs you want, separate them by a semicolon)</inventoryverbs>

this ADDS EXTRA verb buttons to the already existing verb buttons (Objects and Places):

<displayverbs type="listextend">(the EXTRA verbs you want added, separate them by a semicolon)</</displayverbs>

this ADDS EXTRA verb buttons to the already existing verb buttons (Inventory):

<inventoryverbs type="listextend">(the EXTRA verbs you want added, separate them by a semicolon)</inventoryverbs>

-----------------------------

as for any input (ie using what the game player~user types in during game play):

get input {
your_label_for_it = result
}

http://quest5.net/wiki/Get_input

for example:

msg ("What is your name?")
get input {
player.alias = result // the "get input" sets whatever is typed in as "result"
msg ("Your name is " + player.alias)
}


so, for example:

msg ("What is your name?")
get input {
// I type in "HK"
// result = HK
player.alias = result
msg ("Your name is " + player.alias +".")
// output: Your name is HK.
}