discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Ghack - GNUstep roguelike


From: Turtle Wizard
Subject: Re: Ghack - GNUstep roguelike
Date: Tue, 12 Mar 2013 00:26:36 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3.50 (darwin)

"Dr. H. Nikolaus Schaller" <hns@goldelico.com> writes:

> Am 23.02.2013 um 18:43 schrieb Dr. H. Nikolaus Schaller:
>
>> Hi,
>> nice project!
>> 
>> Am 18.02.2013 um 20:16 schrieb elvish.healer@gmail.com:
>> 
>>> Hi,
>>> 
>>> I am working on Ghack, a roguelike game. It will be based on nethack. The 
>>> project is hosted here : https://code.google.com/p/ghack
>>> 
>>> I do not know if I will finish it.
>> 
>> Please do!
>> 
>>> There's a small map and first room generation code, a window and some 
>>> moving. Most things use xpm imagebuffer parts.
>>> 
>>> The graphics are tiles of 16x16.
>>> 
>>> Enjoy, for those who find this useful.
>> 
>> I have tried the latest git clone to adapt it for OS X and QuantumSTEP.
>> I get a first window popping up but then it fails with an undefined selector 
>> (see 3).
>> 
>> Some observations so far:
>> 
>> 1. the code uses [[NSMutableString new] initWithString:@"..."]
>> 
>> This fails on OSX, because +new already calls -init and returns some 
>> NSCFString
>> subclass that does not understand -initWithString. Please use 
>> [NSMutableString alloc] initWithString:...

One trick is to edit a file /usr/include/GNUstep/Foundation.h on macosx and put 
#import <Cocoa/Cocoa.h> in it. Then again NSString is the way to go sometimes.

It was made for GNUStep hence the roguelike.

>> 
>> 2. OS X and QantumSTEP don't have the PS() operator functions

There is GS in this case on MacOS X, with some other framework library for iOS.

>> 
>> I have added some macros to my code to build an NSBezierPath and fill/stroke 
>> it.
>> 
>> 3. there is no [con getSymbolData] method in drawRogueCharacter
>> 
>> Shouldn't that be getCharacterXpmData?

This is in development if I find the time for it.

>> 
>> 4. the code uses strndup() which is a GNU/Linux extension not available 
>> everywhere
>> 

Again, GNUStep is a UNIX/Linux system.

>> I have added the code from 
>> http://opensource.apple.com/source/gcc/gcc-5575.11/libiberty/strndup.c
>> 
>> 5. the GhackInfo.plist is missing some or using different keys for OS X 
>> (icon file, executable)
>> 
>> BR and please continue the good work!

These are in ./Resources/. It uses the mouse not the keyboard :-)

Good points, Thanks for the comment. FYI, I am working on an ObjC game for 
iOS, called zoowy the wizard : http://code.google.com/p/zoowy/downloads/list

Here's a screenshot : http://zoowy.googlecode.com/files/zoowy-screenshot-1.png

It includes a XCode project file.

Enjoy and take care,
Fyndhorn Elder.

>
> Hi,
> do you have some hints especially for issues 3 and 5?
>
> Thanks,
> Nikolaus


reply via email to

[Prev in Thread] Current Thread [Next in Thread]