Try and compile it in delphi mode in free pascal. This 'should' be good enough to make it Delphi compatible


The reason for the persistance is that say for example I want to make an enemy AI using a script. I want it to remember what it is doing in the game. During the game loop I will call the script to check the AI (Usually I do this either 10 or 5 times a second). The script should not have to requery the main application about its state but rather just use the script persistent variables.

Also remember that a game could be running many scripts in memory at the same time (eg one per sprite in the game). So also check that multiple different script files dont conflict with each other.