#(nasrulswd) just want help

36 messages · Page 1 of 1 (latest)

haughty sand
meager domeBOT
#

(nasrulswd) just want help

meager domeBOT
#

Hi I'm AutoThreadBot! Don't mind me, I'll just be adding the helper team to this thread so they can see it. A human will get to you soon.

silver cypress
#

you have a few things you should review and then poke at in your script;
so very first,

after player join:
    - flag <player> thirst:20```

you're setting their thirst to 20; this is not true or false, as you're trying to check on line 7: if <player.flag[thirst]> = true:
a good reference on why you should also drop the = true for a tag that returns true or false (like <player.has_flag[]> or <server.has_flag[]>) is on the if guide page:

#

!guide if command

sudden dockBOT
silver cypress
#

following fixing the logic there, you'l want to read your debug

#

!guide debug

sudden dockBOT
# silver cypress !guide debug
Cannot Specify Searched GuidePage

Multiple possible guidepages: Common Mistakes - Watch Your Debug Console, Common Mistakes - Toggle Debug Settings With Care.

silver cypress
#

!guide watch debug console

sudden dockBOT
#
Possible Confusion

Did you mean to search for common mistakes - watch your debug console?

silver cypress
#

this will show you even <player> being invalid when checked in delta time events

#

there is no player

#

!event delta time

sudden dockBOT
# silver cypress !event delta time
Group

Core

Event Lines

delta time hourly|minutely|secondly

Switches

every:<count> to only run the event every *count* times (like "on delta time secondly every:5" for every 5 seconds).

Triggers

every <count> seconds, minutes, or hours of game calculation time. Default repetitions count of 1.
This is specifically based on the rate of time advancement in the game server,
which is not necessarily equivalent to the real passage of time (for example, this event may fire slower if the server is lagging).
For real time, see !event system time.

Context

<context.second> returns the exact delta time since system start.

silver cypress
#

if you note above, the meta shows event lines, switches, triggers, and context

#

!event player crafts

sudden dockBOT
# silver cypress !event player crafts
Group

Player

Event Lines

player crafts item player crafts <item>

Triggers

when a player fully crafts an item.

Has Player

Always. - this adds switches flagged:<flag name> + permission:<node>, in addition to the <player> link.

Context

<context.inventory> returns the InventoryTag of the crafting inventory.
<context.item> returns the ItemTag to be crafted.
<context.amount> returns the amount of the item that will be crafted (usually 1, except when shift clicked. Can be above 64).
<context.recipe> returns a ListTag of ItemTags in the recipe.
<context.recipe_id> returns the ID of the recipe that is being crafted.
<context.click_type> returns an ElementTag with the name of the click type. Click type list: <@lin...

Determine

ItemTag to change the item that is crafted.

Cancellable

True - this adds <context.cancelled> and determines cancelled + cancelled:false.

silver cypress
#

*Has Player *
Always
this is what you'll see otherwise

#

so you want to loop across players, not tell the script to use one that's not there

#

!tag servertag.online_players

sudden dockBOT
#
Possible Confusion

Did you mean to search for server.online_players?

sudden dockBOT
silver cypress
#

if you're still uncertain after making changes, share the new updated script and a debug and we can help digress more

#

!debug

sudden dockBOT
# silver cypress !debug
Info: debug

If you need help with a script issue, one of the most powerful tools Denizen has to offer is full debug output. This is displaying in your console whenever scripts are running until you turn debug off. To share a debug log quickly and easily with helpers, simply run the command /denizen debug -r in-game to begin recording, then run through the part of the script you need help with, then run the command /denizen submit. This will give you a link to a paste of the debug log, which you can then copy/paste back to us!

haughty sand
silver cypress
#

Error Message: Missing player for player tag.
this is what i meant about <player> not being a thing here; you'll need to target players in this event because the players don't cause this event to fire

#

in-fact, that script will run even without players online

#

following through the guide will help you learn how to write it more properly based on your usage, because there's a lot of different ways to do what you're doing

#

otherwise it's helpful if you explain where you're stuck

haughty sand
#

ouh thanks for your imformation