Skip to content

Commit

Permalink
Codebase Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
SammySemicolon committed Jun 17, 2022
1 parent 6a1cf09 commit ed1b2f0
Show file tree
Hide file tree
Showing 30 changed files with 395 additions and 163 deletions.
26 changes: 26 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/usr/bin/env groovy

pipeline {
agent any
stages {
stage('Clean') {
steps {
echo 'Cleaning Project'
sh 'chmod +x gradlew'
sh './gradlew clean'
}
}
stage('Build') {
steps {
echo 'Building'
sh './gradlew build'
}
}
stage('Publish') {
steps {
echo 'Deploying to Maven'
sh './gradlew publish'
}
}
}
}
23 changes: 21 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ apply plugin: 'org.spongepowered.mixin'
apply plugin: 'org.parchmentmc.librarian.forgegradle'

version = "${project.minecraftVersion}-${project.modVersion}"
if (System.getenv('BUILD_NUMBER') != null) {
version += "." + System.getenv('BUILD_NUMBER')
}
group = 'com.sammy.malum'
archivesBaseName = project.modId
java.toolchain.languageVersion = JavaLanguageVersion.of(17)
Expand Down Expand Up @@ -141,17 +144,33 @@ jar {
}
}

jar.finalizedBy('reobfJar')
jar.finalizedBy('reobfJar')
tasks.withType(GenerateModuleMetadata) {

enabled = false
}
publishing {
publications {
mavenJava(MavenPublication) {
groupId project.group
artifactId project.archivesBaseName
version project.version
artifact jar

pom.withXml {

// Go through all the dependencies.
asNode().dependencies.dependency.each { dep ->

println 'Surpressing artifact ' + dep.artifactId.last().value().last() + ' from maven dependencies.'
assert dep.parent().remove(dep)
}
}
}
}
repositories {
maven {
url "file:///${project.projectDir}/mcmodsrepo"
url = uri("file://${System.getenv("local_maven")}")
}
}
}
2 changes: 1 addition & 1 deletion src/main/generated_resources/.cache/cache
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ eae07e90708b4ad79087ece2f880b20d2dd71862 assets/malum/blockstates/vertical_soulw
ea2124145fd87d36427a1e743f7865d328403f7b assets/malum/blockstates/vertical_soulwood_planks_slab.json
d9001ce582022fed3dcfa3c78a5f1497f622a419 assets/malum/blockstates/vertical_soulwood_planks_stairs.json
1c5a82140570f65af0f2675a889a4887d87d3874 assets/malum/blockstates/wall_ether_torch.json
8a0df2de84a4acc9799d24d3601a957a3ff6d4b2 assets/malum/lang/en_us.json
9b27a5ad5338ca8d18508454848b3c5dd60d3622 assets/malum/lang/en_us.json
a75ef274d6ea80a594a834a6f1a473a9afa5d32f assets/malum/models/block/blazing_quartz_ore.json
2013d43596b37d4dfb09f9b7a02e6887456aadb6 assets/malum/models/block/blighted_coverage.json
b5adc24d11ad28ebea0cc9858df3c7f1ba618c65 assets/malum/models/block/blighted_earth.json
Expand Down
6 changes: 3 additions & 3 deletions src/main/generated_resources/assets/malum/lang/en_us.json
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,7 @@
"malum.gui.book.entry.page.text.expanded_focusing_a": "Furthermore, arcane restoration isn't restricted to just repairing your impetus; it extends much further. Using the restoring process we are able to repair nearly any damaged item.",
"malum.gui.book.entry.page.text.expanded_focusing_b": "Each item will require a unique set of spirits that need to be slotted in the crucible as well as a valid repair ingredient aimed at the crucible in the twisted tablet.",
"malum.gui.book.entry.page.text.expanded_focusing_c": "Additionally, gear closely connected with spirit arcana can be repaired more effectively.",
"malum.gui.book.entry.page.text.hallowed_gold_a": "Gold is very often used as a basis for various magics, this is also the case with spirit arcana. Infusing arcane and sacred arcana into a gold ingot will imbue it with magic and yield a much more desirable magical metal. A few additional reagents are also needed for this process.",
"malum.gui.book.entry.page.text.hallowed_gold_a": "Gold is very often used as a basis for various magics, I believe this property to be relevant when dealing with soul magic as well. Infusing raw and sacred arcana into a gold ingot will imbue it with magic and yield a much more desirable arcane metal. A few additional reagents are also required for this infusion.",
"malum.gui.book.entry.page.text.hallowed_gold_b": "While not too useful in evil schemes or crafting powerful gear, hallowed gold is a metal perfect for spirit manipulation and transfer.",
"malum.gui.book.entry.page.text.haunted": "When a soul is damaged a lot of it's integrity is lost, resulting in some of it's magical energy being released. The haunted enchantment converts that magic energy into extra magic damage to anyone cut by the blade. Higher tiers damage the target further.",
"malum.gui.book.entry.page.text.hex_ash": "As a test of this altar, I have created a powder which I will call Hex ash. It is a simple grit which I will use as a minor ingredient in various magics. The ash is imbued with arcane spirit, which I have taken from a skeleton.",
Expand All @@ -534,8 +534,8 @@
"malum.gui.book.entry.page.text.necklace_of_the_narrow_edge": "The scythe sweep attack can be extremely useful in clearing through hordes of prey, however in other cases it can be seen as unnecessary or even impractical. This iron necklace will completely remove your scythe's sweep attack in exchange for a strong damage increase.",
"malum.gui.book.entry.page.text.rebound": "The rebound enchantment is by far the strangest one of all. It will grant the user the ability to throw the scythe like a boomerang, allowing for a wacky ranged attack. Higher tiers reduce the delay before the scythe can be thrown once more.",
"malum.gui.book.entry.page.text.ring_of_curative_talent": "Tears of the ghast have some really strong curative properties. Combining one with some sacred arcana and infusing both into a gilded ring will yield us the ring of curative talent. This simple trinket will recover a large portion of your health when collecting spirits.",
"malum.gui.book.entry.page.text.ring_of_prowess_a": "There is another thing besides spirit arcana that the soul holds, it is known as brilliance, which you may know as experience. Unlike spirits, brilliance has strong enough ties to the body and some of it is naturally dispersed from the soul upon the defeat of the vessel.",
"malum.gui.book.entry.page.text.ring_of_prowess_b": "As with all things, we can't let the soul keep anything for itself. With some clever use of raw arcana combined with natural brilliance we can leech off some extra experience as spirits leave the dying soul. The ring of prowess does just that.",
"malum.gui.book.entry.page.text.ring_of_prowess_a": "The soul holds more than just spirit flux within it, brilliance, also known as experience can be found within. Unlike spirits, brilliance has a rather loose connection to the soul, even just slaying the vessel through regular means releases some of this stored brilliance.",
"malum.gui.book.entry.page.text.ring_of_prowess_b": "As with all things, we can't let the soul keep anything for itself. With some clever manipulation of raw arcana combined with natural brilliance we can leech off some extra experience from the dying soul. The ring of prowess does just that, awarding the bearer with experience as they collect each individual spirit.",
"malum.gui.book.entry.page.text.ring_of_wicked_intent": "The wicked ring is a simple yet practical trinket that will greatly assist you in combat. Taking note from the powerful wither army the ring will react to nearby spirit arcana and reward you with strength and rage when collecting spirits.",
"malum.gui.book.entry.page.text.runewood_a": "While adventuring I have found a strange tree, it grows in plains and forests and holds a yellow crown. It is a display of pure arcane energy, I believe it's bark and wood will prove itself useful to me. I shall name it Runewood, in note of it's magical nature.",
"malum.gui.book.entry.page.text.runewood_b": "Due to it's magical nature, the wood of the tree appears to function as a great conductor for magic. Even just touching the sapling creates a warm feeling, which I can feel in my very soul. It appears that anything with enough magical energy within is able to impose itself on your very soul, almost as if touching it directly.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

public class HeadOverlayModel extends EntityModel<Player> {

public static ModelLayerLocation LAYER = new ModelLayerLocation(MalumMod.prefix("textures/other/owl_texture"), "main");
public static ModelLayerLocation LAYER = new ModelLayerLocation(MalumMod.prefix("head_overlay"), "main");
public final ModelPart overlay;

public HeadOverlayModel(ModelPart root) {
Expand Down
49 changes: 49 additions & 0 deletions src/main/java/com/sammy/malum/client/model/ScarfModel.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
package com.sammy.malum.client.model;

import com.google.common.collect.ImmutableList;
import com.mojang.blaze3d.vertex.PoseStack;
import com.mojang.blaze3d.vertex.VertexConsumer;
import com.sammy.malum.MalumMod;
import com.sammy.ortus.systems.model.OrtusArmorModel;
import net.minecraft.client.model.EntityModel;
import net.minecraft.client.model.HumanoidModel;
import net.minecraft.client.model.geom.ModelLayerLocation;
import net.minecraft.client.model.geom.ModelPart;
import net.minecraft.client.model.geom.PartPose;
import net.minecraft.client.model.geom.builders.*;
import net.minecraft.world.entity.player.Player;

public class ScarfModel extends EntityModel<Player> {

public static ModelLayerLocation LAYER = new ModelLayerLocation(MalumMod.prefix("scarf"), "main");
public final ModelPart headScarf;
public final ModelPart torsoScarf;

public ScarfModel(ModelPart root) {
this.headScarf = root.getChild("head_scarf");
this.torsoScarf = root.getChild("torso_scarf");

}

public static LayerDefinition createBodyLayer() {
MeshDefinition mesh = HumanoidModel.createMesh(new CubeDeformation(0), 0);
PartDefinition partdefinition = mesh.getRoot();

PartDefinition headScarf = partdefinition.addOrReplaceChild("head_scarf", CubeListBuilder.create().texOffs(0, 14).addBox(-4.5F, -2.25F, -4.5F, 9.0F, 3.0F, 9.0F, new CubeDeformation(0.0F)), PartPose.offset(0.0F, 0.0F, 0.0F));

PartDefinition torsoScarf = partdefinition.addOrReplaceChild("torso_scarf", CubeListBuilder.create().texOffs(0, 0).addBox(-5.5F, -25.0F, -2.5F, 11.0F, 9.0F, 5.0F, new CubeDeformation(0.0F)), PartPose.offset(0.0F, 24.0F, 0.0F));

return LayerDefinition.create(mesh, 64, 32);
}

@Override
public void setupAnim(Player pEntity, float pLimbSwing, float pLimbSwingAmount, float pAgeInTicks, float pNetHeadYaw, float pHeadPitch) {

}

@Override
public void renderToBuffer(PoseStack poseStack, VertexConsumer buffer, int packedLight, int packedOverlay, float red, float green, float blue, float alpha) {
headScarf.render(poseStack, buffer, packedLight, packedOverlay);
torsoScarf.render(poseStack, buffer, packedLight, packedOverlay);
}
}
2 changes: 1 addition & 1 deletion src/main/java/com/sammy/malum/client/model/TailModel.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

public class TailModel extends EntityModel<Player> {

public static ModelLayerLocation LAYER = new ModelLayerLocation(MalumMod.prefix("textures/other/sammy_texture"), "main");
public static ModelLayerLocation LAYER = new ModelLayerLocation(MalumMod.prefix("tail"), "main");
private final ModelPart tail;

public TailModel(ModelPart root) {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"meta":{"format_version":"4.0","creation_time":1655475089,"model_format":"modded_entity","box_uv":true},"name":"ScarModel","geometry_name":"steve","modded_entity_version":"1.17","visible_box":[1,1,0],"variable_placeholders":"","variable_placeholder_buttons":[],"resolution":{"width":64,"height":32},"elements":[{"name":"body_scarf","rescale":false,"locked":false,"from":[-5.5,16,-2.5],"to":[5.5,25,2.5],"autouv":0,"color":0,"origin":[0,0,0],"faces":{"north":{"uv":[5,5,16,14],"texture":0},"east":{"uv":[0,5,5,14],"texture":0},"south":{"uv":[21,5,32,14],"texture":0},"west":{"uv":[16,5,21,14],"texture":0},"up":{"uv":[16,5,5,0],"texture":0},"down":{"uv":[27,0,16,5],"texture":0}},"type":"cube","uuid":"cf8dd474-0366-4b64-27cb-58bcf339ce33"},{"name":"head_scarf","rescale":false,"locked":false,"from":[-4.5,23.25,-4.5],"to":[4.5,26.25,4.5],"autouv":0,"color":0,"origin":[0,0,0],"uv_offset":[0,14],"faces":{"north":{"uv":[9,23,18,26],"texture":0},"east":{"uv":[0,23,9,26],"texture":0},"south":{"uv":[27,23,36,26],"texture":0},"west":{"uv":[18,23,27,26],"texture":0},"up":{"uv":[18,23,9,14],"texture":0},"down":{"uv":[27,14,18,23],"texture":0}},"type":"cube","uuid":"d91e9241-7e11-01df-1363-431774c38598"}],"outliner":[{"name":"helmet","origin":[0,24,0],"color":0,"uuid":"7e3ee6f2-3f06-a380-a526-ffb03f3e5f74","export":true,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["d91e9241-7e11-01df-1363-431774c38598"]},{"name":"torso","origin":[0,0,0],"color":0,"uuid":"ff6e076f-4b94-5425-05cf-9e30be813700","export":true,"isOpen":true,"locked":false,"visibility":true,"autouv":0,"children":["cf8dd474-0366-4b64-27cb-58bcf339ce33"]}],"textures":[{"path":"C:\\Users\\Hanna\\Desktop\\Mod-Stuff\\Malum-Mod\\src\\main\\resources\\assets\\malum\\textures\\patreon\\snake_scarf.png","name":"snake_scarf.png","folder":"","namespace":"","id":"0","particle":false,"render_mode":"default","visible":true,"mode":"bitmap","saved":true,"uuid":"46b725ee-f5fa-986e-9711-a721e0b56d22","relative_path":"../../../../../../../../resources/assets/malum/textures/patreon/snake_scarf.png","source":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAAAgCAYAAACinX6EAAAAAXNSR0IArs4c6QAAAgZJREFUaENjZBjhgHGE+59hNABGU8AIDwHGRLGe/6AweP//GTwoBBmlwGx+DlmGCY/CMbJJgdzK/x9/PAarwaUPZhgu/SB5kBnzX5UMaDZkfLPR+r+I/1G4I0B8kONacvPADgR5EDlABLnFIB7/+oqhZvIkMBubfpB4aWogOBBBekDqQeDB95Ng87pnr8fQOxCJEWfof78RBQ4IEOCQtgLTP54eY/h68yEDt7o8mM+psQyn/pszjf7L2Wtg6AcJgMx4++I7g3r6uQGNfZBb8Drg/+cp4EB4u285SixTElOgFEZMAFJiByl68QYAKBWAYgs5iZNiODa1oPJjsOR/gimAFgEAKnRh5cpAF4BEBcCjgzeomldhtU5F8zKqmktuysSbBUD5ldqFFayWoWa2ItfzBFMASAF6NUmJZYNR74BXQwMdKKMBMNAxMND2j6aAgY6BgbZ/NAUMdAwMtP2jKWCgY2Cg7cc6IgRyFPIgCJjPLcaQ3VHDIOwUCXczqJs8taIFPtiBbZQI2SwQGzRAgj4SNJA9REbQwIWwBCfYU6B2Pwgg82FsWB++KzAV7GFQgJStnw1WD+oyw/TjMwukBjRIUunmD9YPAiCzQAEy7dA5Bmp3vIhJXXQvA0B9C+RUBHMkNQddiPE4TA3dA4AUx9FD7WgA0COUB7MdoylgMMcOPdw24lMAAGI/4SHPlnAaAAAAAElFTkSuQmCC"}]}
Loading

0 comments on commit ed1b2f0

Please sign in to comment.