1

Scoreboard help please?

T-R-S's Avatar T-R-S9/12/17 11:29 pm
1 emeralds 230 6
9/13/2017 2:13 pm
Pepijn's Avatar Pepijn
so im trying to make a coins scoreboard, and i made it with an offline player that i dont know. (player=coins)
so i do a testfor @p[score_Coins_min=100] it doesnt work because i need to make it player specific. does any1 know how to do this?
Posted by T-R-S's Avatar
T-R-S
Level 1 : New Miner
0

Create an account or sign in to comment.

6

1
09/13/2017 2:13 pm
Level 57 : Grandmaster Cyborg
Pepijn
Pepijn's Avatar
You are using what is called a "fake player" if I'm correct. Which basically means you're assigning a score to a non-existent player. This is totally fine but it comes with some limitations.

The main limitation is that you CAN'T test for fake-player scores using normal target selectors (like @a[score_Coins_min=1].

If you did:
scoreboard players set EXAMPLE Coins 1
You can test for the score from the fake-player Example using this:
scoreboard players test EXAMPLE coins 1 1
1
09/13/2017 6:06 am
Level 34 : Artisan Nerd
PyroCreative
PyroCreative's Avatar
Ok, so basically you want to give or do something while you are testing for a command..
So, lets us visualise the basics.

Here is your coin scoreboard

/scoreboard objectives add Coins
/scoreboard objectives setdisplay Coins sidebar

Now that you have made your scoreboard,
Let us add a few points to the scoreboard.

/scoreboard players add Coins 1

If we do a repetitive command as above , you will end up using a lot of time.

The idea you have mentioned above wont work if u are making a shop.. as it is no longer supported in 1.12 plus.

So u will have to give the player a balance.

/scoreboard players add Coins 500

You could take any amount.. I'll take 500.
So now that the player has a balance..
He could fill it up again. [set a contraption for that]

Now you want to make the player teleport / buy / sell

So if you want him to teleport, make a button teleporting to the xyz coordinates.
and deduct coins from him.
/scoreboard players set Coins 450
[do the same with the shop if u make it]

OR

if you are testing for his score,
then ..

/testfor @p[score_Coins_min=1_max=100

or on a server,

/testfor @r[score_Coins_min=1_max=100]

Done!

For more help,
Subscribe to me and ya..
follow me :=]

Bye,
pyro
1
09/13/2017 5:20 am
Level 23 : Expert Crafter
Void_Strider_
Void_Strider_'s Avatar
Wait so like.. are you trying to give every player a score e.g. PlayerCoins = 0?
Then I assume you get coins some how then you want to test to see if they have the required amount (100) before doing something? (e.g. /give /teleport etc.)?



If you are trying @p you will need to test the closet player you need to run the command through a command block. (Not just type it in or use the server console). On yourself (the one executing the command) use @s. Hope this helps, I'll try to be more useful when I get a better idea of what you doing :)
-Void
1
09/13/2017 2:15 am
Level 1 : New Miner
T-R-S
T-R-S's Avatar
i did the player for the color and i used the basic scoreboard commands
1
09/13/2017 6:07 am
Level 34 : Artisan Nerd
PyroCreative
PyroCreative's Avatar
add the player to a team

and give option for color
1
09/12/2017 11:46 pm
Level 22 : Expert Mage
TheGalaxyCat
TheGalaxyCat's Avatar
Well I need more details. Like why did you make a player for it what is it for and commands you used to set up your coin system.
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome