Skript icon indicating copy to clipboard operation
Skript copied to clipboard

Fix vehicle register

Open TheLimeGlass opened this issue 1 year ago • 1 comments

Description

vehicle itself cannot be used within an on mount event.

The only change is the registerDefault and removal of Delay.isDelayed because setTime handles this. The rest is code standards.

on mount:
	broadcast "%vehicle%"
	name of vehicle is "boat"
	passengers of vehicle is set
	cancel event

Errors: Untitled


Target Minecraft Versions: any Requirements: none Related Issues: none

TheLimeGlass avatar Mar 11 '24 15:03 TheLimeGlass

I'm not entirely convinced the removal of the delay checks is correct, I'll have to test that. Other than that, looks good!

Skript will error at parse time if any delay was used before it, making it not possible for this get method to even be called in the first place. Even event switching in a section won't work because it wouldn't have the EntityMountEvent which is needed for that condition to send default event expressions.

I have re-added the delay check. Let me know your thoughts and investigation.

TheLimeGlass avatar Mar 23 '24 19:03 TheLimeGlass

still needs tests

See https://github.com/SkriptLang/Skript/pull/5312

TheLimeGlass avatar Sep 17 '24 20:09 TheLimeGlass

still needs tests

See #5312

This PR should have its own regression tests so it's not dependent on the other pr for merging

sovdeeth avatar Sep 17 '24 21:09 sovdeeth

Inactive

sovdeeth avatar May 06 '25 21:05 sovdeeth