Jump to content
RAGE Multiplayer Community

Hep! How create gang zone


Recommended Posts

Have a good evening everyone. Please tell me why when my create a glare when you zoom in on a map, the glare starts to float. I create a flare on the server side. An example of my highlight:

let blip = mp.blips.new(9, new mp.Vector3(x,y,z),
            {
                radius: 180,
                dimension: 1,
                color: 35,
                alpha: 175,
                rotation: 0
            });

Maybe some additional argument is missing?

P.S. 0.3.7

 

spacer.png

Link to post
Share on other sites
let natives = {}

mp.game.graphics.clearDrawOrigin = () => mp.game.invoke('0xFF0B610F6BE0D7AF'); // 26.07.2018 // GTA 1.44 

natives.SET_BLIP_SPRITE = (blip, sprite) => mp.game.invoke("0xDF735600A4696DAF", blip, sprite); // SET_BLIP_SPRITE
natives.SET_BLIP_ALPHA = (blip, a) => mp.game.invoke("0x45FF974EEE1C8734", blip, a); // SET_BLIP_ALPHA
natives.SET_BLIP_COLOUR = (blip, c) => mp.game.invoke("0x03D7FB09E75D6B7E", blip, c); // SET_BLIP_COLOUR
natives.SET_BLIP_ROTATION = (blip, r) => mp.game.invoke("0xF87683CDF73C3F6E", blip, r); // SET_BLIP_ROTATION
natives.SET_BLIP_FLASHES = (blip, f) => mp.game.invoke("0xB14552383D39CE3E", blip, f); // SET_BLIP_FLASHES
natives.SET_BLIP_FLASH_TIMER = (blip, t) => mp.game.invoke("0xD3CD6FD297AE87CC", blip, t); // SET_BLIP_FLASH_TIMER
natives.SET_BLIP_COORDS = (blip, x, y, z) => mp.game.invoke("0xAE2AF67E9D9AF65D", blip, x, y, z); // SET_BLIP_COORDS
natives.SET_THIS_SCRIPT_CAN_REMOVE_BLIPS_CREATED_BY_ANY_SCRIPT = (toggle) => mp.game.invoke("0xB98236CAAECEF897", toggle); // SET_THIS_SCRIPT_CAN_REMOVE_BLIPS_CREATED_BY_ANY_SCRIPT
natives.GET_FIRST_BLIP_INFO_ID = (i) => mp.game.invoke("0x1BEDE233E6CD2A1F", i); // GET_FIRST_BLIP_INFO_ID
natives.GET_NEXT_BLIP_INFO_ID = (i) => mp.game.invoke("0x14F96AA50D6FBEA7", i); // GET_NEXT_BLIP_INFO_ID
natives.DOES_BLIP_EXIST = (blip) => mp.game.invoke("0xA6DB27D19ECBB7DA", blip); // DOES_BLIP_EXIST
natives.GET_NUMBER_OF_ACTIVE_BLIPS = () => mp.game.invoke("0x9A3FF3DE163034E8"); // GET_NUMBER_OF_ACTIVE_BLIPS
natives.SET_BLIP_SCALE = (blip,scale) => mp.game.invoke("0xD38744167B2FA257",blip,scale); // SET_BLIP_SCALE
natives.SET_ENTITY_NO_COLLISION_ENTITY = (entity1, entity2, collision) => mp.game.invoke("0xA53ED5520C07654A", entity1.handle, entity2.handle, collision); // SET_ENTITY_NO_COLLISION_ENTITY



function clearBlips() {
    natives.SET_THIS_SCRIPT_CAN_REMOVE_BLIPS_CREATED_BY_ANY_SCRIPT(true)
    let last_blip = natives.GET_FIRST_BLIP_INFO_ID(5)
    while (natives.DOES_BLIP_EXIST(last_blip)) {
        mp.game.ui.removeBlip(last_blip)
        last_blip = natives.GET_NEXT_BLIP_INFO_ID(5)
    }
    mp.game.wait(50)
}
let teamData = {
    "TEAM_BALLAS": {
        "BlipColor": 27,
        "zone": undefined,
        "Checkpoint": {
            "x": -140.23487854003906,
            "y": -1629.2459716796875,
            "z": 32.8006706237793
        }
    },

    "TEAM_GROVE": {
        "BlipColor": 25,
        "zone": undefined,
        "Checkpoint": {
            "x": 104.83192443847656,
            "y": -1939.8612060546875,
            "z": 20.803701400756836
        }
    }

}

clearBlips()                                                    
for (let team in teamData) {                                              
    pos = teamData[team].Checkpoint
    teamData[team].zone = mp.game.ui.addBlipForRadius(pos.x, pos.y, 0, 100);
    natives.SET_BLIP_SPRITE(teamData[team].zone, 5);
    natives.SET_BLIP_ALPHA(teamData[team].zone, 100);
    natives.SET_BLIP_ROTATION(teamData[team].zone, 90)
    natives.SET_BLIP_COLOUR(teamData[team].zone, teamData[team].BlipColor)
}

I had the same problem when creating a gang war.
so I found a code here on the forum, I cleaned it and I think it will help you

  • Like 1
Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...