Jump to content
  • Advertisement
Sign in to follow this  
kaktusas2598

What you think about Idea to come back to console for one big project..?

This topic is 2836 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Although I have programmed for SDL over month and created Tic Tac Toe I still have a dream of creating C++ RPG (it is not my favourite genre, but for text based game it fits perfectly), and i mean not 300 lines of code project, I want to do big RPG from scratch with all cool things - combat system, storyline, text command processing and etc. I think this is not easy project, it will be real challenge to me cause I have programmed for several years, but i did big "not coding" periods in my programming "career", so to sum up I have programmed over year, but It is actually good idea to come back from SDL (just started, next week I plan to create Pong :) )to text based console? Although, I'm planning to do this after 2 or 3 weeks, cause i must to create pong in SDL first. So, basically it is my dream... What do you think about it, and it is worth doing it? Maybe I will strenghten my C++ knowledge, cause I'm not planning to do some most obviuos beginner stuff, actually I want to create whole world and system, firstly I'm planning to go in design phase and this phase will took "some" time. What's all. Thank you. :rolleyes:

I hope it may not sound silly, it is just my little dream....

PLEASE READ IT ||||
P.S I'm very curiuos about learning scripting and embedding it in my C++ code, I want to try Lua, but i don't know where to start... Can you give me helping hand?
I have a really silly dream what i can implement my scipts (most likely Lua) in this console RPG game, just curiuos to learn how to do it... Maybe I can edit storyline , enemy and item stats and other various things with scripting...

P.S. Other way of doing it - I can also implement simple graphics in console just to represent map, highlight player choise, show stats, show this in different colors, for this i would create some sort of drawing engine, does windows have capability of doing this? I heard what <windows.h> have all needed function... Have any ideas about it, it would really nice to avoid just white text on black screen....

P.S.
Storyline could be based on cyberpunk theme... Just thinking know. And definately it might have plenty of classes :D

Share this post


Link to post
Share on other sites
Advertisement

but It is actually good idea to come back from SDL (just started, next week I plan to create Pong :) )to text based console? ............ and it is worth doing it?



Well, if you're willing to trade time for some experience in writing game logic, then it's definitely worth doing. And if you code it correctly, you will be able to re-use most of the code later in a 2D/3D game.

Using Lua with C++

Share this post


Link to post
Share on other sites

[quote name='kaktusas2598' timestamp='1299610634' post='4783222']
but It is actually good idea to come back from SDL (just started, next week I plan to create Pong :) )to text based console? ............ and it is worth doing it?



Well, if you're willing to trade time for some experience in writing game logic, then it's definitely worth doing. And if you code it correctly, you will be able to re-use most of the code later in a 2D/3D game.

Using Lua with C++

[/quote]

Thanks, this is exacly what I mean, I'll check ou those lua tutorials, any more help, ideas about this?

Share this post


Link to post
Share on other sites
Well, a somewhat obvious advice is to break the game down and do this step by step. Write an abstract inventory system, test it where the user can pick up items, drop them and interact with them. Debug it and make sure it works perfectly. Do the same for the combat, navigation, quests etc... Don't try to code everything at the same time.

The quest system doesn't need to know how the inventory works.. And the navigation system needn't really know how you attack a mob.

Once you have written all the non-game specific code, glue it together with a clean interface, creating your own mini RPG "engine"

Next, you can start creating maps, characters and storylines.. You might want to script these.

Also, take a look at this thread and Motorherp's answer in particular. His Entity & Property approach is pretty good.

And finally, start small. Don't bite off more than you can chew. Finishing a small project is much more satisfying than writing a big unpolished buggy mess.

Good luck!

Share this post


Link to post
Share on other sites
Yeah, it is all about design first, I will grap paper and start thinking how it will look, first I will create game class with loop, update and everything else. And i know what I'm capable of doing it... I just know that, I have been programming not for week or month - it is over year now...

Share this post


Link to post
Share on other sites
If you want to get fancy, you could make this an exercise in separating interface from the game logic, and then you could create a more-graphical interface later -- however, only certain types of game will work well -- for example, its rather hard to do an action game in the console (though doable).

A good style of game would be something like a text-adventure with RPG elements and combat. You move from location to location with text commands, interact with objects present in that location and occasionally encounter scripted or random encounters with NPCs or enemies. Interactions could be text-based, but menu-based would probably be less difficult to implement. This style of game could easily be presented in either a text-based or graphical format.

Basically, to do this you want to view the interface as the "client" and the game engine as the "server" -- even though they are the same machine and even the same process in this case (though, another interesting "interface" that could be added to the engine might allow remote play through a terminal connection or web browser ;) ). Then when you write the GUI version, its just a different "client" using the same "server" (of course, you'll need to serve up different resources depending on the client type, possibly by serving up generic resource IDs and letting the client choose -- say the "server" says you're in "room12", and the text client loads "room12.txt", while the GUI client loads up "room12.bmp" or whatever).

Share this post


Link to post
Share on other sites
Yeah I like your Idea, that first part of your post, I mean second paragraph - is that I was thinking about to made.
Of course I can create some sort of simple graphics in console, like highlithing menu choises when interacting with npc's or using different colors, but I certainly don't know what to use to create this, year ago I was playing with windows.h and did some colored stuff but i forgot it... Maybe it can work again... Just with a little search in MSDN , one thing what might be handy is changing console cursor position to draw text in different place and this can be done using windows.h but then game will be platform dependent but I use XP and Visual Studio so it wouldn't hurt i guess...

Share this post


Link to post
Share on other sites

His Entity & Property approach is pretty good.

Thats called component based game object system if you would like to find more info through google, component based programming though is a pretty advanced topic especially when you are used to inheritance hierarchies.

In the case of component based game objects it is better to call the attributes of an entity properties and call the behavioral implementations components. This way you separate the concerns of a class out better as a property only holds a value and a component would hold a behaviour on the entity that can change certain properties.

He is also not using a component based system in the way it is meant to be used as you woulnd't have any base classes spawning from entity, an entity should just be a collection of attributes and components.


Share this post


Link to post
Share on other sites
I made a Tetris clone in the console a few years ago (that I completely abandoned :():

[media]
[/media]

This tutorial here is what I used for inspiration: http://www.benryves..../winconsole/all

To change the colors, I stole code from somewhere and can't find it anymore, but you basically have to open a new thread that pretends to be the Win32 console settings dialog and set the screen mode/color palette from there. There's also undocumented functions from kernel32.dll, I believe, that you can use to change the resolution on the fly...

And the sound is just raw midi commands, playing notes from an array :P

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!