Welcome to GameHourz.com!
FAQFAQ      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

C# PDCurses

 
   Game Forums (Home) -> Roguelike -> Development RSS
Next:  Random Dungeon Generator - part 4  
Author Message
init13

External


Since: Nov 25, 2007
Posts: 1



(Msg. 1) Posted: Sun Nov 25, 2007 4:58 pm
Post subject: C# PDCurses
Archived from groups: rec>games>roguelike>development (more info?)

Hello!

Is there any way to use PDCurses with C# ?
If no, please tell me, how to organize fast console output with C# ?

Thanks!

 >> Stay informed about: C# PDCurses 
Back to top
Login to vote
init13

External


Since: Nov 26, 2007
Posts: 2



(Msg. 2) Posted: Mon Nov 26, 2007 1:11 am
Post subject: Re: C# PDCurses [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Nov 26, 4:41 am, "Nik Coughlin" <nrkn.... RemoveThis @gmail.com> wrote:
> <ini... RemoveThis @gmail.com> wrote in message
>
> news:83158c1d-f619-4dba-bfa1-79ff08fbbdd0@j44g2000hsj.googlegroups.com...
>
> > Is there any way to use PDCurses with C# ?
>
> http://www.mono-project.com/Libraries#Curses

That's perfect!

Thank you!

 >> Stay informed about: C# PDCurses 
Back to top
Login to vote
almafeta

External


Since: Jun 17, 2006
Posts: 20



(Msg. 3) Posted: Mon Nov 26, 2007 6:18 am
Post subject: Re: C# PDCurses [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Nov 25, 9:35 pm, "Nik Coughlin" <nrkn.....DeleteThis@gmail.com> wrote:
> Call the Win32 API instead. Console class in .NET is *slow*. Very
> unfortunate Sad Especially if you want to target Mono as well.

I'm using it, and I'm not seeing this very-slowness...

-- Shanya
 >> Stay informed about: C# PDCurses 
Back to top
Login to vote
Nik Coughlin

External


Since: Nov 09, 2007
Posts: 6



(Msg. 4) Posted: Mon Nov 26, 2007 3:35 pm
Post subject: Re: C# PDCurses [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

<init13.TakeThisOut@gmail.com> wrote in message
news:83158c1d-f619-4dba-bfa1-79ff08fbbdd0@j44g2000hsj.googlegroups.com...
> Hello!
>
> Is there any way to use PDCurses with C# ?
> If no, please tell me, how to organize fast console output with C# ?
>
> Thanks!

I don't know about your first question but, as to your second:

Call the Win32 API instead. Console class in .NET is *slow*. Very
unfortunate Sad Especially if you want to target Mono as well.
 >> Stay informed about: C# PDCurses 
Back to top
Login to vote
Nik Coughlin

External


Since: Nov 09, 2007
Posts: 6



(Msg. 5) Posted: Mon Nov 26, 2007 3:41 pm
Post subject: Re: C# PDCurses [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

<init13.DeleteThis@gmail.com> wrote in message
news:83158c1d-f619-4dba-bfa1-79ff08fbbdd0@j44g2000hsj.googlegroups.com...
> Is there any way to use PDCurses with C# ?

http://www.mono-project.com/Libraries#Curses
 >> Stay informed about: C# PDCurses 
Back to top
Login to vote
Nik Coughlin

External


Since: Nov 09, 2007
Posts: 6



(Msg. 6) Posted: Tue Nov 27, 2007 9:02 am
Post subject: Re: C# PDCurses [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

<almafeta.DeleteThis@gmail.com> wrote in message
news:c7d4d946-57a6-46f5-a44f-90843129d030@b15g2000hsa.googlegroups.com...
> On Nov 25, 9:35 pm, "Nik Coughlin" <nrkn.....DeleteThis@gmail.com> wrote:
>> Call the Win32 API instead. Console class in .NET is *slow*. Very
>> unfortunate Sad Especially if you want to target Mono as well.
>
> I'm using it, and I'm not seeing this very-slowness...

