Jump to content

/sell Skript for gen servers


skAyo

Recommended Posts

Here's a simple gen sell skript for all of you nerds creating gen servers.

command /sell:
    trigger:
	
        sell(player, coal, 1)
        sell(player, iron, 5)
		
        add {-temp::%player%} to player's balance
        send title "&a&lSOLD" with subtitle "&fYou sold all items for &2&l$%{-temp::%player%}%"
        play sound "block.note_block.pling" with volume 2 to player
        delete {-temp::%player%}

function sell(P: player, I: itemtype, N: int):
    set {_am} to amount of {_I} in {_P}'s inventory
    set {_am} to ({_am} * {_N})
    remove all {_I} from {_P}'s inventory
    add {_am} to {-temp::%{_P}%}
	  
	  
	  
  • Like 1
Link to comment
Share on other sites

22 hours ago, skAyo said:

Here's a simple gen sell skript for all of you nerds creating gen servers.

command /sell:
    trigger:
	
        sell(player, coal, 1)
        sell(player, iron, 5)
		
        add {-temp::%player%} to player's balance
        send title "&a&lSOLD" with subtitle "&fYou sold all items for &2&l$%{-temp::%player%}%"
        play sound "block.note_block.pling" with volume 2 to player
        delete {-temp::%player%}

function sell(P: player, I: itemtype, N: int):
    set {_am} to amount of {_I} in {_P}'s inventory
    set {_am} to ({_am} * {_N})
    remove all {_I} from {_P}'s inventory
    add {_am} to {-temp::%{_P}%}
	  
	  
	  

nice

 

 

image.png.bc433d6489d70ad831075fe76809b993.png
 

Lifestealed | Minecraft Servers
 

OG [VIP] 12/26/20 - 10/27/2021
OG [PRO] 12/27/21 - 11/18/2022
OG [LEGEND] 11/18/2022 - 3/14/2023
[DEFAULT] 3/14/2023 - Present

 

Link to comment
Share on other sites

  • 1 month later...

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
×
×
  • Create New...