Jump to content
  • Advertisement
Sign in to follow this  
vexille

Is it possible to use HGE on Netbeans?

This topic is 3209 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'd really like to think so. I've been trying for a little while, but I just can't get it to work. I'm kind of blindly trying since there's no tutorial on setting up HGE specifically for Netbeans. Here's what I did: In options > C/C++ > Code Assistance > C++ Compiler I've added hge\include and hge\lib\gcc. In the project properties, under C++ Compiler, I've set hge\include as the Include Directory. And I've also added hge.lib from lib\bcc to the Header Files folder in the project. Then I've trying running the first tutorial(http://hge.relishgames.com/doc/html) and I get a "undefined reference to `_hgeCreate@4'" error. I'm sure I've done something ridiculously wrong with all that fumbling around, so I'd really appreciate if someone could shed some light on that for me. [Edited by - vexille on October 31, 2009 12:20:59 PM]

Share this post


Link to post
Share on other sites
Advertisement
Oh okay, that's good to know. But I'm still not sure how to handle what I should add to the project. Should all those files in the include folder be in the project's Header Files? And what should be in the C++ Compiler thing in the options?

Share this post


Link to post
Share on other sites
I haven't used C++ in Netbeans, but here are the things you would need to set up HGE in any IDE.

  • You'll need to add the include directory of HGE to your include directories. This is usually specified as an IDE-wide option, but apparently in Netbeans it's per-project instead.
  • Similar, add the lib/gcc directory of HGE to your library directories. Same as before, this is usually IDE-wide, but apparently per-project in Netbeans.
  • You need to tell the linker to link to the libhge.a library. This is definitely a per-project setting.

After that, you should just be able to #include <hge.h> in your project to get access to HGE functionality. To clarify, you don't need to add any of HGE's include files to your project directly, instead you just #include <hge.h> in your own files.

You don't need to mention the lib/bcc directory, that's for Borland compilers only.

Share this post


Link to post
Share on other sites
Oh man, that did it! I got so used to working with Netbeans for Java projects that I just didn't want to let go of it. Thanks a lot, Matt :D

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!