dmarkwick 261 Posted September 18, 2007 OK, some here will know I had success in this forum getting my addon to be somewhat standalone (although it only catches BIS default classes so far), now I would like to make it MP-friendly. Of course, the config part of the addon is already MP-friendly. Anyone using the addon will see better grenades, building collapse, better vehicle smoke etc. But what people do NOT see is the scripted smoke effects based around the "killed" eventhandler. Basically, on a "killed" event a vehicle will execute a script, and from there will be directed to another script suitable for it's class. Within THAT script, there may be random differences, however I think I can restructure that to be better for MP (i.e. passing parameters in rather than randomising within the script), so that everyone sees more-or-less the same thing. Question: how can I restructure the addon to be MP-friendly? Of course I realise that each & every Drop command is not sent across the network, so how do I co-ordinate each client to execute the same scripts with same settings at the same time? Share this post Link to post Share on other sites
ricki 0 Posted September 18, 2007 the Extended Init Eventhandler maybe ? catching every class of vehicle(truck, hmmwv, tank), adding them the killed eventhandler which executes the "smoke script" regards rocko Share this post Link to post Share on other sites
dmarkwick 261 Posted September 18, 2007 the Extended Init Eventhandler maybe ?catching every class of vehicle(truck, hmmwv, tank), adding them the killed eventhandler which executes the "smoke script" Well the extended init eventhandler is there to make addons compatible with other addons, but I don't think it improved MP functionality other than this. What I was thinking was, I seem to remember that it's possible for the serving host machine to force client machines to execute scripts/functions. I'm guessing that the main script will have something like: if (!isServer) exitWith {}; then whenever a "killed" event happens on a supported class it forces the clients to run a script, and everyone sees the smoke effects. I'd like someone who knows what I'm trying to get at to give me a pointer, maybe to an example, maybe a few lines of example code. Also, how to cope with clients who may not have the addon. Share this post Link to post Share on other sites
ricki 0 Posted September 18, 2007 cope with clients who dont have the addon wont work i suppose. pm u. regards rocko Share this post Link to post Share on other sites