Product Chat / Lua Require DLL

Author
Message
Kalinko213
3
Years of Service
User Offline
Joined: 9th Oct 2021
Location:
Posted: 10th Oct 2021 21:12
Hello again

I have a DLL File and I want to use require:

For instance: The dll file is called "example.dll":



I am placing the code in the global.lua file in the GameLoopInit function:


Gameguru tells me that the file could not be found:


I have placed the dll file in almost all directories:
Game Guru Main Directory
Game Guru\Files
Game Guru\Files\scriptbank

Guys can you please help me?
Thanks in advance
PM
3com
10
Years of Service
User Offline
Joined: 18th May 2014
Location: Catalonia
Posted: 10th Oct 2021 23:36
DLL has nothing to do with global.lua and/or GameLoopInit function.
DLL is a system library and it should be registered and called thru the engine internal code itself.
I have no idea about steam, but most likely it should do so, via the internal code.
I dare to say if TGC wants GG linked with steam the way you want to, GG could have their own dll to do so. imho
Laptop: Lenovo - Intel(R) Celeron(R) CPU 1005M @ 1.90GHz

OS: Windows 10 (64) - Ram: 4 gb - Hd: 283 gb - Video card: Intel(R) HD Graphics
cpu mark: 10396.6
2d graphics mark: 947.9
3d graphics mark: 8310.9
memory mark 2584.8
Disk mark: 1146.3
Passmark rating: 3662.4

PM
Kalinko213
3
Years of Service
User Offline
Joined: 9th Oct 2021
Location:
Posted: 11th Oct 2021 00:23
There are C extension modules for Lua and these modules are to be loaded by require()

Link: http://lua-users.org/wiki/BuildingModules

Example: I have the module ABC (abc.dll) I can load the module this way:



After that I can run functions that are available in this module:


PM

Login to post a reply

Server time is: 2024-11-23 07:56:28
Your offset time is: 2024-11-23 07:56:28