PDA

View Full Version : Rogue Variants



bowesben
07-13-2008, 06:45 AM
Hello all, new to the forum (and to ADOM). I fell in love with the genre as soon as I stumbled upon it some time ago. I would love to develop my own Roguelike, and as I'm already developing another project in Java, I see no alternative but to try my hand in creating a roguelike in java as well.

My problem is not unique, but have been as of yet unable to discover a plain and simple workaround regarding dealing with curses. My only option (development wise) is to work in Java (I'm using NetBeans), with my Mac (os X). All solutions dealing with Java and Curses *assume* a windows platform is being used.

I'm currently stuck on how to implement a java JNI wrapper class:
[SOURCE: http://roguebasin.roguelikedevelopment.org/index.php?title=Java_Curses_Implementation]
- Implementation code (excerpt) reads as follows
public int JniCurses()
{ init(); }

of course, I get an error when compiling (missing return statment), so I add the following lines in method:
int JniCursesFlag = 1;
return JniCursesFlag;

the next compile error is: [no JniCurses in java.library.path]
this refers my attempted use at an unreferenced dll file:
(Code Excerpt) [static { System.loadLibrary("JniCurses"); }]

-I know half of what I'm doing wrong (trying to use DLL files on a MAC system...), but is there anything that can be done?
Again, I can only use Java, and I refuse to go back to using windows.

Thankyou all in advance for any help that can be offered, and I look forward to sharing ideas and thoughts with you all in the future:)