Posted 17 November 2013 - 01:57 PM
Unlike all other's new language request, my thing is i coding it!
https://github.com/EcmaXp/PyCraft
Problem is very hard to rewrite with lua. (eg. support metaclass, parse the arguments)
So i have some choice.
* Run python code in real interpreter
- with some resist (memory limit are possible, ASTVisitor + weakref can track all value)
- and use socket (or queueEvent? slow) for call lua function (If we can do that, really happy)
- and can't call python function. only python -> lua are allowed;
- problem is i don't have good skill with Java, and Modding.
- Calling lua function is slow, but run python is fast.
- It will spawn one python (or pypy) process.
* Run translated-python code in Computer
- (that is lua code, and my code do that, and limited)
- Calling lua function is fast, but run python code is slow.
- We can mix lua object + python object (not suggest, but lua code can call python code.)
- It don't need mod but http or other thing need for translate. (for run python compiler)
* write PyPy backport for lua
- Never choice me?
* Run Jython
- http://www.computerc...aft-for-mc-16x/
- It use Jython, but 2.5; i love Python 3k, not 2.x
- I can rewrite python-part inital code.
First method are almost look's like CC's Language API.
Second method are some people say that. but i think run translated-python code are slow than normal lua code.
4th method, i don't like it. (but that is look's like First method)
Q1. What is best?
Q2. First and Second Method, What is more fast? (Case: GUI programs, and CUI programs with no user input, etc.)
Q3. ?
Q4. 4's Method, That are add the new block for run python code. I don't like that, Can I add new api directly to Lua? (like builtins os api (lua part))
Q5. If i choice first method, It is possible calling python function in lua? (And in python function, call the lua function)
Q6. How i download the dependency libary (like msgpack-java, jython, or ForgeMultiparts) in mod (java-code)?
https://github.com/EcmaXp/PyCraft
Problem is very hard to rewrite with lua. (eg. support metaclass, parse the arguments)
So i have some choice.
* Run python code in real interpreter
- with some resist (memory limit are possible, ASTVisitor + weakref can track all value)
- and use socket (or queueEvent? slow) for call lua function (If we can do that, really happy)
- and can't call python function. only python -> lua are allowed;
- problem is i don't have good skill with Java, and Modding.
- Calling lua function is slow, but run python is fast.
- It will spawn one python (or pypy) process.
* Run translated-python code in Computer
- (that is lua code, and my code do that, and limited)
- Calling lua function is fast, but run python code is slow.
- We can mix lua object + python object (not suggest, but lua code can call python code.)
- It don't need mod but http or other thing need for translate. (for run python compiler)
* write PyPy backport for lua
- Never choice me?
* Run Jython
- http://www.computerc...aft-for-mc-16x/
- It use Jython, but 2.5; i love Python 3k, not 2.x
- I can rewrite python-part inital code.
First method are almost look's like CC's Language API.
Second method are some people say that. but i think run translated-python code are slow than normal lua code.
4th method, i don't like it. (but that is look's like First method)
Q1. What is best?
Q2. First and Second Method, What is more fast? (Case: GUI programs, and CUI programs with no user input, etc.)
Q3. ?
Q4. 4's Method, That are add the new block for run python code. I don't like that, Can I add new api directly to Lua? (like builtins os api (lua part))
Q5. If i choice first method, It is possible calling python function in lua? (And in python function, call the lua function)
Q6. How i download the dependency libary (like msgpack-java, jython, or ForgeMultiparts) in mod (java-code)?
Edited on 17 November 2013 - 01:21 PM