• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

GameMaker Creating particle effects on a client screen and general client update for servers

P

pincholinco

Guest
I have been running in this problem for a while now it seems very hard for me to update clients whenever I add anything new to my project currently tiles are destroyed and particles get shown on my screen or the server/host screen but not on the client screen and just dont know why i modified the networking tutorial code in order to create this code if that helps so when the bomb explodes the particles dont get shown on the client any idea why that might be ?
 

FrostyCat

Redemption Seeker
There are no particles on the client side because either the server didn't send a message to the client talking about it, or the client didn't listen to the server talking about a bomb going off, or both. You can't just blindly add to a tutorial without thinking. Having a connection doesn't magically imply synchronization.

Think carefully about what correspondence chess has to do with multiplayer games, then think about which part of the concept is missing from your work:
One thing that I now demand of all networking novices is an understanding of procedures in correspondence chess, even if they don't all play chess. That's the closest physical analogue of how actual multiplayer games work, and it stops dead most rookie myths about multiplayer games.
  • The connection is not a shared board between the players on a table, it's just the mailman in a correspondence game.
  • Nothing happens on your board until you act upon mail sent out by your opponent.
  • Nothing happens on your opponent's board until you send him/her mail stating what your move is.
  • For the same reason you can't use chess notation in backgammon, bridge or StarCraft, you have to tailor the form and notation to the game.
 
P

pincholinco

Guest
so i did study it i am just saying i built upon the initial example. my problem is that I essentially don't know how to send the message to the client that the particles were created wat would that look like ?
 
P

pincholinco

Guest
sry if i wasnt clear enough I got all the basics down for example I know how to transfer the value of variable between the server and the client but when it comes to particles I am kind lost because I don't understand where the data for the particles that were created is held would this be a case of updating the particle system object for both the client and the server ?
 
If you know how to send a variable then send a boolean and client-side check that boolean and create particles depending on the value of that boolean (i.e. true = create particles, false = stop creating particles).
 
P

pincholinco

Guest
It did not work I understand better now that the client only updates if the server sends the information to the client however how do i go about updating the particle system in the client wat has to be sent from the server to the client in order to update the particle system ?
 

Slyddar

Member
You know how to send a variable between the two, and you know how to create the particles on either of them, so code the client so when some variable is set to true, the particles are created (and ensure it's then set to false again). When the server creates the particles, it needs to send a message to the client to enable that variable, which will then run that particle create code.
 
Top