.:: Bots United ::.

.:: Bots United ::. (http://forums.bots-united.com/index.php)
-   HPB_bot (http://forums.bots-united.com/forumdisplay.php?f=35)
-   -   Compiling dlls with MingWing (http://forums.bots-united.com/showthread.php?t=3701)

Whistler 21-03-2005 02:51

Re: Compiling dlls with MingWing
 
if you are using Dev-C++, you can change the dll filename in Project->Project Options->Build Options->Override output filename

the Template source code will build a playable HPB_bot.dll file (non-metamod version), but it won't support waypoints.

edit:
I've also made HPB bot 3.0 source code (full non-metamod version with waypoint support) buildable with MinGW/Dev-C++, so if you need it:
http://filebase.bots-united.com/inde...on=file&id=286

Beasty 27-03-2005 07:36

Re: Compiling dlls with MingWing
 
Sorry for this really late reply! I was on a short holiday. Anyway, I get this error when starting a game:

*****
Can't load 'E:\SIERRA\Half-Life/MY_MOD\cl_dlls\NoVGUI.dll'
*****

Is there a way to turn VGUI on for my mods?

Whistler 27-03-2005 11:08

Re: Compiling dlls with MingWing
 
copy the NoVGUI.dll (which is included with botman's SDK patch in cl_dll folder) to your Half-Life\valve\cl_dlls folder and it should be okay.

also you can't use the VGUI scoreboard with MinGW

Beasty 28-03-2005 02:43

Re: Compiling dlls with MingWing
 
Alright, thanks! I'm a bit curious about this VGUI stuff. Is the VGUI scoreboard the scoreboard when you hold tab in a multiplayer game? And why can't you use it in MinGW?

Pierre-Marie Baty 28-03-2005 04:43

Re: Compiling dlls with MingWing
 
Yes, it's that one, and it can't compile on MinGW because the code uses Microsoft-specific parts (I suppose it's some MSVC assembly) that have not been "translated" to GCC style yet.

botman 28-03-2005 15:42

Re: Compiling dlls with MingWing
 
The problem with using VGUI is that all you have is vgui.lib which was compiled with the MSVC compiler using MSVC C++ linkage. There isn't any other compiler or linker than can handle the Microsoft method of name mangling in C++, so you are stuck using only the source code that you can compile (which is the SDK).

If Valve had created a COFF version of the VGUI library, you would be able to link against it with other compilers/linkers, but they didn't, so you can't.

botman

Pierre-Marie Baty 29-03-2005 01:04

Re: Compiling dlls with MingWing
 
wrapper DLL ? :)

Beasty 29-03-2005 08:23

Re: Compiling dlls with MingWing
 
Oh, alright! So does the scoreboard display a sort of list in the center when you hold down tab instead? And what is wrapper.dll?

Pierre-Marie Baty 29-03-2005 08:48

Re: Compiling dlls with MingWing
 
yes, it's the old style scoreboard. The wrapper DLL was just an idea... a workaround, sort of. But it's meaningful to coders only :)

botman 29-03-2005 16:10

Re: Compiling dlls with MingWing
 
The NoVGUI.dll is essentially a wrapper DLL (that only wraps one function necessary to initialize the client display). In order to do a wrapper DLL, you'd have to use MSVC to build it (since MSVC is the only one that can handle VGUI.lib) and export all the functions with standard C linkage (plain non-mangled names). This would destroy the C++ aspect of the VGUI library (since you don't have classes with standard C). Destroying the C++ aspect of the VGUI library would make it kind of pointless as a mod feature since it would be difficult to create new (custom) VGUI windows.

It might be easier just to create your own VGUI library and re-implement all the work that Valve put into the VGUI library (there are MANY Linux GUI libraries that you could start from that are open source), but this would take quite a lot of work and wasn't worth it in my opinion.

And it's worth even less now that you can download the MSVC command line environment (.net 2005 beta) for free. If you don't want to compile using Microsoft's tools, because you don't like Microsoft, just keep in mind who's operating system you are running the game on anyway. :)

botman


All times are GMT +2. The time now is 10:53.

Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.