-
-
Notifications
You must be signed in to change notification settings - Fork 375
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
Update charged syntax #6860
Merged
Merged
Update charged syntax #6860
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
996a0e9
Update CondIsCharged
cheeezburga 28f1d87
Adds new test and updates effect
cheeezburga 5ba53c4
Fixes test
cheeezburga d231cba
Apply suggestions from code review
cheeezburga 883a222
Merge branch 'dev/patch' into update-charged
sovdeeth 6f2e52c
Merge branch 'dev/patch' into update-charged
cheeezburga c8b60c3
Suggestions
cheeezburga 16ed7e6
Merge branch 'dev/feature' into update-charged
Moderocky File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
src/test/skript/tests/syntaxes/conditions/CondIsCharged.sk
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
test "is charged": | ||
spawn a creeper at (spawn of world "world"): | ||
set {_e} to entity | ||
shoot a wither skull from {_e} | ||
set {_w} to last shot entity | ||
|
||
assert {_e} is not charged with "a normally spawned creeper should not be charged" | ||
assert {_w} is not charged with "a normally spawned wither skull should not be charged" | ||
|
||
charge {_e} | ||
charge {_w} | ||
assert {_e} is charged with "charging a creeper should do exactly that" | ||
assert {_w} is charged with "charging a wither skull should do exactly that" | ||
|
||
uncharge {_e} | ||
uncharge {_w} | ||
assert {_e} is not charged with "uncharging a creeper should do exactly that" | ||
assert {_w} is not charged with "uncharging a wither skull should do exactly that" | ||
|
||
spawn an adult zombie at (spawn of world "world"): | ||
set {_z} to entity | ||
|
||
assert {_z} is not charged with "a non-creeper/wither skull should never be charged" | ||
charge {_z} | ||
assert {_z} is not charged with "charging a non-creeper/wither skull should do nothing" | ||
uncharge {_z} | ||
assert {_z} is not charged with "uncharging a non-creeper/wither skull should do nothing" | ||
|
||
delete entity within {_e} | ||
delete entity within {_w} | ||
delete entity within {_z} |
This file was deleted.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can also use event-location in the case that we change the location for some reason.