Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / NOX - Open Source FPS DGDK Port

Author
Message
Potassium
15
Years of Service
User Offline
Joined: 12th Jul 2009
Location:
Posted: 17th Jul 2009 17:32 Edited at: 20th Jul 2009 18:36
I was searching and found a open source fps NOX on this forum writted in DB Pro. The thread is here:

http://forum.thegamecreators.com/?m=forum_view&t=111818&b=8

The thread has kind of died out. I realized it had a lot of great potential, I tryed to port this to C++ and Dark GDK.

Yes there are problems and I'm not done with converting but its open source, so whoever wants to help can go ahead. The media and the DB Pro source is found on the link above. Check the DBPro source because some of my conversions may be incorrect

The code WILL NOT COMPILE, I am aware and anybody who would like to help, please go ahead. But this is open-source so post on this thread when you have a contribution.

Code is released under GNU General Public License. I will update the code from time to time,so I will edit this post, and I suggest you check the edit post time.

Mista Wilson
16
Years of Service
User Offline
Joined: 27th Aug 2008
Location: Brisbane, Australia
Posted: 17th Jul 2009 18:03


You are declaring your arrays in the DBPro style...

There is no 1:1 equiv for arrays in DBPro in C++ unless you make it yourself(that I am aware of).. however there are alternatives..

You can either use a standard array decleration :


then access it with :


Note: the variable h_gun would have to be declared a "const int" for the above array to be able to be declared, otherwise it would need to be declared using the new operator in your code in a different manner.

Standard arrays in C++ arent dynamic, meaning they have a fixed size that cannot be increased, so the normal DBPro commands that you may be used to, wont work, aswell as they arent part of the C++ language.

The other alternative is to use the Standard Template Library and choose containers from there to use for the arrays in the program, depending on how they are being used... the benefit of the STL containers is that they are dynamic, so they can expand and shrink during runtime, and they are totally managed, so you dont need to worry about allocating and de-allocating memory for them like you would with a normal array if you put it on the heap.

Good luck with the project though.. I hope you can get the code running, it looks interesting

If it ain't broke.... DONT FIX IT !!!
Potassium
15
Years of Service
User Offline
Joined: 12th Jul 2009
Location:
Posted: 17th Jul 2009 18:28
Oh the dim was for arrays, hmph, I'm fine with arrays for the most part, like I said, this is a port, and I copied the DBPro source of NOX to Dark GDK. I never bought DB Pro, I have the trial version.

I don't know any C++ or Dark GDK command similar to exitfunction.

I'll try to fix the code so that you all can expand. I suggest you all look at the DB Pro version.
IanM
Retired Moderator
22
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 17th Jul 2009 20:46
Please PLEASE use code tags - it only takes a few second to do and makes reading your posts much easier.

Login to post a reply

Server time is: 2024-10-01 08:16:01
Your offset time is: 2024-10-01 08:16:01