Importing external pthon modules


(gorgan_almi) #1

Is this a bug or a delberate security feature?

cose if its a security feature then its a pretty bulsey one, bit like the one introduced in 2.2x that stops seperate python scripts from sharing global variables and functions. :x

Why does this make me so cross? Well I’m developing a game using event-based Python scripts a much as possible, and logic bricks as little as possible. My game only uses logic bricks to detect the events and launch the python scripts. This in my view is the best way forward, as it gives the programmer as much flexibility as possible. But for this method to work you needed to be able to share global variables and functions between scripts. When that was blocked I found I could get away with having the majority of my scripts as imported modules. But if that doesn’t work either in compiled exe’s then my method is impossible and my entire work useless!

If these are security features then you should be able to turn them on and off when editing the game. Does anyone know if importing modules will eventually be possible in compiled games?

Thanx,
Keith.

P.S. Sorry for cross-posting but I felt this topic was relevent to both forums.