juicebta.blogg.se

Gmod lua test chromium
Gmod lua test chromium









gmod lua test chromium

Alternatively, clone this repo in your GarrysMod\garrysmod\addons folder.

gmod lua test chromium

Note: This requires Windows and 64-bit Garry's Mod. Hope you enjoyed my guide.A Garry's Mod addon that uses libsm64 to put a playable Mario in the game. Note, that all client and shared files must be put for download using AddCSLuaFile for them to work in multiplayer. To make the script run automatically when the server starts, you simply put it into one of those folders:įor shared scripts ( Loaded on both client and server )Ĭ:\Program Files\Steam\steamapps\common\garrysmod\garrysmod\lua\autorunįor client-only scripts ( Loaded only on client )Ĭ:\Program Files\Steam\steamapps\common\garrysmod\garrysmod\lua\autorun\clientįor server-only scripts ( Loaded only on server )Ĭ:\Program Files\Steam\steamapps\common\garrysmod\garrysmod\lua\autorun\serverįor this specific tutorial any of those paths will work just fine. If you did everything correctly up to this point you should see a message in the console : Now, open the console and type the following : To run any of your scripts you need to be playing a map. Now, just press enter (or press the save button) to save your script. lua), and in the Save As type box, select All Files. In the filename box, type a (Note that you must specify. To find your lua folder follow the following path - this may be slightly different on your computer, but will look something like this:Ĭ:\Program Files\Steam\steamapps\common\garrysmod\garrysmod\lua\ You're now ready to create the actual Lua script file. In this case, print() takes only one argument, which is a string (a series of letters, numbers, spaces, and so on), and when Msg() is called, it puts that string into the console in Garry's Mod. Many functions can take arguments, which is data you give the function to change exactly what it does. A function is a command that does something when you call it. You're done! Wasn't that easy? It should have been. Type the following code into your chosen editor : We'll learn how to send a message to the console. As a rule of thumb, if you can have text that uses two different fonts in one file, then it is not a plain text editor.įor our first script, we're not going to do anything too complex. It will put useless tags in around your code that will cause it to fail when loading. It is a formatted text editor, not a plain text editor. A plugin you may want to use with Notepad++ would definitely be the Gmod Lua highlighter: įor the sake of simplicity we'll refer to both as "notepad". You can use any text editor, but to make your life easier, we recommend that you use Notepad++. To create and edit these scripts you need a plain text editor such as notepad.

gmod lua test chromium

A lua file is called a script, it's plain text.











Gmod lua test chromium