OTOH, you might use something like POE to get callbacks into 1 process/thread whenever an event is triggered. You could maybe even get away with using alarm() to trigger your own timeouts if you want to get that low-level.
If you are using Tk or some other GUI toolkit, most of them also have some kind of event handling to accomodate this kind of thing (see Tk::Eventloop for instance)
One other strategy that might help if you run multiple processes already (say, for instance you're running the game from CGI or mod_perl) is to use a shared data storage (like a relational database), so all data can be shared "automatically" as long as you check for updates periodically. Other options here are IPC::ShareLite and Cache::Cache.
Have fun figuring out which one you like :-)
Joost.
In reply to Re: Data copied with fork() -> how to access true data?
by Joost
in thread Data copied with fork() -> how to access true data?
by muba
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |