Closed Jak2k closed 6 months ago
Yes, scripting support is available when downloading, but not in the browser.
Yes, scripting support is available when downloading, but not in the browser.
This seems acceptable to me, as people who are interested in scripting are likely to know how to clone the repository and run the game locally. Plus, I have a hard time imagining how that would work in the browser. Would we have to select our script file from a dialog in the game? How would debugging work? Would we have to re-upload the script after every change? Is it even possible to open a local file from a Python program compiled to WebAssembly and running inside a browser? Please provide more details on the implementation you have in mind.
Maybe let users script using JS, that calls the functions, which would be called by user interaction.
I am not sure how I would go and implement a way to interact with the Python code from JavaScript, nor how it would solve the other problems. I am closing the issue again for now as I will not implement this. If you submit a pull request, I will look at it.
Scripting support is already implemented, as indicated in the README.