#I'm looking to make something like fairy souls from hypixel skyblock

1 messages · Page 1 of 1 (latest)

elder harbor
#

on rightclick: event-block is bone block add 1 to {fossil::%player's uuid%}

Here is what I have right now.
How would I make it so you can only click the same block once?

bronze wedge
#

add the block to a list

thick prism
#

^

elder harbor
thick prism
#

you can also use on right-click on bone block:

elder harbor
#

on load:
add .. to {fossils::*}

thick prism
#

yup

elder harbor
#

what do i put in the ..?

bronze wedge
#

don't do it on load?

thick prism
#

its location maybe

thick prism
#

then just check if that list contains the block

elder harbor
thick prism
bronze wedge
#

or if the block is unique you can just add it on rightclick

thick prism
#

location of ...

elder harbor
elder harbor
bronze wedge
#

if a specific block is only ever used as a collectible, how would that make it hard to tell what's collectible?

#

like if bone blocks are only ever used as collectibles

#

not as building blocks

elder harbor
bronze wedge
#

oh okay

elder harbor
#

on rightclick: event-block is bone block add location of to {fossils::*} add 1 to {fossil::%player's uuid%} broadcast {fossils::*}

#

what do I put inside locatiom

#

i put event-block

#

on rightclick: event-block is bone block add location of event-block to {fossils::*} add 1 to {fossil::%player's uuid%} broadcast {fossils::*} broadcast {fossil::%player's uuid%}

thick prism
#

is {fossils::*} a list of

  • all possible bone blocks to find
    or
  • all bone blocks found by that player
elder harbor
#

this appears to be working but how do I make the player unable to right click the same block twice

thick prism
#

so then it shouldnt be on right-vlivk:

lucid bramble
#

Check if event-block isnt in fossils list

thick prism
lucid bramble
#

Oh

#

Ok

thick prism
#

so create another list for ones the player has found

elder harbor
#

okay

lucid bramble
#

Yes

#

Thats good

elder harbor
#

on right-click on bone block: add location of event-block to {fossils::*} add location of event-block to {foundfossils::*} add 1 to {fossil::%player's uuid%} broadcast {fossils::*} broadcast {fossil::%player's uuid%}

lucid bramble
#

well problem is

#

Foundfossils will apply to everyone

#

Also ur not checking if player found the fossil already

thick prism
#

okay

  1. code blocks are 3 backticks, not 1. ```code here```
  2. You don't want to add to {fossils::*} there.
  3. the {foundfossils::*} list is not player specific
elder harbor
#

okay

thick prism
#

you'd want another index; {foundFossils::%player's UUID%::*}

elder harbor
#
    {fossils::*} contains location of event-block
    add location of event-block to {foundfossils::%player's uuid%::*}
    add 1 to {fossil::%player's uuid%}
    broadcast {fossils::*}
    broadcast {fossil::%player's uuid%}```
thick prism
#

you need the ::* on line 3, that makes it a list

elder harbor
#

like that?

thick prism
#

closer

#

but you're still adding to {fossils::*}, which means every block that is clicked will become a fossil
(and blocks that are already fossils will be added to the list again)

elder harbor
#

how would I stop that?

thick prism
#

you should just be checking if {fossils::*} contains location of event-block

elder harbor
#

alr

#
    if {fossils::*} contains location of event-block
    add location of event-block to {foundfossils::%player's uuid%::*}
    add 1 to {fossil::%player's uuid%}
    broadcast {fossils::*}
    broadcast {fossil::%player's uuid%}```
#

how would I then add the locations to the list {fossils::*}

thick prism
#

line 2 needs a colon at the end and you have to indent after it

#

or you can delete the if at the front

thick prism
elder harbor
#
    if {fossils::*} contains location of event-block:
        add location of event-block to {foundfossils::%player's uuid%::*}
        add 1 to {fossil::%player's uuid%}
        broadcast {fossils::*}
        broadcast {fossil::%player's uuid%}```
#

So this is basically all the functionality done

thick prism
#

deleting the if at the front was an alternative to adding a colon and indenting

#

you want one or the other, not both