Gmod 13 Transformation

Hey im kinda new to the newish gmod 13 lua changes…and i was wondering how i would put this in the new lua form?


for k, v in pairs(file.FindInLua('sandbox/gamemode/scoreboard/*.lua')) do AddCSLuaFile('scoreboard/' .. v); end

Thanks for the help guys.

Dude… you and I both. The FindInLua structure has changed.

[strikethrough]Here is your direct reference: https://docs.google.com/document/d/1CIMxhvD7UX1lJPGi_DpDmPdTcVloIDYo-6AAMQl_KCs/edit[/strikethrough]
Nevermind. Changes after that as well. look in the doc below

I also recommend looking at this as well: https://docs.google.com/document/d/1khSuIYrAMkqXu7wlH5YRJNwz6hOH6Xqi5lqBhE3x6gA/edit

Cheers mate

Have a look at how DarkRP does it for an example.

https://github.com/FPtje/DarkRP/blob/master/gamemode/init.lua (around line ~125)


for k, v in pairs(**file.Find**('sandbox/gamemode/scoreboard/*.lua'**, 'DATA'**)) do AddCSLuaFile('scoreboard/' .. v); end

Oh i see it now lol. Thanks guys. Cheers

Yeah woops, was very early in the morning, had spent a long time doing ‘DATA’ didn’t even consider it was ‘LUA’ instead, my bad.