Skip to content

Commit

Permalink
Final warning
Browse files Browse the repository at this point in the history
- Address warnings generated by javadocs and mixin remaps for joml
  • Loading branch information
Jozufozu committed May 4, 2024
1 parent e7844cc commit 89f48c2
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ public interface LitVisual extends Visual {
*
* <p>Even if multiple sections are updated at the same time, this method will only be called once.</p>
*
* <p>The implementation is free to parallelize calls to this method, as well as call into
* {@link DynamicVisual#beginFrame} simultaneously. It is safe to query/update light here,
* but you must ensure proper synchronization if you want to mutate anything outside this
* visual or anything that is also mutated by {@link DynamicVisual#beginFrame}.</p>
* <p>The implementation is free to parallelize calls to this method, as well as execute the plan
* returned by {@link DynamicVisual#planFrame} simultaneously. It is safe to query/update light here,
* but you must ensure proper synchronization if you want to mutate anything outside this visual or
* anything that is also mutated within {@link DynamicVisual#planFrame}.</p>
*/
void updateLight();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public interface SimpleDynamicVisual extends DynamicVisual {
* The implementation is free to parallelize calls to this method.
* You must ensure proper synchronization if you need to mutate anything outside this visual.
* <br>
* This method and {@link TickableVisual#tick} will never be called simultaneously.
* This method and {@link SimpleTickableVisual#tick} will never be called simultaneously.
* <br>
* {@link Instancer}/{@link Instance} creation/acquisition is safe here.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public interface SimpleTickableVisual extends TickableVisual {
* The implementation is free to parallelize calls to this method.
* You must ensure proper synchronization if you need to mutate anything outside this visual.
* <br>
* This method and {@link DynamicVisual#beginFrame} will never be called simultaneously.
* This method and {@link SimpleDynamicVisual#beginFrame} will never be called simultaneously.
* <br>
* {@link Instancer}/{@link Instance} creation/acquisition is safe here.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ private TransformedInstance createInstance(Model model) {

/**
* Update the fire instances. You'd typically call this in your visual's
* {@link com.jozufozu.flywheel.api.visual.DynamicVisual#beginFrame(DynamicVisual.Context) beginFrame} method.
* {@link com.jozufozu.flywheel.lib.visual.SimpleDynamicVisual#beginFrame(DynamicVisual.Context) beginFrame} method.
*
* @param context The frame context.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public ShadowComponent strength(float strength) {

/**
* Update the shadow instances. You'd typically call this in your visual's
* {@link com.jozufozu.flywheel.api.visual.DynamicVisual#beginFrame(DynamicVisual.Context) beginFrame} method.
* {@link com.jozufozu.flywheel.lib.visual.SimpleDynamicVisual#beginFrame(DynamicVisual.Context) beginFrame} method.
*
* @param context The frame context.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ abstract class FixNormalScalingMixin {
* applied, which negates the matrix again, resulting in the matrix being the
* same as in the beginning.
*/
@Inject(method = "scale(FFF)V", at = @At(value = "INVOKE", target = "Lorg/joml/Matrix3f;scale(F)Lorg/joml/Matrix3f;", shift = Shift.AFTER), cancellable = true)
@Inject(method = "scale(FFF)V", at = @At(value = "INVOKE", target = "Lorg/joml/Matrix3f;scale(F)Lorg/joml/Matrix3f;", shift = Shift.AFTER, remap = false), cancellable = true)
private void flywheel$returnAfterNegate(float x, float y, float z, CallbackInfo ci) {
ci.cancel();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ public static <T extends Entity> EntityVisualizer<? super T> getVisualizer(T ent

/**
* Checks if the given block entity can be visualized.
* @param type The block entity to check.
* @param <T> The block entity.
* @param blockEntity The block entity to check.
* @param <T> The type of the block entity.
* @return {@code true} if the block entity can be visualized.
*/
public static <T extends BlockEntity> boolean canVisualize(T blockEntity) {
Expand All @@ -41,8 +41,8 @@ public static <T extends BlockEntity> boolean canVisualize(T blockEntity) {

/**
* Checks if the given entity can be visualized.
* @param type The entity to check.
* @param <T> The entity.
* @param entity The entity to check.
* @param <T> The type of the entity.
* @return {@code true} if the entity can be visualized.
*/
public static <T extends Entity> boolean canVisualize(T entity) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -210,10 +210,7 @@ public VisualManager<Effect> getEffects() {
}

/**
* Tick the visuals after the game has ticked:
* <p>
* Call {@link TickableVisual#tick} on all visuals in this level.
* </p>
* Begin execution of the tick plan.
*/
public void tick() {
// Make sure we're done with any prior frame or tick to avoid racing.
Expand All @@ -227,11 +224,7 @@ public void tick() {
}

/**
* Get ready to render a frame.
*
* <p>Check and update the render origin.
* <br>
* Call {@link DynamicVisual#beginFrame} on all visuals in this level.</p>
* Begin execution of the frame plan.
*/
public void beginFrame(RenderContext context) {
// Make sure we're done with the last tick.
Expand Down

0 comments on commit 89f48c2

Please sign in to comment.