This is a demo application.
This means that it doesn't work in every situation and contains errors when it's not used how it's supposed to be used. If you notice that something is broken, please open an issue or, even better, open a PR with the solution.
- If too many pods die at the same time some script errors will occur and multiple models will spawn. (Don't spawn too many enemies)
- If too many pods are on a server the GUI doesn't scale with the amount of pods
- Garry's Mod
- Steam Account
- Buy here
- Kubernetes cluster
- Can be a minikube instance
- Needs localhost:8001 access to Kubernetes API through
kubectl proxy - This code is tested on a 1.9.7 cluster
- Make sure your cluster is running and you're able to connect to it with
kubectl proxy.- There needs to be an active API connection.
- You can test this by connecting to the GUI through the browser
- Install the customizations into Garry's Mod
- Search for your Garry's Mod folder in your filesystem.
- On Windows this is default under
C:\Program Files (x86)\Steam\steamapps\common\GarrysMod\garrysmod - On MacOS this is default under
/Users/<USERNAME>/Library/Application Support/Steam/steamapps/common/GarrysMod/garrysmod
- On Windows this is default under
- In this folder should be a Lua map.
- Drop chaos.lua in
lua/folder - Drop gui.lua in
lua/autorun/clientfolder
- Search for your Garry's Mod folder in your filesystem.
- Open up Garry's Mod and start a new singleplayer game.
- The coordinates in this demo are designed for the map gm_flatgrass
- Open up the console and type
lua_openscript chaos.lua- Default the console is the button under the escape key.
- Press Q and at the top of your screen an NPC menu should appear. Click it and disable Join Player Squad.
If you completed these steps the game should've spawned you on top of a building looking towards some pillars.
These pillars symbolize a node.
The size of each area is dependend on the amount of memory present in the node.
Models will spawn in the node area's. The model is dependent on the image tag.
These image tags need to be either
- v1 --> npc_citizen
- v2 --> npc_kleiner
Otherwise it will default to the v1 model. Each model = specific pod.
- By pressing
Ythe chat window should appear, typeSpawnBugsand "bugs" will start spawning in random nodes. - By pressing
Yagain and typingStopSpawnBugs, the "bugs" will stop spawning but existing "bugs" will not disappear. - By pressing
Yagain and typingDespawnBugs, the "bugs" will stop spawning and all existing "bugs" will disappear.
The containers will spawn on a 3 second timer. So updates aren't instant.
You can either reset the state of the map by restarting the map or using the console.
- Restarting the map
- Press
ESCand click start new game. - Select the same map and everything should reload
- Press
- Console
- Default the console is the button under the escape key.
- type
gmod_admin_cleanupand the map should reset.