Skip to content

Snirozu/Funkin-Script-AutoComplete

Repository files navigation

Funkin Script AutoComplete

Friday Night Funkin' Script AutoCompleter for Friday Night Funkin and Psych Engine!

Features

Haxe Scripted Classes

  • Functional Haxe completion!
  • PLANNED! Completion for Friday Night Funkin v0.3.0 Modding API

Lua

  • Function/Event/Variable auto completing
  • Warnings for deprecated functions
  • Hovers with documentation
  • API data is downloaded from the GitHub repository instead of being grabbed from local storage.

Installation

Latest Release | Latest Build

Installing VSIX

  1. Download the .vsix file from the latest release
  2. Open Visual Studio Code and select Extensions from the left bar
  3. At the top of Extensions menu click on three dots and select "Install From VSIX..."
  4. In the Install from VSIX window select downloaded .vsix file
  5. Restart Visual Studio Code
  6. Optionally you can change the targetted engine in File/Preferences/Settings/Extensions/Funkin Script AutoComplete/Lua Engine

Quick Documentation

Script Types

  • *.hxc - V-Slice (FNF v0.3.0) Scripts, they should always begin with a upper case
  • *.lua - Any other Lua based FNF Engine, like Psych Engine

Code Comments

  • Enable this extension in a file: ---@funkinScript (only if funkinvscode.enableOnlyOnCertainScripts setting is on)
  • Set FNF engine for this file: ---@funkinEngine={psych|pengine|etc.}
  • Disable deprecated warnings for specific function on this file: ---@diagnostic disable: {funcs}
  • Disable deprecated warnings for specific function on next line: ---@diagnostic disable-next-line: {funcs}

Report bugs and contribute to this extension on Github

Contributing

Any pull requests are appreciated, feel free to Pull Request any missing engines, functions or variables!
If you want to add another engine to this extension make a json file in data/ called something like "piss-engine_data.json", this data file should be based of any *_data.json file
NOTE : If you don't know how to install dependencies use npm install

You should manually add/change documentation value (if documentation is "Needs documentation", "" or doesn't exist) and a returns value (if returns is "???" or doesn't exist)

If a function is deprecated add "deprecated": "deprecated message here" to the function

Compiling and Editing the source

  1. Install npm
  2. Clone this repo with git clone https://github.com/Snirozu/Funkin-Script-AutoComplete.git (must be in empty folder)
  3. To install all the libraries run npm install
  4. And to compile run npm run build