Jump to content

Recommended Posts

Posted

Someone check if this works I have no one to test right now friend is far away

Server side :
mp.events.add('playerJoin', (player) => {
player.call('setRelationshipGroup');
});
--------------------------------------------------
Client side :
mp.events.add('setRelationshipGroup', () => {
const player = mp.players.local;
const relationshipGroup = mp.game.joaat("PLAYER");
player.setRelationshipGroupHash(relationshipGroup);
mp.game.ped.setRelationshipBetweenGroups(5, relationshipGroup, relationshipGroup);
});

Posted

Actually I tested my code and it works 100% 

Server side :
mp.events.add('playerJoin', (player) => {
player.call('setRelationshipGroup');
});
--------------------------------------------------
Client side :
mp.events.add('setRelationshipGroup', () => {
const player = mp.players.local;
const relationshipGroup = mp.game.joaat("PLAYER");
player.setRelationshipGroupHash(relationshipGroup);
mp.game.ped.setRelationshipBetweenGroups(5, relationshipGroup, relationshipGroup);
});

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...