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

NPE when using loop-value in a date list #2302

Closed
Whimsyturtle opened this issue Jul 26, 2019 · 1 comment
Closed

NPE when using loop-value in a date list #2302

Whimsyturtle opened this issue Jul 26, 2019 · 1 comment
Labels
bug An issue that needs to be fixed. Alternatively, a PR fixing an issue. completed The issue has been fully resolved and the change will be in the next Skript update. priority: low Issues that are not harmful to the experience but are related to useful changes or additions.

Comments

@Whimsyturtle
Copy link
Member

Whimsyturtle commented Jul 26, 2019

Description

When having a date list, and looping through the date list and getting the difference between now and loop-value, an NPE will occur upon skript parse.

Steps to Reproduce

command /test:
    trigger:
        loop {list::*}:
            send "%difference between now and loop-value%"

Expected Behavior

For an NPE to not be thrown on skript parse

Errors / Screenshots

https://pastebin.com/HqprGYjk

Server Information

  • Server version/platform: Spigot 1.14.4
  • Skript version: Skript 2.4-beta3

Additional Context

@TheBentoBox TheBentoBox added bug An issue that needs to be fixed. Alternatively, a PR fixing an issue. priority: low Issues that are not harmful to the experience but are related to useful changes or additions. labels Jul 31, 2019
@Whimsyturtle Whimsyturtle changed the title NPE when using loop-value NPE when using loop-value in a date list Oct 17, 2019
@TPGamesNL
Copy link
Member

AFAIK this occurs when one of the 2 expressions has Object as their return type (not as a variable), such as:
set {_x} to difference between (metadata "test" of player) and (metadata "test" of player)
or
set {_x} to difference between 1 and loop-value

@Whimsyturtle Whimsyturtle added the completed The issue has been fully resolved and the change will be in the next Skript update. label Mar 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An issue that needs to be fixed. Alternatively, a PR fixing an issue. completed The issue has been fully resolved and the change will be in the next Skript update. priority: low Issues that are not harmful to the experience but are related to useful changes or additions.
Projects
None yet
Development

No branches or pull requests

4 participants