Syncing Randomly Spawning Objects
I've made an asteroids game and i want to make it multiplayer with two ships battling to get the most amount of points. I have 5 asteroids randomly spawning within an obj_spawner in the step event. this is what i have.
if (!instance_exists(obj_asteroids)){
instance_create(random(room_width),random(room_height), obj_asteroids);
instance_create(random(room_width),random(room_height), obj_asteroids);
instance_create(random(room_width),random(room_height), obj_asteroids);
instance_create(random(room_width),random(room_height), obj_asteroids);
instance_create(random(room_width),random(room_height), obj_asteroids);
}
and in the create event of the asteroid it sets its random direction, speed, and x,y postition.
how do i sync this so all players will see the same asteroid in the same position?
Replies (1)
Last message on 27 Aug 2016
Size43
(Administrator)
on
27 Aug 2016, 13:34:32