1

Scoreboard shop help

sannic19's Avatar sannic196/7/13 12:32 pm
1 emeralds 411 6
6/12/2013 7:11 pm
Statistical's Avatar Statistical
hey guys im making an arena map and there will be a shop included in it in which the currency is kill points, but the only problem it the command /scoreboard players remove @p[score_kills_min=10] Kills 10. The command in the command block works but once it activates the comparator to give the player the item the comparator wont deactivate so the item can only be bought once, is there anything i can do to make the item be able to be bought more then once thanks
Posted by sannic19's Avatar
sannic19
Level 7 : Apprentice Explorer
3

Create an account or sign in to comment.

6

Statistical
06/12/2013 7:11 pm
Level 38 : Artisan Electrician
Statistical's Avatar
Use this:

Just make sure the redstone activating the command block also turns off the torch.
1
MadOliveGaming
06/12/2013 7:35 am
Level 31 : Artisan Engineer
MadOliveGaming's Avatar
Em simply don't use comparators. Make a commandblock that does /give [item] [amount] @p[score_kills_min=10,r=*put a range here*]. Than one that does /scoreboard players remove @p[score_kills_min=10,r=*put range here*] Kills 10.

You REALLY need to entre in a max range cuz otherwise if a player with 9 kills pushed it and someone else does has 10 kills, that other person is the nearest player with 10 kills and buys something he might not want!
1
Kahanamoku
06/07/2013 8:03 pm
Level 1 : New Miner
Kahanamoku's Avatar
Here are the screenshots. Note that while it is for an XP Person to Person transfer, the concept is still the same (albeit your one will be slightly simpler)







1
Kahanamoku
06/07/2013 7:53 pm
Level 1 : New Miner
Kahanamoku's Avatar
Here's how I did it on SPCraft.

Button Signal goes to Both the following:
CMD Block [Set Dummy Objective "ShopTransaction" to 0 - to clear existing states]
Repeater with 3 tick delay to ensure above command block completes its action.

Repeater Signal then goes to the following:
A command block to check testfor on the "ShopTransaction" to ensure it is 0 [No Transactions In Progress]

The command block is connected to a comparitor/repeater chain

The output from this comparitor/repeater chain will then run to 2 command blocks
One to set the "ShopTransaction" to 1 [In Progress]
One to deduct the scoreboard balance from the user (with your @p conditional mentioned above)

The output from the comparitor/repeater chain should also loop back (with a delay of say, 6 ticks) to the Comparitor itself as a B-Signal to reset the state, as well as to the command block that tests the "ShopTransaction" state (with a delay of 3 ticks)

This will force a re-test of the transactional state causing the output of the command block to be false, and thus not resending the signal through again. The loop back to the comparitor on the B-Signal will reset it's state to off, ready for the next use.


the output should also be looped back to both the comparitor (with a few ticks delay) to initiate disabling of it as well as a loop back to the original testfor command block to retest the balance
1
_xeodite_
06/07/2013 12:52 pm
Level 22 : Expert Spelunker
_xeodite_'s Avatar
Hook the switch/lever up to a timer that will check for that amount of kills each time they click it. The lever/switch will have to be deactivated after using the shop or the player will constantly get those items after they reach that certain amount of kills
1
sannic19
06/07/2013 1:02 pm
Level 7 : Apprentice Explorer
sannic19's Avatar
could i have a clock and a player presses a button which deactivates a piston in a inverteer so the command block will only check when the button is pushed
1
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome