@ -1,5 +1,8 @@
|
||||
# Changelog
|
||||
|
||||
**1.0.8**
|
||||
* Update Textures
|
||||
|
||||
**Beta 0.2.2**
|
||||
* Update To Fabric Structure API
|
||||
|
||||
|
27
docs/API.md
Normal file
@ -0,0 +1,27 @@
|
||||
# API
|
||||
The public API is in the package ``com.thebrokenrail.energonrelics.api``. Any registries are located in the package ``com.thebrokenrail.energonrelics.registry``. Anything else should be treated as unstable and may change at any moment.
|
||||
|
||||
## Setup
|
||||
|
||||
### ``build.gradle``
|
||||
```gradle
|
||||
repositories {
|
||||
maven { url 'https://maven.thebrokenrail.com' }
|
||||
}
|
||||
dependencies {
|
||||
modImplementation 'com.thebrokenrail:energonrelics:VERSION'
|
||||
// VERSION = "<Mod Version>+<MC Version>", for example "1.0.0+1.16.2"
|
||||
}
|
||||
```
|
||||
|
||||
### ``fabric.mod.json``
|
||||
```json
|
||||
{
|
||||
"depends": {
|
||||
"energonrelics": "1.0.x"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## JavaDoc
|
||||
[View JavaDoc](https://jenkins.thebrokenrail.com/job/EnergonRelics/job/master/JavaDoc/)
|
@ -7,3 +7,5 @@
|
||||
[View Blocks](BLOCKS.md)
|
||||
|
||||
[View Structures](STRUCTURES.md)
|
||||
|
||||
[View API](API.md)
|
@ -10,7 +10,7 @@ org.gradle.jvmargs = -Xmx1G
|
||||
fabric_loader_version = 0.9.2+build.206
|
||||
|
||||
# Mod Properties
|
||||
mod_version = 0.2.2
|
||||
mod_version = 1.0.0
|
||||
maven_group = com.thebrokenrail
|
||||
|
||||
# Dependencies
|
||||
|
@ -14,8 +14,7 @@ import java.util.Objects;
|
||||
/**
|
||||
* Energy Ticker
|
||||
*/
|
||||
@ApiStatus.Internal
|
||||
public class EnergyTicker {
|
||||
public final class EnergyTicker {
|
||||
private static final List<EnergyTickable> scheduled = new ArrayList<>();
|
||||
private static List<EnergyTickable> allLoaded = Collections.emptyList();
|
||||
|
||||
@ -33,6 +32,7 @@ public class EnergyTicker {
|
||||
* Schedule For Next Energy Tick
|
||||
* @param tickable Object To Tick
|
||||
*/
|
||||
@ApiStatus.Internal
|
||||
public static void schedule(EnergyTickable tickable) {
|
||||
scheduled.add(tickable);
|
||||
}
|
||||
@ -41,6 +41,7 @@ public class EnergyTicker {
|
||||
* Tick Energy
|
||||
* @param world World
|
||||
*/
|
||||
@ApiStatus.Internal
|
||||
public static void tick(World world) {
|
||||
if (Objects.requireNonNull(world.getServer()).getThread() == Thread.currentThread()) {
|
||||
world.getProfiler().push(EnergonRelics.NAMESPACE);
|
||||
|
@ -3,7 +3,7 @@ package com.thebrokenrail.energonrelics.api.item;
|
||||
import net.minecraft.text.MutableText;
|
||||
|
||||
/**
|
||||
* Implement To Provide Extra Information In Multimeter
|
||||
* Implement To Provide Extra Information In Multimeter Output
|
||||
*/
|
||||
public interface MultimeterExtra {
|
||||
/**
|
||||
|
@ -26,7 +26,7 @@ public class SolarPanelBlockEntity extends EnergyGeneratorBlockEntity {
|
||||
for (Direction side : Direction.values()) {
|
||||
light = Math.max(light, getLight(side));
|
||||
}
|
||||
return (int) (((float) light) * Math.min(0, MathHelper.cos(Objects.requireNonNull(getWorld()).getSkyAngleRadians(1f))));
|
||||
return (int) (((float) light) * Math.max(0, MathHelper.cos(Objects.requireNonNull(getWorld()).getSkyAngleRadians(1f))));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -21,13 +21,13 @@ import net.minecraft.world.explosion.Explosion;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
public class IndustrialLaserBlockEntity extends FieldProjectorBlockEntity {
|
||||
public class IndustrialLaserProjectorBlockEntity extends FieldProjectorBlockEntity {
|
||||
private BlockPos targetPos;
|
||||
private BlockState targetState;
|
||||
|
||||
private int progress = 0;
|
||||
|
||||
public IndustrialLaserBlockEntity(BlockEntityType<?> type) {
|
||||
public IndustrialLaserProjectorBlockEntity(BlockEntityType<?> type) {
|
||||
super(type, state -> EnergonRelics.Blocks.INDUSTRIAL_LASER);
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
package com.thebrokenrail.energonrelics.block.forcefield.laser;
|
||||
|
||||
import com.thebrokenrail.energonrelics.block.entity.forcefield.laser.IndustrialLaserBlockEntity;
|
||||
import com.thebrokenrail.energonrelics.block.entity.forcefield.laser.IndustrialLaserProjectorBlockEntity;
|
||||
import com.thebrokenrail.energonrelics.block.forcefield.util.FieldProjectorBlock;
|
||||
import net.minecraft.block.entity.BlockEntity;
|
||||
import net.minecraft.block.entity.BlockEntityType;
|
||||
@ -14,6 +14,6 @@ public class IndustrialLaserProjectorBlock extends FieldProjectorBlock {
|
||||
|
||||
@Override
|
||||
protected Function<BlockEntityType<BlockEntity>, BlockEntity> getFactory() {
|
||||
return IndustrialLaserBlockEntity::new;
|
||||
return IndustrialLaserProjectorBlockEntity::new;
|
||||
}
|
||||
}
|
||||
|
@ -88,6 +88,7 @@ public class HighlightBlockEntityRenderer extends BlockEntityRenderer<BlockEntit
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("SameParameterValue")
|
||||
private static void vertex(VertexConsumer consumer, Matrix4f model, float x, float y, float z) {
|
||||
consumer.vertex(model, x, y, z).color(1f, 1f, 1f, 1f).next();
|
||||
}
|
||||
|
@ -2,9 +2,11 @@ package com.thebrokenrail.energonrelics.util;
|
||||
|
||||
import net.fabricmc.api.EnvType;
|
||||
import net.fabricmc.api.Environment;
|
||||
import org.jetbrains.annotations.ApiStatus;
|
||||
|
||||
import java.util.function.Consumer;
|
||||
|
||||
@ApiStatus.Internal
|
||||
@Environment(EnvType.CLIENT)
|
||||
public class BooleanIterator {
|
||||
public static void run(Consumer<Boolean> function) {
|
||||
|
After Width: | Height: | Size: 502 B |
After Width: | Height: | Size: 497 B |
After Width: | Height: | Size: 508 B |
After Width: | Height: | Size: 509 B |
After Width: | Height: | Size: 372 B |
After Width: | Height: | Size: 403 B |
After Width: | Height: | Size: 363 B |
Before Width: | Height: | Size: 575 B After Width: | Height: | Size: 2.5 KiB |
@ -10,7 +10,7 @@
|
||||
"item": "energonrelics:circuit_board"
|
||||
},
|
||||
"I": {
|
||||
"item": "minecraft:iron_ingot"
|
||||
"item": "minecraft:iron_nugget"
|
||||
},
|
||||
"L": {
|
||||
"item": "minecraft:lever"
|
||||
@ -18,6 +18,6 @@
|
||||
},
|
||||
"result": {
|
||||
"item": "energonrelics:switch",
|
||||
"count": 2
|
||||
"count": 4
|
||||
}
|
||||
}
|