It seems to be OK here too now. The ast time I tried to use it was in
VS2005 in XP, now I'm running VS2008 on Vista. The code I tested with was
this (caution: ugly code follows):

Random r = new Random();

Console.Clear( );

while ( true ) {
for ( int y = 0; y < 20; y++ ) {
for ( int x = 0; x < 70; x++ ) {
Console.SetCursorPosition( x, y );
Console.ForegroundColor = (ConsoleColor) r.Next( 16 );
Console.Write( 'x' );
}
}
}

Further speed increases by only setting the cursor position in the Y loop.
In a Roguelike there would be further increases by only drawing what's
changed.
 >> Stay informed about: C# PDCurses 
Back to top
Login to vote
init13

External


Since: Nov 26, 2007
Posts: 2



(Msg. 7) Posted: Thu Nov 29, 2007 9:22 am
Post subject: Re: C# PDCurses [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On 26 ÎÏÑÂ, 22:02, "Nik Coughlin" <nrkn.... DeleteThis @gmail.com> wrote:
> <almaf... DeleteThis @gmail.com> wrote in message
>
> news:c7d4d946-57a6-46f5-a44f-90843129d030@b15g2000hsa.googlegroups.com...
>
> > On Nov 25, 9:35 pm, "Nik Coughlin" <nrkn.... DeleteThis @gmail.com> wrote:
> >> Call the Win32 API instead. Console class in .NET is *slow*. Very
> >> unfortunate Sad Especially if you want to target Mono as well.
>
> > I'm using it, and I'm not seeing this very-slowness...
>
> It seems to be OK here too now. The ast time I tried to use it was in
> VS2005 in XP, now I'm running VS2008 on Vista. The code I tested with was
> this (caution: ugly code follows):
>
> Random r = new Random();
>
> Console.Clear( );
>
> while ( true ) {
> for ( int y = 0; y < 20; y++ ) {
> for ( int x = 0; x < 70; x++ ) {
> Console.SetCursorPosition( x, y );
> Console.ForegroundColor = (ConsoleColor) r.Next( 16 );
> Console.Write( 'x' );
> }
> }
>
> }
>
> Further speed increases by only setting the cursor position in the Y loop.
> In a Roguelike there would be further increases by only drawing what's
> changed.

Yeah, that's work pretty slow Smile
 >> Stay informed about: C# PDCurses 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
Problems with PDcurses - I'd like to preface this by saying that I am VERY new to the roguelike development scene, so I'm trying to learn most of this as I go. I just picked up a copy of PDcurses, and I've been experimenting with it. addch() , addstr() and getch() seem to be..

init_color() in PDCurses - OK, along with the X11 and DOS ports, the Win32 port of PDCurses now has a working init_color() and color_content(). You can try it out now via anonymous CVS; otherwise you'll have to wait for the next release. Limitations in the Win32 port: 1) Works..

PDcurses incompatibility with fstream.h? - Okay, this is probably more reflective of my lack of understanding of C++ than anything else, but here goes. I'm writing a roguelike, I've gotten it to the point where the player can move around, look, and open/close doors, and I was gearing towards..

7DRL: Invader - Well, I've talked myself into attempting a game for the 7DRL challenge. :-) Invader will be a sci-fi RL where the player is the planet's only hope of stopping a dread alien invasion ship. The character's base of operations will be their docked ship. ....

7DRL: TBA! :P - I'm going to throw my hat into the 7drl arena by taking on a project I've wanted to do for ages. I think it will get me past the mental block of actually getting started. My concept is based around the remains of a post apocalyptic world with gang..
   Game Forums (Home) -> Roguelike -> Development All times are: Ekaterinburg, Islamabad, Karachi, Tashkent (change)
Page 1 of 1

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



[ Contact us | Terms of Service/Privacy Policy ]