Skip to content
This repository has been archived by the owner on Aug 4, 2023. It is now read-only.

Fixed loading of start_script.py - it will be loaded as fast as possi… #200

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

igadmg
Copy link

@igadmg igadmg commented Jan 2, 2023

…ble - original hook was not wokring, now it try until console.startScript is available

Original code was waiting for PyRun_StringFlags_S to be called, but it never was. Anno is creating some objects and use PyObject_CallObject

That patch waits until it is possible to run console.startScript and execute all registered mod scripts.

…ble - original hook was not wokring, now it try until console.startScript is available
@jakobharder
Copy link
Contributor

Python has been replaced by Lua recently. Even though no further seasons are planned, I wouldn't rely on Python at this point.

@igadmg
Copy link
Author

igadmg commented Jan 3, 2023

Wow, really, that explains why some scripts are written on lua in dlcs now.
But actually, I don't think they will remove python support completely. Yet we need to think how to implement injection to lua calls the same way as we do for python. And I think the same logic can be then applied for lua scripts.

Interesting question is - are actions assigned to keypresses in assets.xml - are they executed as lua code or as python code?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants