freeablo icon indicating copy to clipboard operation
freeablo copied to clipboard

Scripting

Open wheybags opened this issue 11 years ago • 6 comments

wheybags avatar Feb 23 '14 18:02 wheybags

We got working python so I think issue can be closed.

konopka90 avatar May 28 '16 18:05 konopka90

What will Python be used for? I was hoping for mods to be lua based.

tilkinsc avatar Dec 22 '17 07:12 tilkinsc

Yup, current plan is lua, but we'll see what is best when the point comes

wheybags avatar Dec 22 '17 12:12 wheybags

Lua has the ability to be flexible in that you can sandbox an environment very very easily especially inside itself without any C code. I'm a Lua person and I have the know how to do such things.

tilkinsc avatar Dec 22 '17 22:12 tilkinsc

cling based C++ as scripting language / hot code reload Why? Able to run C++ script in runtime or compile it for max speed ( as in example https://github.com/derofim/cling-cmake ) Also: May be used to improve modules compile time

HOT code reload possible approaches:

store app state fix cling undo for files https://root-forum.cern.ch/t/loading-unloading-class-as-interpreted-macro-in-cling-multiple-times/32976/2

execute cling code to change callbacks & variables nested cling::Interpreter with multiple cling::MetaProcessor IDK how to do it, but you can create child cling::Interpreter

blockspacer avatar Aug 24 '19 16:08 blockspacer

Copy discussion from PR:

there are some issues to work out with whatever scripting language we use. The primary use case for it will be scripting in mods, and mods scripts will need to be deterministic just like the rest of the game code, in order for multiplayer to work. This means they will need to use our FixedPoint class for maths. Given that, I'm not sure if we shoudl try to hack FixedPoint into an existing scriping language, or if we should just make our own simplistic langauge. In particular, since FixedPoints can be a bit slow, it would be nice to use a language that distinguished between integer and real number types, so people could only use FixedPoint operations when they actually needed them.

wheybags avatar Feb 20 '20 10:02 wheybags