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

Chicken throws an error #4809

Closed
1 task done
XenonsEU opened this issue Jun 16, 2022 · 2 comments
Closed
1 task done

Chicken throws an error #4809

XenonsEU opened this issue Jun 16, 2022 · 2 comments
Labels
duplicate For bugs or requests that have already been made and are currently open.

Comments

@XenonsEU
Copy link

Skript/Server Version

Server Version: git-Paper-277 (MC: 1.18.2) - It is !!1.19!! but it shows 1.18.2
Skript Version: 2.6.2-mc-1.19
Installed Skript Addons: 
Skent v3.1.0
Skacket v1.0.10
skript-reflect v2.3 (https://github.com/TPGamesNL/skript-reflect)
skUtilities v0.9.2 (https://tim740.github.io/)
skript-db v1.3.3
skRayFall v1.9.27 (https://sk.rayfall.net/)
SkQuery v4.1.6
SkBee v1.16.0 (https://github.com/ShaneBeee/SkBee)
SkJade v1.4.1 (https://www.github.com/Ankoki-Dev/SkJade)
RediSkript v1.3.5
Skript-Packet v2.1.0 (www.github.com/Anarchick/skript-packet)
SkStuff v2.2.1

Bug Description

When using entity in a function, they all work fine that I've tested so far
except chicken

when I put chicken as entity it just says that "Variables cannot be used here" or that the argument given is not of the correct type
different errors based on how many arguments the function has.
as soon as I swap the entity to anything else like cow/pig it works fine

Expected Behavior

I want my chickens

Steps to Reproduce

function testChicken(e: entity type):
    broadcast {_e}

command /testchicken:
    trigger:
        testChicken(chicken)

Swapping chicken argument with a cow works for example.

Errors or Screenshots

No response

Other

No response

Agreement

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

TheLimeGlass commented Jun 16, 2022

It's conflicting with the item type chicken as in cooked chicken.

You can set the default parameter of the function or parse the input as an entity type so Skript knows which chicken you're referring too.

function testChicken(e: entity type = chicken):
	broadcast {_e}

command /testchicken:
	trigger:
		testChicken("chicken" parsed as entity type)
		testChicken()

You will also have conflicts with fishes and rabbit.

@TheLimeGlass TheLimeGlass 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 Jun 16, 2022
@TheLimeGlass
Copy link
Collaborator

TheLimeGlass commented Jun 16, 2022

Duplicate #4769 @TPGamesNL

Pull request at #4776

@TheLimeGlass TheLimeGlass added duplicate For bugs or requests that have already been made and are currently open. and removed 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 Jun 16, 2022
@TheLimeGlass TheLimeGlass closed this as not planned Won't fix, can't repro, duplicate, stale Jun 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate For bugs or requests that have already been made and are currently open.
Projects
None yet
Development

No branches or pull requests

2 participants