GPWiki.org
GPWiki.org
It is currently Fri May 24, 2013 11:06 pm

All times are UTC




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: C# 'DF' type interface
PostPosted: Wed Mar 21, 2012 1:39 pm 
Rookie

Joined: Wed Mar 21, 2012 12:38 pm
Posts: 2
Hi all,

I'm a C#/.Net developer but my experience in the field is limited to WinForms (and a bit of WPF) programs for internal use of the company I work for. I'm looking to expand my programming knowledge into games, mainly for a hobby or perhaps give away as freeware.

I'd like my game to be more about the game-play than eye candy (my lack of artistic ability helps with this move too ;) )

Without being too long winded about what the game is I'd be quicker to describe as 'Dwarf Fortress like' although it's certainly not going to be a 'clone' of DF (not that I would dream of being able to even equal such a classic game imho). I want to use the style of ASCII type graphics that DF uses and it would work well for what I have planned, I'm not really interested with 3D objects or bitmaps at this point. Although DF looks like a console app I'm not sure if it actually is (not being experience with console apps I'm not entirely sure what display abilities they have)

I've purchased an excellent book called Visual C# Game Programming for Teens that uses GDI and sprites and I'm hoping to use this to show be the basic concepts of game programming. What I'd like to know is:

    Can I use C# to create a game with the same graphic style as DF? If so have you any hints/tips or some keywords I could Google?
    If not would using XNA be a better approach?

Sorry if these questions sound a bit vague but I'm at the stage were I don't know what I don't know (if that doesn't sound stupid) and don't want a long walk down what could be a blind ally, ask me to write a program to interrorgate a database and I'm away, all the graphics and game stuff is making me feel like I've only started coding again :thumbs

Many thanks in advance and thank you!

Mark


Top
 Profile  
 
PostPosted: Wed Mar 21, 2012 2:19 pm 
Funky Monkey

Joined: Thu Sep 09, 2004 1:17 pm
Posts: 1553
Location: burrowed
Hey and welcome to the forums.

I have only briefly played around with console output, and what i gathered is it is Console.WriteLine is fairly slow if called in rapid succession.
There might be ways around that through accessing the text buffer directly or miniminze the amount of .WriteLine calls.

http://cgp.wikidot.com/consle-screen-buffer
This might be worth trying. Otherwise you might want to google for "C# console buffer" or similar.

Hope that helps

_________________
Long pork is people!

wzl's burrow


Top
 Profile  
 
PostPosted: Wed Mar 21, 2012 2:31 pm 
Rookie

Joined: Wed Mar 21, 2012 12:38 pm
Posts: 2
Many thanks!

Using your suggestion I came up with this: http://broadcast.oreilly.com/2010/08/un ... games.html that might be a start.

If anyone else has suggestions or links that might help me though PLEASE reply. I'm looking for all the info I can get.

Thank you again!

Mark


Top
 Profile  
 
PostPosted: Wed Mar 21, 2012 3:21 pm 
Harmlessness does no harm
User avatar

Joined: Tue Sep 14, 2004 8:37 pm
Posts: 3810
Location: Ferriday, LA, US
You want something like Curses (a library for text-based user interfaces). The equivalent text interface built into Windows (conio) is kind of lame, and I don't even know if it can be used with anything but C or C++.

PDCurses and nCurses have been ported to other languages and OS platforms. The only thing I've found thus far for C# is this: http://sourceforge.net/projects/curses-sharp/

For more general info on the Curses library: http://en.wikipedia.org/wiki/Curses_%28 ... library%29

_________________
What most people don't understand about "enlightenment" is that it is not an end-goal; but where you find yourself just before taking a new "first step."


Top
 Profile  
 
PostPosted: Thu Mar 22, 2012 8:12 pm 
Dexterous Droid
User avatar

Joined: Wed Aug 18, 2004 7:40 pm
Posts: 3735
Location: South Africa
Quote:
Although DF looks like a console app I'm not sure if it actually is (not being experience with console apps I'm not entirely sure what display abilities they have)

DF can use Curses on Linux, but it generally runs on top of SDL, with a spritesheet for the traditional looking "ASCII" characters.

You can take something like the following image and then use regular graphics operations. No need to worry about the console.
Image

This one is the traditional DF tileset:
Image

I think if you go the route of using an ASCII tileset, you'll learn skills that are more transferable to your next game than if you learnt how to use Curses. I wasn't really enthused last time I looked at Curses. I'd jump into XNA + an ASCII tileset, if I were you.

_________________
Whatever the mind can conceive and believe, it can achieve


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group