Say I have a game which has lots objects (NPCs, monsters, etc.), I want a console so I can change the variables of the objects (like changing HP for example), how could I embed python into my program, so that I can change these variables and classes with a few keystrokes in the console? An example of a command would be: /monster 1 1 HP 100
(monster
is the object name, 1 1
is the coordinates, and HP 100
is the variable to change, and to what amount)
Take the 2-minute tour
×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.
|
|||
#include <Python.h>
with python in the project directory – bboy3577 Mar 12 at 10:05