Giving Premium purchasers Adonis admin commands

Hello! I want to, make a system like If you buy Roblox premium, you get Adonis admin commands Ingame… The Issue Is, that I don’t know how to do It.
I have tried, making It like I make a normal game pass like you get VIP Door access Ingame, If you buy VIP from the game store.

2 Likes

This may be of use:

Player.MembershipType checks what type of membership the player has.

local Players = game:GetService("Players")
local player = Players.LocalPlayer
 
if player.MembershipType == Enum.MembershipType.Premium then
	-- Take some action specifically for Premium members
 
end

Hope this helps, Sylvern.

2 Likes

Thanks, Mr.Sylvem! can you, also teach me, how to grant the members of premium features… But the thing Is, I want people that buy premium, from my game gets the feature, not other people with premium.

18 posts were split to a new topic: Giving Premium purchasers (Private Discussion)

Datastores are definitely not required. If I understood correctly, you need to give the player the benefits after he purchases Premium from the prompt in-Game and reward the benefits if they are already Premium.

I will briefly tell you the process you need to follow :

That should be all you need however if you need help just reply back :slight_smile:

1 Like

Hey there! I haven’t tested this code but it might work. Sorry for weird formatting aswell.

-- this code copy pasted from Dev_Sylvern
local Players = game:GetService("Players")
local player = Players.LocalPlayer
 
if player.MembershipType == Enum.MembershipType.Premium then
        local data = {
        	Settings = {
			Admins = {player.Name}
	        };
        }
	require(359948692)(data) -- adonis API module 
end 
1 Like

Where to put, the script ???..

I guess anywhere you want to put the script, server script service, workspace, in another script

1 Like

One more question, can I change admin level? to mod.

Also It Is local script or just script?

it is a server script
(30 charsssssssssss)

Server script, and yeah just change the “Admins” to “Mods”

-- this code copy pasted from Dev_Sylvern
local Players = game:GetService("Players")
local player = Players.LocalPlayer
 
if player.MembershipType == Enum.MembershipType.Premium then
        local data = {
        	Settings = {
			Moderators = {player.Name}
	        };
        }
	require(359948692)(data) -- adonis API module 
end 

Thanks and, I mean the type local script or script…

That’s what I said, server script = normal script

1 Like

Ok, tysm I will try It out, you legit helped me so much!!

So If a player, buys premium from my game gets mod?

Anyone who owns roblox premium will get mod.

Uhhh… I don’t wanted It like that, I want It to be like If a player buys premium, In my game gets mod…

Not entirely sure if you’re able to check if the player buys it from your game, but there is gamepasses you can use.

I got Idea, I can make sword, only premium can buy?.. like prompt It for only, Roblox premium players? And the sword, will give people mod.