-
Activity
-
57
-
1
-
9
-
9
-
9
-
9
-
-
5
boss victim calculation problem
GameLib/ActorInstanceBattle.cpp: 1. #include "../UserInterface/PythonNonPlayer.h" at the top under the other includes. 2. Look for: Below add: This will fix the problem with bosses, which are using skills. If you're talking about player sync delay this is the only solution: -
2
Unwear/swap weapon/armor with costume on [c++]
hello, is there a solution for that?
-
-
Recently Browsing
- No registered users viewing this page.
Question
Yiv 168
Dear community,
I have done a small gui (for testing) and I have a function inside:
I also added a packet which is sent from server and received by binary and I want to add inside the receive function a call of this python function with one argument (string).
How can I mange it?
Regards
Link to comment
Share on other sites
Top Posters For This Question
6
5
Popular Days
Apr 16
10
Apr 17
1
Top Posters For This Question
Yiv 6 posts
Sanchez 5 posts
Popular Days
Apr 16 2014
10 posts
Apr 17 2014
1 post
Popular Posts
Sanchez
1. Open PythonPlayerModule.cpp and add this to the static PyMethodDef s_methods[]: { "GetRK", playerGetRK, METH_VARARGS }, 2. Now still in PythonPlayerModule.cpp add this: PyObject * playerGetRK(PyObject* poSelf, PyObject* poArgs) { return Py_BuildValue("i", 15); } Add this to your py: def GetRKValue(self): return player.GetRK()
Sanchez
You can easily call a function from binary: PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_GAME], "UpdateRK", Py_BuildValue("(i)", 15)); UpdateRK - Name of your event (i) - The Py_BuildValue() Function 15 - Value what you want to push (Sure you can use variables too) Example with a variable: int pushThis = 15; PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_GAME], "UpdateRK", Py_BuildValue("(i)", pushThis));
Yiv
But now the function has to be in game.py, doen't it? I have the function in an other file named uitestgui.py. What's now? Regards
10 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now