• Hey! Register here to create your account, engage with the community, and talk about what is new!

Is there a way to give an item to a player only once (like a beginner item that you can only get the first time you join)

ddess

New member
Joined
Aug 17, 2022
Messages
8
Reaction score
0
I'm trying to make an item that you only get the first time you join. Is there a way?
 
Solution
idk maybe like a varible thing or something
Yeah, it's a variable thing
To do it; first, create a variable with the name of something like %uuid firstjoin, %uuid will automatically be replaced with the player's uuid and we use uuid instead of name so it works even if the player changes their name. and shift-right click with the variable to set it to Saved (so it saves even when the player leaves). Now on player join event, place an If Variable =, in the 1st slot put the variable and in the 2nd slot put a number 0, between the pistons put the code for the first join and a Set Variable = to set the variable to 1 so the If Variable won't run when the player joins again. You can place an Else after the If Variable...

ARMcPro

Forum adept
Overlord
Joined
Oct 20, 2020
Messages
1,256
Reaction score
353
idk maybe like a varible thing or something
Yeah, it's a variable thing
To do it; first, create a variable with the name of something like %uuid firstjoin, %uuid will automatically be replaced with the player's uuid and we use uuid instead of name so it works even if the player changes their name. and shift-right click with the variable to set it to Saved (so it saves even when the player leaves). Now on player join event, place an If Variable =, in the 1st slot put the variable and in the 2nd slot put a number 0, between the pistons put the code for the first join and a Set Variable = to set the variable to 1 so the If Variable won't run when the player joins again. You can place an Else after the If Variable if you want a code that runs if it isn't their first time.
 
Solution

leonardo101b

New member
Joined
Jan 4, 2024
Messages
6
Reaction score
1
Yeah, it's a variable thing
To do it; first, create a variable with the name of something like %uuid firstjoin, %uuid will automatically be replaced with the player's uuid and we use uuid instead of name so it works even if the player changes their name. and shift-right click with the variable to set it to Saved (so it saves even when the player leaves). Now on player join event, place an If Variable =, in the 1st slot put the variable and in the 2nd slot put a number 0, between the pistons put the code for the first join and a Set Variable = to set the variable to 1 so the If Variable won't run when the player joins again. You can place an Else after the If Variable if you want a code that runs if it isn't their first time.
tysm!! it helped me too!
 
Top Bottom