Interface JavaKineticWeapon.Condition
- Enclosing interface:
JavaKineticWeapon
public static interface JavaKineticWeapon.Condition
A condition used during the attack of a
JavaKineticWeapon.- Since:
- 2.9.3
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic @NonNull JavaKineticWeapon.Condition.Builderbuilder(@org.checkerframework.checker.index.qual.NonNegative int maxDurationTicks) Creates a builder for aJavaKineticWeapon.Condition.@org.checkerframework.checker.index.qual.NonNegative intThe time in ticks after which the condition is no longer checked (and thus always fails), starting onceJavaKineticWeapon.delayTicks()has passed.floatThe minimum relative speed between the attacker and the target, in blocks per second, required for the condition to pass.floatminSpeed()The minimum speed of the attacker, in blocks per second, required for the condition to pass.
-
Method Details
-
maxDurationTicks
@org.checkerframework.checker.index.qual.NonNegative int maxDurationTicks()The time in ticks after which the condition is no longer checked (and thus always fails), starting onceJavaKineticWeapon.delayTicks()has passed.- Returns:
- the time in ticks after which the condition is no longer checked
- Since:
- 2.9.3
-
minSpeed
float minSpeed()The minimum speed of the attacker, in blocks per second, required for the condition to pass. Defaults to 0.- Returns:
- the minimum speed of the attacker, in blocks per second
- Since:
- 2.9.3
-
minRelativeSpeed
float minRelativeSpeed()The minimum relative speed between the attacker and the target, in blocks per second, required for the condition to pass. Defaults to 0.- Returns:
- the minimum relative speed between the attacker and the target, in blocks per second
- Since:
- 2.9.3
-
builder
static @NonNull JavaKineticWeapon.Condition.Builder builder(@org.checkerframework.checker.index.qual.NonNegative int maxDurationTicks) Creates a builder for aJavaKineticWeapon.Condition.- Parameters:
maxDurationTicks- the time in ticks after which the condition is no longer checked- Returns:
- a new builder
- Since:
- 2.9.3
- See Also:
-