Compiling dll problem Created 4 years ago2020-05-13 12:25:38 UTC by Zhouy Zhouy

Created 4 years ago2020-05-13 12:25:38 UTC by Zhouy Zhouy

Posted 4 years ago2020-05-13 12:25:38 UTC Post #344208
Hello,

I recently picked up some coding I used to work on 6years ago. I tried compiling my code, and got a compiling error c2668. I solved this though, and my dll finally compiled.

However, when I moved the hl.dll to my mod dir and started the game, it's just like regular hl. It's like visual studio just ignored all my coding and compiled a default hl dll. I doublechecked to see if it compiled the right files, and that's what it should do.

I made some custom settings to other things like some hl maps and server settings etc and with this new dll, all my editing here is also ignored.

I think I used to have SDK 2.3 and now I downloaded SDK 2.4, to make it more compatible with newer versions of virtual studio.

Anyone knows what's going on? Maybe I should just download a earlier version of virtual studio and compile it like I used to back in the day? It's been a long time hehe..
Posted 4 years ago2020-05-13 15:07:37 UTC Post #344209
What code did you exactly change or add?
Chances are, if you switched to HL SDK 2.4, you maybe overwrote all the changes you did to your 2.3 SDK.

BTW about newer versions of Visual Studio, you should use Solokiller's updated HL SDK, works with Visual Studio 2019 even.
https://github.com/Solokiller/halflife-updated
Admer456 Admer456If it ain't broken, don't fox it!
Posted 4 years ago2020-05-13 15:43:01 UTC Post #344210
I tried this now:

I downloaded the SDK in your link because it's a newer version than the one I have. I compiled without change any code, it works alright.

Now I replace gauss.cpp with my modified work from 2014, where I make the gauss behave the same way in multiplayer like it does in singleplayer (longer chargin, unable to fly in air etc.). I know it should work because I compiled this before, and have an old compiled hl.dll from 2014. It compiles fine but no changes happens with the gauss. (This was just one of my modified cpp files for testiing purposes)

Maybe I should just stick to Virtual Studio 2010 and SDK 2.3? Maybe it's bad anyway to copy my modified SDK 2.3 files to 2.4 as these new cpp files might have updated code. And it's not like I want to recode all my old work :)
Posted 4 years ago2020-05-13 16:06:03 UTC Post #344211
Did you compile both DLL files? Weapons are both in hl.dll and client.dll.
Admer456 Admer456If it ain't broken, don't fox it!
Posted 4 years ago2020-05-13 16:19:34 UTC Post #344212
Thank you for your answers, yes I did. :glad:
Posted 4 years ago2020-05-14 20:39:13 UTC Post #344215
Well, here's what you can do.

Use something like WinMerge or any code comparison website, compare what you've changed between HL SDK 2.4 and your own .cpp files.
And then carry over the differences to the updated SDK for VS2019.
Admer456 Admer456If it ain't broken, don't fox it!
Posted 4 years ago2020-05-16 03:47:36 UTC Post #344223
What's in your mod's liblist.gam file?
Posted 4 years ago2020-05-18 19:06:20 UTC Post #344231
Touché... If it is not in the liblist.gam file it should not work.
Posted 4 years ago2020-05-19 17:27:17 UTC Post #344240
compiling dlls is "quite hard"
I think you should get a second hand CD with MSVC++ 6.0, that´s what I did finally from a guy here in Spain (10€ lucky me!!).

Search on EBay and for less than 50$ your problems will go away. :)

If you want I can give you the old tutorial from TWL about set up MSVC++ and compiling both client and server dlls with which I am working for the last 15 years.

Warning: I am NO CODER, I can barely modify things here and there, I still don´t know how to do the "HELLO" program... :/
Posted 4 years ago2020-05-19 18:27:54 UTC Post #344241
"Search on EBay and for less than 50$ your problems will go away"
Or, you know, you can just get Solokiller's updated HL SDK, and Visual Studio Community 2019, and pay 0$.

Visual Studio 6.0 is practically abandonware (abbadon-ware :glad: ), and you can get it for free if you got a Microsoft account with the Dev Essentials thingy. At least I think so. Many older versions are available there after all, so.
Admer456 Admer456If it ain't broken, don't fox it!
Posted 4 years ago2020-05-20 21:05:04 UTC Post #344254
Hold up. Sixcentgeorge, is that you?
Admer456 Admer456If it ain't broken, don't fox it!
You must be logged in to post a response.