Autonauts Modding API SnippentsThis is an extention that contains snippets for all classes/functions of the Autonauts Modding API Snippet Format
SnippetsYou can type things like "modobject." (case-insensitive) and you will see options for "ModObject.GetObjectType", "ModObject.DestroyObject", "ModObject.GetObjectTileCoord", etc. Typing just the function without the function's class also works. No need to memorise which class each function comes from. TODO: gif of snippets usage Snippet ExampleModTool.CreateTool() ModTool.CreateTool( *UniqueName, --string NewIngredientsStringArr, --string[] = null NewIngredientsAmountArr, --int[] = null ObjectsToUseOnArr, --string[] = null TilesToUseOnArr, --string[] = null ObjectsToProduceArr, --string[] = null ObjectsToProduceAmountArr, --int[] = null AnimationDuration, --float = 2.0f ModelName, --string = "" UsingCustomModel, --bool = true CallbackOnComplete, --DynValue = null DestroyTarget, --bool = true ) Notes:
The snippets.json file is generated from the c# files from the game. I do not host the c# files anywhere, as they are the property of Denki Games. The program for generating the snippets.json file is available on repl.it at autonautsVSCodeSnippitGenerator. The code is not pretty, and is sparsely commented. The intermediate json files (which are just json versions of the Autonauts Modding API docs) are available there, and the snippets.json file is generated from those. When updates to the modding API are made, the c# files will need to be TEMPORARILY put into the "API" folder and the program re-run. Some fixes where made to the various c# files before processing (classes with no public API methods, typos, etc). I have 'corrected' copies of these locally, but a bit of trial-and-error would work out for anyone else. Release Notes:0.0.4Fixed trailing-comma issue after last param in snippet functions 0.0.3Fixed repo url 0.0.2Added icon 0.0.1Initial release of Autonauts Modding API Snippents |