Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 06/12/18 in Posts

  1. /save [name (optional)] command to save your/your vehicle's position and heading/rotation to a file just like in SA-MP. You can find the saved positions inside savedpos.txt on the server folder. Code: const fs = require("fs"); const saveFile = "savedpos.txt"; mp.events.addCommand("save", (player, name = "No name") => { let pos = (player.vehicle) ? player.vehicle.position : player.position; let rot = (player.vehicle) ? player.vehicle.rotation : player.heading; fs.appendFile(saveFile, `Position: ${pos.x}, ${pos.y}, ${pos.z} | ${(player.vehicle) ? `Rotation: ${rot.x}, ${rot.y}, ${rot.z}` : `Heading: ${rot}`} | ${(player.vehicle) ? "InCar" : "OnFoot"} - ${name}\r\n`, (err) => { if (err) { player.notify(`~r~SavePos Error: ~w~${err.message}`); } else { player.notify(`~g~Position saved. ~w~(${name})`); } }); }); What the output looks like: Position: -422.9187316894531, 1133.0765380859375, 325.8547058105469 | Heading: 344.207763671875 | OnFoot - No name Position: -411.07977294921875, 1180.73681640625, 325.0368957519531 | Rotation: 1.4606590270996094, 0.7490195631980896, 75.47509765625 | InCar - No name Position: -1087.9407958984375, 4912.0634765625, 214.6710968017578 | Heading: 222.96522521972656 | OnFoot - Altruist Camp
    1 point
  2. Hey guys, Our community has been in development for a while now, and we've shown some images on our forums, but I wanted to show some here as well. Some of the screenshots may be outdated, as I'm showing everything. Let's see how long I can keep this thread going to show how far we have come, and how far we will go. Every feature is a work in progress, enjoy. New videos that were released:
    1 point
  3. In known games such as Minecraft or SA:MP hitting arrow up key when having chat open brings up last sent message. Rage is lacking this feature.
    1 point
  4. I'll make a compatible version for Menyoo.
    1 point
  5. New update! Changelog: - Bug fixes, - Added german translation. Also rewrited language system, now you can easy add new language. - Added global chat /g (temporary) - Added Gas Stations Update DB structure! ------------------------------------------------ Some players have interesting humor
    1 point
  6. most stupid answer, next. u need to learn language, not a nodejs module.
    1 point
×
×
  • Create New...