Jump to content
AnonOp

Position on MAP

Recommended Posts

You can do this by when a player sends a message to those factions that it will create a marker on the map by checking player location and getting their name placing that into a variable and calling that variable as a string inside marker message so it displays it on the map with their name and then i guess doing it really simple but adding a sleep for 3 minutes or something and then delete the marker. Theres heaps of things you could do with this, just be creative!

Share this post


Link to post
Share on other sites
On 6/10/2017 at 0:01 AM, Elite IV | XtG Community said:

You can do this by when a player sends a message to those factions that it will create a marker on the map by checking player location and getting their name placing that into a variable and calling that variable as a string inside marker message so it displays it on the map with their name and then i guess doing it really simple but adding a sleep for 3 minutes or something and then delete the marker. Theres heaps of things you could do with this, just be creative!

Yea but how do you add it in the 1st place?

Share this post


Link to post
Share on other sites

I'm doing this on a phone so this is annoying lol. Bare with me here.

The way I would do it is create a script in the mission file like "fn_phoneRequestMarker.sqf" and inside there add

private [_positionVar,_marker];

_positionVar = position player;

_marker = createMarker ["phoneRequestMarker", _positionVar];

"phoneRequestMarker" setMarkerColor "ColorRed";

"phoneRequestMarker" setMarkerText "Warning! Recent emergency phone call from or near this location!";

"phoneRequestMarker" setMarkerType "mil_warning";

sleep (2 * 60);

deleteMarker "phoneRequestMarker";

 

 
   
   
   
   
   
   
   
   
 

At the moment with the current code it will show the marker to everyone. I don't remember how to only make the marker visible for that specific side, you will also have to create both seperate files for police and medic because it doesn't check whether what faction it needs to show it too in 1 file, until I get back onto my PC I'll help you finish this :) anyways, then define the path and tag through functions.hpp after that you will have to call the script once a player sends a text with the phone. You can do this in the life_server side and the file functions.sqf. Look for "TON_fnc_cell_emsrequest" and in that method you will see "call [] life_fnc_cellPhone;" below it add "[] call life_fnc_phoneRequestMarker;" without the quotation marks.

that should work if you do it correctly. :) 

Edited by Elite IV | XtG Community

Share this post


Link to post
Share on other sites
On 6/12/2017 at 12:38 PM, Elite IV | XtG Community said:

I'm doing this on a phone so this is annoying lol. Bare with me here.

The way I would do it is create a script in the mission file like "fn_phoneRequestMarker.sqf" and inside there add

private [_positionVar,_marker];

_positionVar = position player;

_marker = createMarker ["phoneRequestMarker", _positionVar];

"phoneRequestMarker" setMarkerColor "ColorRed";

"phoneRequestMarker" setMarkerText "Warning! Recent emergency phone call from or near this location!";

"phoneRequestMarker" setMarkerType "mil_warning";

sleep (2 * 60);

deleteMarker "phoneRequestMarker";

 

 
   
   
   
   
   
   
   
   
 

At the moment with the current code it will show the marker to everyone. I don't remember how to only make the marker visible for that specific side, you will also have to create both seperate files for police and medic because it doesn't check whether what faction it needs to show it too in 1 file, until I get back onto my PC I'll help you finish this :) anyways, then define the path and tag through functions.hpp after that you will have to call the script once a player sends a text with the phone. You can do this in the life_server side and the file functions.sqf. Look for "TON_fnc_cell_emsrequest" and in that method you will see "call [] life_fnc_cellPhone;" below it add "[] call life_fnc_phoneRequestMarker;" without the quotation marks.

that should work if you do it correctly. :) 

I want to do this but i want this marker show only that player Could you help me ? sorry for my bad english

Share this post


Link to post
Share on other sites
On 7/3/2019 at 8:46 AM, Rococo said:

I want to do this but i want this marker show only that player Could you help me ? sorry for my bad english

That doesn't make any sense.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.