Page 1 of 1

Integrate Torch7 into LÖVE?

Posted: Mon Nov 20, 2017 8:14 pm
by SirRanjid
Hello I just started using löve which is super easy however I have no clue how to build a new love.exe with torch(http://torch.ch/) included.

I followed "https://love2d.org/wiki/Building_L%C3%96VE" as far as possible (win 8 x64). So I got the löve and the torch source (both 64bit luajit (löve c++, torch c)).

I noticed the CMakeList.txt with all the source contents of löve. Do I have to edit it manually and how to? Where to put torch?

Re: Integrate Torch7 into LÖVE?

Posted: Mon Nov 20, 2017 10:27 pm
by bartbes
I don't think you need to compile torch into love, just stick the dll (compiled for lua 5.1) next to the exe and require torch.

Re: Integrate Torch7 into LÖVE?

Posted: Tue Nov 28, 2017 1:26 pm
by josip
I'm really curious what you want to use Torch for? Combining ML and gamedev gets my imagination running wild.

Re: Integrate Torch7 into LÖVE?

Posted: Tue Nov 28, 2017 2:41 pm
by SirRanjid
josip wrote: Tue Nov 28, 2017 1:26 pm I'm really curious what you want to use Torch for? Combining ML and gamedev gets my imagination running wild.
Mine too c:

At first I just wanna play around. Maybe gui improvements. But mostly the enemy AI player... I wanna let 2 AI's compete for long enough to get a decent bot. The pro side is every action has the same computing time.

Another thing I have in mind are Zombie-AIs since they are not very intelligent. I could use some of them and alter each zombies ai by applying some jitter to the weigths... many many possibilities.

My problem is still how to get the lua functions into the game but I delayed it til my game is at that state^^