So i made both of my players shooting when they pick up the bow & arrow.
But when player 1 shoots player 2 does it as well.
(i also gave ownership still)
Screenshots down below.
Lol…no need to apologise…but I’m having an operation on my right eye in a few hours and I can guarantee it’ll be more fun than sorting out multiplayer ownership issues.
Have you definitely been through the example projects and painstakingly looked through all the multiplayer conditions and ownership actions?
I think you need a condition to check which player is playing
Hi Dave!
Good luck!
See you soon.
A+
Xierra
I’m in the waiting room! Yes … I think you need that ownership condition…these things are basically like trying to flick a pea into an eggcup from 50 yards away
So i tried the : Is object Owned by Current player? (Condition)
And when i did, RESULT! it worked, but as soon as both of the players shoot some of the keys wont work like jumping, it does it really late, like what im saying is that it lags alot!
Ok …progress though! We to see the rest of the events… there’s some sort of conflict going on somewhere.
Is that all the events?
I don’t think you need the ownership actions to happen every frame - just at the beginning.
When you say that the keys aren’t working - you have clicked in the right window? so there’s two players and you’re testing in two windows?
Yup two windows, two players. If you want all the events you’re gonna have to wait a while for me to take a vid, and about the keys, i tested again, only player ones arrow keys and jumping is ssoooooooo lagy, while player twos is only a little bit laggy.
ok then! - give me time to digest it!
You can tell how much fun this stuff is by the number of people who have got involved in this thread.
The key to multiplayer success, and the reward of there being a faint whiff of a possibility that two people play your game at the same time is… ‘ownership’
I had to go back to my game ‘the gods of stonehinge’ from last year and it’s full of lots of this sort of thing…
Whether it’s correct - lord only knows! I just did it repeatedly in umpteenth different arrangements until it stopped not working.
It seemed that you needed to take ownership of variables and objects after you made a change - I know! by that point I’d almost lost the will to keep going. But keep going I did! It’s in my blood you see - Dunkirk, and all that! I stood strong!! I kept going!!! I took ownership of the variables after each player had changed them - And you know what!!! - It worked!!! Lord how it worked!! Even the AI bot that takes over in an empty lobby worked …And I published it on itch and gd games -----and no one has, or ever will, play it as a multiplayer game.
back to your project!
Those ownership events don’t need to be every frame - just when the game starts as you only need to use that action every frame on the objects that are changing hands during the game.
here’s the event to set ownership from my game when the game starts
Any variables or objects that are being moved or changed - you need to check which player is playing and then take ownership in the action after you change them. So that includes things like ‘Checkpoint now’ and any objects that are being interacted with
I can’t at the moment see why it’s laggy other than there being lots of collision checks - are there too many bullets being fired?
No as far as i know, i added a firing cool down. Btw srry for the late response .
Have you read this - top to bottom? - as I hadn’t and I probably should have!
GDevelop Multiplayer - GDevelop documentation
Well yes i have multiple times cuz ppl keep telling me when i have multiplayer prblems.