Forum > Coding >

Request| Notification when a player of a group with a rank joins

Posts: 181

Threads: 22

Joined: Jul, 2021

Reputation: -20

Posted

Hi,

I need a script that would execute a script (Like a notification or just print or something of my choosing like kick) If a player who joins in my game is in a group with a speficiet rank Like ("Admin") Or ("Owner")

 

Anyone has a script for it? Thanks

 

If its possible to add a notification that would say the players name when they join it would be better but its not needed too mutch

 

I Simply need it because there is soo many admins/premium users on a script i execute and also for a game that has alot of admins so yh

  • 0

tar

CoolNickname

Posts: 119

Threads: 11

Joined: Jul, 2021

Reputation: 1

Replied

https://developer.roblox.com/en-us/api-reference/function/Player/GetRankInGroup

  • 0

https://imgur.com/a/oOomuUo

Posts: 181

Threads: 22

Joined: Jul, 2021

Reputation: -20

Replied

@tar Where Do you put the GROUP ID And This script is only for owner ? I need a script where it would kick you if a Player joins with a spifiect rank in the group for example the rank could be ("Member") or ("Admin"). I think this script isnt what i need. 

  • 0

Kura

kuraise

Posts: 135

Threads: 3

Joined: Jun, 2021

Reputation: 5

Replied

@GoldenCheats simple.

local player = game.Players.LocalPlayer;
local id = 1; -- set your group id here.
if player:GetRankInGroup(id) == 255 then
    print('owner');
else
    print('not owner');
end;

ofc this can be easily hooked so pls don't use these. You can change this to what you wish

  • 0

 

https://cdn.discordapp.com/attachments/877610317037858846/975469974405673041/Signature.png

Posts: 181

Threads: 22

Joined: Jul, 2021

Reputation: -20

Replied

So like if there is 3 speficiet group ranks

 

Premium

Owner

Admin

Manager

 

 

How do i make it so it does it for "Premium" Rank? Where do i get the code of the rank

  • 0

Posts: 1592

Threads: 166

Joined: Apr, 2021

Reputation: 13

Replied

@Kura why the semicolons in lua tho

  • 0

Random quote here...

Kura

kuraise

Posts: 135

Threads: 3

Joined: Jun, 2021

Reputation: 5

Replied

@VoidableMethod idk im used to it

  • 0

 

https://cdn.discordapp.com/attachments/877610317037858846/975469974405673041/Signature.png

tar

CoolNickname

Posts: 119

Threads: 11

Joined: Jul, 2021

Reputation: 1

Replied

@GoldenCheats (sorry for late reply)

https://developer.roblox.com/en-us/api-reference/function/Player/GetRoleInGroup

  • 0

https://imgur.com/a/oOomuUo

Users viewing this thread:

( Members: 0, Guests: 1, Total: 1 )