Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 03/16/19 in Posts

  1. I have seen the example posted by rootcause with a rescue command as it is on samp for java script and i said to do one for C #. You must use the System.IO library using System.IO; And this is the proper command.. [Command("save","Use /save [Position Name]", GreedyArg = true)] public void CMD_SavePosition(Client player, string PosName = "No Set") { var pos = (player.IsInVehicle) ? player.Vehicle.Position : player.Position; var rot = (player.IsInVehicle) ? player.Vehicle.Rotation : player.Rotation; using (var stream = File.AppendText("SavePos.txt")) { if (player.IsInVehicle) { NAPI.Notification.SendNotificationToPlayer(player, "~g~In car ~w~postion saved with name ~r~" + PosName, true); stream.WriteLine("IN VEH || " + PosName + ":" + pos.X + ", " + pos.Y + ", " + pos.Z + " Rot: " + rot.Z); stream.Close(); } else { NAPI.Notification.SendNotificationToPlayer(player, "~g~On foot ~w~position saved with name ~r~" + PosName, true); stream.WriteLine("ON FOOT|| " + PosName + ":" + pos.X + ", " + pos.Y + ", " + pos.Z + " Rot: " + rot.Z); stream.Close(); } } } The positions you find saved in the SavePos.txt file in the server folder That's how they look ON FOOT|| No Set: -439.8961, 6023.063, 31.49012 Rot: 2.175138 ON FOOT|| Police: -440.5302, 6034.081, 31.34053 Rot: 2.944162 IN VEH || Spawn Adder: -440.6177, 6035.974, 30.93323 Rot: 2.784058
    1 point
  2. Just use Codewalker28, it's full of features and it's open source.
    1 point
×
×
  • Create New...