Jump to content


Recommended Posts

on script load:
	set {prices::iron ingot} to 10
	set {prices::gold ingot} to 15
	# etc

on right click: # all the information you gave, edit to your liking to fit your actual needs
	loop {prices::*}:
		set {_item} to loop-index parsed as item
		set {_amount} to amount of {_item} in player's inventory
		set {_reward} to {_amount} * loop-value
		send formatted "You sold %{_amount}%x %{_item}% for %{_reward}%" to player
		add {_reward} to player's balance
		remove {_amount} of {_item} from player
		delete {_item}, {_amount} and {_reward}

something like this should work, untested

Edited by AnonymousUser
removed html styling
Link to comment
Share on other sites

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