#how to cooldown

1 messages · Page 1 of 1 (latest)

deft fractal
#

Check shanebee's github

#

It's got a simple item cooldown

shut nymph
#

whats the link

deft fractal
shut nymph
#

how can i see the cooldown skript ?

#

where

deft fractal
#

Check around...

#

Search up simple item cooldown

#

On the github

shut nymph
#

where can i search

deft fractal
shut nymph
#

there is no simple item cooldown

deft fractal
#

...

deft fractal
#

It gives you an example of how to use it

shut nymph
#

waht should i do to fix ?

deft fractal
#

Check what the itemtype for a nether star is

shut nymph
#

its nether_star

deft fractal
#

The skript itemtype

#

Do you have effect commands enabled

shut nymph
deft fractal
#

nvm

#

Just put this in

#

Nevermind, just instead of putting holding nether star put on right click: 1 of player's tool = 1 of nether star named "" with lore ""

shut nymph
#

or how should i put it in

#

@deft fractal

#

waht do i need to do

deft fractal
#

As I told you. Don't ping me pointlessly.

#

And it's telling you that because you didn't indent properly.

shut nymph
#

ok sorry but waht do i need to do

deft fractal
#

I gave you something that didn't need indentation

shut nymph
#

so waht do i need to do ?

#

?

deft fractal
#

indent properly...

shut nymph
#

waht do i need to do

deft fractal
#

It needs to be under an if section

#

you can add an if statement instead of what I sent

shut nymph
#

i dont understand

deft fractal
#
  if 1 of player's tool = 1 of nether star named "" with lore "":```
shut nymph
#

waht should i do with the if

#

also

#

can u help me how to i do taht it only shoots the tnt when i right click the nehter star

#

rrl6 ?

deft fractal
#

That's what you coded it to do

shut nymph
#

no if i right click a sand block its shoot a tnt to

#

how to fix it

deft fractal
#

Send your current code

#

```vb
code```

deft fractal
shut nymph
#

waht is vb code

deft fractal
#

It's a code block

#

send your code like this

#

```vb
code```

shut nymph
# deft fractal \```vb code```
   permission: op
   trigger:
      give player 1 nether star named "&f&lShuricken" with lore "&7right click on a Player to deal 4 hearts of damage"
on right click:
  shoot an tnt

on right click:
  1 of player's tool = 1 of nether star named "&f&lShuricken"
  if {cooldowns::%uuid of player%::nether star } > now:
  cancel event
  set {_diff} to difference between {cooldowns::%uuid of player%::hoe} and now
  send "You have to wait %{_diff}% to use this tool"
  else:
  set {cooldowns::%uuid of player%::hoe} to 10 seconds from now

on quit:
    delete {cooldowns::%uuid of player%::*}```
deft fractal
#

aight

#

let's see

#

you have to indent after the else, and you didn't make it an if statement like I said

shut nymph
#

i dont understand

#

waht statement

deft fractal
#

If statement

#

if _:

shut nymph
#

where do i need to put it

deft fractal
#

...

shut nymph
#

so ?

#

rrl6 ?

deft fractal
#

Bro

cedar tuskBOT
#

In skript, you need to maintain consistent indentation, meaning you cannot indent 1 line 5 spaces, and the next 7 spaces. Usually it’s recommended you use tabs, however.

A good rule of thumb is to always indent the subsequent line whenever the previous statement ends with a :, an exception to this is in command statements with items before the trigger such as permission: or aliases:

With conditional statements and loops, any code that is indented within the statement will be run as a part of the statement, other code will not be run within the statement. Here is an example of proper indentation:

https://i.imgur.com/PbfZ12M.png