Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.7: Some functions not loaded on startup #5779

Closed
1 task done
L3v3lup opened this issue Jun 29, 2023 · 7 comments
Closed
1 task done

2.7: Some functions not loaded on startup #5779

L3v3lup opened this issue Jun 29, 2023 · 7 comments
Assignees
Labels
addon-related An issue that is related to an addon and not Skript.

Comments

@L3v3lup
Copy link

L3v3lup commented Jun 29, 2023

Skript/Server Version

[11:39:31 INFO]: [Skript] Server Version: git-Purpur-2004 (MC: 1.20.1)
[11:39:31 INFO]: [Skript] Skript Version: 2.7.0-beta3-nightly-97a6d14 (skriptlang-nightly)
[11:39:31 INFO]: [Skript] Installed Skript Addons:
[11:39:31 INFO]: [Skript]  - SkUniversal v2.13
[11:39:31 INFO]: [Skript]  - skript-yaml v1.4.1-for-MC-1.20
[11:39:31 INFO]: [Skript]  - skript-reflect v2.3 (https://github.com/TPGamesNL/skript-reflect)
[11:39:31 INFO]: [Skript]  - skript-db v1.3.6
[11:39:31 INFO]: [Skript]  - skRayFall v1.9.28 (https://sk.rayfall.net/)
[11:39:31 INFO]: [Skript]  - SkBee v2.13.0 (https://github.com/ShaneBeee/SkBee)
[11:39:31 INFO]: [Skript]  - ItemsAdder v3.5.0-r2 (devs.beer)
[11:39:31 INFO]: [Skript] Installed dependencies:
[11:39:31 INFO]: [Skript]  - WorldGuard v7.0.9-SNAPSHOT+2250-fffb0c1
[11:39:31 INFO]: [Skript]  - GriefPrevention v16.18.1

Bug Description

Some of my functions are not getting loaded when i startup the server. The same error occurs with /sk reload all.

More infos to this problem: The same functions that are not recognized later down the script are being used above, but dont throw an error. Can a (too) big skript file cause this? Anyways, this is new and didn't happen in 2.6.

Expected Behavior

Steps to Reproduce

Errors or Screenshots

[11:38:42 INFO]: loaded 6 structures from 'Dungeons\Skills.sk'
[11:38:42 INFO]: loaded 8 structures from '!API.sk'
[11:38:42 INFO]: Line 882: (Achievements.sk)
[11:38:42 INFO]:     The function 'Reward' does not exist.
[11:38:42 INFO]:     Line: Reward(expr-2, 1, 100, true, "&6Händler I&7", false)
[11:38:42 INFO]:
[11:38:42 INFO]: Line 883: (Achievements.sk)
[11:38:42 INFO]:     The function 'ItemPayout' does not exist.
[11:38:42 INFO]:     Line: ItemPayout(expr-2, 2 emerald)
[11:38:42 INFO]:
[11:38:42 INFO]: Line 888: (Achievements.sk)
[11:38:42 INFO]:     The function 'Reward' does not exist.
[11:38:42 INFO]:     Line: Reward(expr-2, 2, 500, true, "&6Händler II&7", false)
[11:38:42 INFO]:
[11:38:42 INFO]: Line 889: (Achievements.sk)
[11:38:42 INFO]:     The function 'ItemPayout' does not exist.
[11:38:42 INFO]:     Line: ItemPayout(expr-2, 8 emerald)
[11:38:42 INFO]:
[11:38:42 INFO]: Line 894: (Achievements.sk)
[11:38:42 INFO]:     The function 'Reward' does not exist.
[11:38:42 INFO]:     Line: Reward(expr-2, 5, 2000, true, "&6Händler III&7", true)
[11:38:42 INFO]:
[11:38:42 INFO]: Line 895: (Achievements.sk)
[11:38:42 INFO]:     The function 'ItemPayout' does not exist.
[11:38:42 INFO]:     Line: ItemPayout(expr-2, 1 netherite ingot)
[11:38:42 INFO]:
[11:38:42 INFO]: loaded 21 structures from 'Achievements.sk'
[11:38:42 INFO]: loaded 9 structures from 'Auktionshaus.sk'
[11:38:42 INFO]: loaded 18 structures from 'ChatTab.sk'
[11:38:42 INFO]: loaded 13 structures from 'Dashboard.sk'
[11:38:42 INFO]: loaded 15 structures from 'dyn.sk'
[11:38:42 INFO]: loaded 84 structures from 'Essentials.sk'
[11:38:42 INFO]: loaded 8 structures from 'Farmwelt.sk'
[11:38:42 INFO]: loaded 3 structures from 'Geldsystem.sk'
[11:38:42 INFO]: loaded 26 structures from 'Items.sk'
[11:38:42 INFO]: loaded 23 structures from 'Jobs.sk'
[11:38:42 INFO]: loaded 5 structures from 'Lift.sk'
[11:38:42 INFO]: loaded 4 structures from 'PlayerCitys.sk'
[11:38:42 INFO]: loaded 3 structures from 'Quarrys.sk'
[11:38:42 INFO]: loaded 21 structures from 'Sandbox.sk'
[11:38:42 INFO]: loaded 2 structures from 'Scoreboard.sk'
[11:38:42 INFO]: loaded 3 structures from 'Tacho.sk'
[11:38:42 INFO]: loaded 1 structure from 'Team.sk'
[11:38:42 INFO]: loaded 13 structures from 'Vote.sk'
[11:38:42 INFO]: loaded 2 structures from 'Yaml.sk'
[11:38:42 INFO]: loaded 5 structures from 'Zaubermarkt.sk'
[11:38:42 INFO]: loaded 14 structures from 'Zirkus.sk'
[11:38:43 INFO]: Line 190: (ChatTab.sk)
[11:38:43 INFO]:     the display name of loop-player is already a text, so you should not put it in one (e.g. the display name of loop-player instead of "%the display name of loop-player%")
[11:38:43 INFO]:     Line: if {_m} contains "%displayname of loop-player%":
[11:38:43 INFO]:
[11:38:45 INFO]: [Skript] Encountered 6 errors while reloading the config, aliases and all scripts! (4434ms)

Other

No response

Agreement

  • I have read the guidelines above and affirm I am following them with this report.
@APickledWalrus
Copy link
Member

APickledWalrus commented Jun 29, 2023

im assuming Achievements.sk is using the missing functions. what script are they a part of? !API.sk? could you send the script containing the functions?

also, what other scripts make use of the functions but load correctly?

@APickledWalrus APickledWalrus added investigating The core developers are currently investigating this issue. Usually used for complex cases. waiting for reply The report needs a response from the reporter to determine course of action. labels Jun 29, 2023
@L3v3lup
Copy link
Author

L3v3lup commented Jun 29, 2023

!API.sk just has some WorldGuard things inside.

The function "Reward" is in the file Geldsystem.sk. "ItemPayout" is in Essentials.sk.

Function "Reward" is used in: Essentials.sk, Zirkus.sk and Achievement.sk.
Function "ItemPayout" is used in 6 different files and Achievement.sk - which all work besides Achievement.sk.
I tried renaming "Achievement.sk" to "ZAchievment.sk" for the sake of a broken loading order, but that didnt solve the problem either.

Oh and "Achievement.sk" successfully uses "Reward()" and "ItemPayout()" in Achievement.sk. The trouble starts just at line 882.

Geldsystem.sk: https://pastebin.com/t2N7GkDu
Essentials.sk: https://pastebin.com/XhYBTW40

@APickledWalrus
Copy link
Member

thanks for all the information! could you send the achievement.sk script as well?

@L3v3lup
Copy link
Author

L3v3lup commented Jun 29, 2023

Can i send you that privately?
I found your E-Mail adress on your profile. I will send you a pastebin link to the file.

@APickledWalrus
Copy link
Member

Based on the information in that script (it was emailed to me), it looks like the problematic calls are located in a custom effect created using skript-reflect. Looking at the source code, it seems like it may end up loading the code too early (the addon has not yet been adapted for 2.7). Are there other cases where it is working in a custom syntax?

@APickledWalrus APickledWalrus added addon-related An issue that is related to an addon and not Skript. and removed investigating The core developers are currently investigating this issue. Usually used for complex cases. waiting for reply The report needs a response from the reporter to determine course of action. labels Jun 29, 2023
@L3v3lup
Copy link
Author

L3v3lup commented Jun 30, 2023

Oh i didn't realize that. Thanks for pointing that out.
I will text TPGamesNL about that problem.

@Moderocky
Copy link
Member

The related issue for skript reflect is marked as completed, so I'll assume this is fixed. Either way, it's not a Skript issue so this wouldn't be the place for the ticket.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
addon-related An issue that is related to an addon and not Skript.
Projects
None yet
Development

No branches or pull requests

3 participants