Jump to content
Sign in to follow this  
Fuzzy Bandit

Creating JIP-compatible markers on the fly

Recommended Posts

One thing I've always struggled with is creating markers on the fly and having them sync up with JIP players.

I've worked around this in the past by having all my markers created before-hand (placed in the Mission Editor) and then simply cycling through each of them on the client doing...

"myMarker" setMarkerPos (getMarkerPos "myMarker");

Now that works, but it's messy and requires that I have all markers placed prior to the start of my mission.

So, what's an elegant way to make this work? I want to be able to create/delete a marker at any point and have all JIP players be able to see / no longer see said marker. Now I'm aware there's a CBA function (something along the lines of setMarkerPersistant?), but I'd much prefer to not have to rely on a large library when all I need is one function.

Ideas? :)

Share this post


Link to post
Share on other sites

Markers placed both in editor and by script are now synchronized automatically, no need to hack it around ;)

Share this post


Link to post
Share on other sites
Markers placed both in editor and by script are now synchronized automatically, no need to hack it around ;)

Markers created server side via createMarker (and their modifiers) are globally synched even for JIP players? Is this new because when I was scripting during alpha, this was not the case.

Share this post


Link to post
Share on other sites
Markers created server side via createMarker (and their modifiers) are globally synched even for JIP players? Is this new because when I was scripting during alpha, this was not the case.

I think he's reffering to player created Markers during the Mission. I think CreateMarker on it's own is still not JIP Compatible.

Share this post


Link to post
Share on other sites
I think he's reffering to player created Markers during the Mission. I think CreateMarker on it's own is still not JIP Compatible.

Well those aren't placed in the editor or by script so I doubt he means that.

Share this post


Link to post
Share on other sites
I think he's referring to player created Markers during the Mission. I think CreateMarker on it's own is still not JIP Compatible.

No, when I say markers created by script, I mean markers created by script. :P

Just tested it in Steam version (dev build, but should be in the default one as well) and it works.

Share this post


Link to post
Share on other sites
No, when I say markers created by script, I mean markers created by script. :P

Just tested it in Steam version (dev build, but should be in the default one as well) and it works.

Well, you've swooped in and saved the day, there! I, too, thought that that fix was just in regards to player-created markers via double-clicking the map in-game; didn't realise it applied to script-created ones too! Fantastic!

To confirm once more for my giddy head (and because I'm at work at the moment so can't test), I can just call createMarker on the server and the marker will be created for all clients and be there for JIP clients? And then if I delete said marker with deleteMarker, it'll disappear for good? Out of interest, does this also apply to tasks? I was creating tasks via BIS functions just yesterday and noticed that JIP players were receiving them; is everything nice and synced with JIP clients now?

In advance of your final response, please know that, if yes, I shall be doing this in my office --> :yay:

Also, you should really publicise this more! As I said in the original post, it's something I've been annoyed about for a long time; to see it fixed now is fantastic!

Edited by Fuzzy Bandit

Share this post


Link to post
Share on other sites
No, when I say markers created by script, I mean markers created by script. :P

Just tested it in Steam version (dev build, but should be in the default one as well) and it works.

Oh, ok. Sounds too good to be true :D

Share this post


Link to post
Share on other sites
I can just call createMarker on the server and the marker will be created for all clients and be there for JIP clients? And then if I delete said marker with deleteMarker, it'll disappear for good?

Yes

Could you please verify it, you guys made me doubt what I said :D

Share this post


Link to post
Share on other sites
Yes

Could you please verify it, you guys made me doubt what I said :D

I will verify tonight. I have an exact case where this was an issue for me.

Serverside using createMarker built a marker at x point. All players in the server at the time could see it. JIP after that point could not see it.

Share this post


Link to post
Share on other sites
Serverside using createMarker built a marker at x point. All players in the server at the time could see it. JIP after that point could not see it.

Exactly my problem whenever I've tried in the past.

But, as you will be, I'll try and verify tonight.

Share this post


Link to post
Share on other sites

It doesn't work! I have had to use functions to make JIP players see the script created markers.

This also applies to markers already on the map but changed position.

Share this post


Link to post
Share on other sites

To confirm, I've tested this and it works absolutely fine. Created and deleted multiple markers, another player joined a-fresh and could see the correct markers. Bloomin' good job, lads!

Share this post


Link to post
Share on other sites
To confirm, I've tested this and it works absolutely fine. Created and deleted multiple markers, another player joined a-fresh and could see the correct markers. Bloomin' good job, lads!

Take it you're on the latest dev build?

Share this post


Link to post
Share on other sites

Did you move them aswell? or change their Color? this is getting more and more confusing.

Share this post


Link to post
Share on other sites
Did you move them aswell? or change their Color? this is getting more and more confusing.

Will test changing colour tonight as I'll need to be doing that anyway. ^_^

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×