VS Code’s pretty great and is even better with UPBGE autocomplete! To get it working, do this:
On Windows (apparently works on Linux too!):
- Install VS Code (duh) & the Python addon by Don Jayamanne
- Download & extract BGEMockGen.zip from post #8 here: https://blenderartists.org/forum/showthread.php?414680-Mock-BGE-Python-API-for-Autocomplete&highlight=scrapper
- Open cmd prompt (perhaps right in VS Code, ctrl+shift+`)
- Navigate to where you extracted the BGEMockGen.zip (where the file make.py resides)
- add the following below line 350 of make.py in extracted BGEMockGen dir to get all the API
build(url + "bge.render.html")
- (assuming python is in your path & still in the make.py file location) type:
python.exe make.py
6a) If make.py errors out with missing module “requests” like it did for me, try running the following and go back to step 5 if successful:
pip.exe install requests
- In VS Code, open Settings (File > Settings) & locate “python.autoComplete.extraPaths” and hit the little pencil that appears next to it
- A text panel should open to the right. Edit the C:\Path\To\BGEMockGen\API bit (duh again):
{"python.autoComplete.extraPaths": ["C:\\Path\\To\\BGEMockGen\\API"]}
- Save or something & restart code (not sure if this is necessary but :shrug-emoticon: )
Viola, you should be able to autocomplete bge code with the best of them now!
PS Thanks to elmeunick9 for the scraper & TwisterGE for Linux testing this method/UPBGE in general!!!