Skript

Skript

743k Downloads

anvil text input not working if anvil is open from Skript

Saanjuk opened this issue · 2 comments

commented

[00:54:21 INFO]: [Skript] Skript's aliases can be found here: https://github.com/SkriptLang/skript-aliases
[00:54:21 INFO]: [Skript] Skript's documentation can be found here: https://docs.skriptlang.org/
[00:54:21 INFO]: [Skript] Skript's tutorials can be found here: https://docs.skriptlang.org/tutorials
[00:54:21 INFO]: [Skript] Server Version: git-Purpur-2152 (MC: 1.20.4)
[00:54:21 INFO]: [Skript] Skript Version: 2.9.1 (skriptlang-github)
[00:54:21 INFO]: [Skript] Installed Skript Addons:
[00:54:21 INFO]: [Skript] - skript-placeholders v1.6.0 (https://github.com/APickledWalrus/skript-placeholders)
[00:54:21 INFO]: [Skript] Installed dependencies:
[00:54:21 INFO]: [Skript] - Vault v1.7.3-b131
[00:54:21 INFO]: [Skript] - WorldGuard v7.0.9+5934e49

GUI from skript:

command /tszukaj [<text>] :
    trigger:
        set {_x} to anvil inventory 
        set slot 0 of {_x} to iron helmet named " " with lore "Kliknij aby zresetować"
        set slot 1 of {_x} to iron helmet named "&aFiltr szukania: &6&lWszystko" with lore "&aKliknij, Aby zmienić"
        set slot 2 of {_x} to iron helmet with lore "Kliknij aby wyszukać"
        open {_x} to player

Events:

on inventory click:
    type of event-inventory is anvil inventory
    cancel event`
    set {_input} to anvil text input of the event-inventory
    send "%{_input}%"

sending <none>

on inventory click:
     type of event-inventory is anvil inventory
    cancel event`
    send the anvil text input of the event-inventory to player

does nothing

on anvil prepare:
    set {_xd} to anvil text input of the event-inventory
    send "%{_xd}%" to all players

all work fine if anvil is real anvil or /anvil from essentials but don't work on anvil inventory created by skript

commented

If I use Skript-AnvilGUI addon parse anvil text input from GUI generate by Addon work...
Can we really not do the same thing as in this add-on in pure script?

commented

This seems to be a server issue and not a skript issue. When recreating using skript-reflect, the server isn't thinking it's an anvil inventory. No matching non-static method: CraftInventoryCustom#getRenameText

Edit: After some more discussion, this is indeed a Skript issue.