Open Jeremi360 opened 1 year ago
Our discord discussion stooped on this:
I was thinking that we just update SET_VARIABLE regex to just "(?
{VARIABLE}) = ((?.+)" And use str_to_var() then var_to_bytes() But I see that for example there can be problem if some one will try something like Object.new()in rkscript - for that we would need to run somehow gdsript code - I don't have idea how yet. Or maybe there is something different I don't see here ? this only way I find to execute gdscipt code from string: https://godotengine.org/qa/339/does-gdscript-have-method-to-execute-string-code-exec-python
@theludovyc I also just realize that our SET_VARIABLE
is almost just DEFINE_VARIABLE
,
in script is only possible to do x = 2
and x = 3
, but can't do x = 2 + 1
or x += 1
or logic in it x = a or b
- this is bad!
It means that now for base math and logic user need to add custom regex and it shouldn't be this way.
I just have idea how to handle it, but I need to test it first.
in script is only possible to do x = 2 and x = 3, but can't do x = 2 + 1 or x += 1 or logic in it x = a or b - this is bad
We can think about this for later version. You can make an issue 😊
we will need to convert Rakugo variables to GDScript variables before executing this code. I just have idea how to handle gdscript code, but I will post code of here it later.
Okay. I have just one question I cannot answer now, it is : if we convert them to gdscript variable how can we access them ?
We can think about this for later version. You can make an issue 😊
I made new issue #237 for it @theludovyc
Need to fix this we should be able, thanks to how godot is coded, easy be able to suport any variable type that GDScript supports.