Quote from: Nawm on May 20, 2010, 07:39:33 pm
Okay... the HTML help file is unclear. It doesn't explain hosting very well, so I'm stuck at the moment.
Like.. how do I make it, so that other people, such as my friends can play.
Have you ever heard of the Internet and the information that is out there, my friend?
@G_G:
The method nathmatt posted:
def self.main
# while server is running
while RMXOS.server.running
self.server_update #server is running
sleep(0.1) # 0.1 seconds pause, decreases server load
end
# YOUR CODE BEFORE SHUTDOWN GOES HERE
# server is shut down
end
Clicking X kills the server and I don't think there's a way around that. The only actual way I could think of would be that the server writes to a file every 5 seconds and if the file hasn't been modified for more than 10 seconds, everything outside of RMX-OS knows that RMX-OS isn't running anymore.
As for the other plugins...
RMX-OS is not related to the game in any way. There is almost not game data on the server. The only game data that is on the server while it's running is the data that is required for other clients to know where the client is standing, etc. You can't give people gold on the server and expect it to appear in game. RMX-OS is a server, not a client. It synchronizes clients. It does not run a messed up copy of the game like Netplay (hence RMX-OS runs a lot faster than Netplay).
You can always use the message code EVA when sending clients a message that they should interpret.
client.send("EVA$game_party.gain_gold(1000)")