Résolu Exportation du mod qui foire (nom de fichier incorrect)
-
C’est la soirée où je n’ai que des gros problèmes avec mon mod.
J’ai exporté une version de mon mod qui n’a pas été reconnu par mon serveur (pouf plus rien), du coup je re-exporte une version pour voir où est le prob et boum:
:::
Voilà, donc en fait ça m’a créé un .jar qui ne sert à rien.
Modifs que j’ai fais depuis la dernière exportation:
-ajout d’un bloc type four (Gui/Container/recipes)
-ajout d’un cooldown sur mes monturesRien de plus de mémoire.
Où dois-je chercher pour que ce problème ne se reproduise plus et que je puisse exporter de nouveau un fichier viable svp?
(C’est un peu la détresse là Xd )EDIT: La seule piste que j’ai pour le moment serait ma déclaration du GuiHandler peut-être, ici à la fin:
! ```java
@SuppressWarnings(“static-access”)
@EventHandler
public void Init(FMLInitializationEvent event)
{
MinecraftForge.EVENT_BUS.register(new LivingEventHandler());
! EntityRegistry.registerGlobalEntityID(EntityKart.class, “kart”, EntityRegistry.findGlobalUniqueEntityId(), new Color(200, 200, 0).getRed(), new Color(0, 0, 0).getRed());
EntityRegistry.registerModEntity(EntityKart.class, “kart”, 801, this.instance, 40, 1, true);
EntityRegistry.registerGlobalEntityID(EntityMoto.class, “moto”, EntityRegistry.findGlobalUniqueEntityId(), new Color(140, 140, 80).getRed(), new Color(140, 140, 0).getRed());
EntityRegistry.registerModEntity(EntityMoto.class, “moto”, 802, this.instance, 40, 1, true);
EntityRegistry.registerGlobalEntityID(EntityBuggy.class, “buggy”, EntityRegistry.findGlobalUniqueEntityId(), new Color(0, 0, 0).getRed(), new Color(0, 0, 0).getRed());
EntityRegistry.registerModEntity(EntityBuggy.class, “buggy”, 803, this.instance, 40, 1, true);
EntityRegistry.registerGlobalEntityID(EntityBMX.class, “bmx”, EntityRegistry.findGlobalUniqueEntityId(), new Color(80, 80, 80).getRed(), new Color(80, 80, 80).getRed());
EntityRegistry.registerModEntity(EntityBMX.class, “bmx”, 804, this.instance, 40, 1, true);
EntityRegistry.registerGlobalEntityID(EntityBaignoire.class, “baignoire”, EntityRegistry.findGlobalUniqueEntityId(), new Color(140, 140, 80).getRed(), new Color(80, 80, 80).getRed());
EntityRegistry.registerModEntity(EntityBaignoire.class, “baignoire”, 805, this.instance, 40, 1, true);
EntityRegistry.registerGlobalEntityID(EntityBolide.class, “bolide”, EntityRegistry.findGlobalUniqueEntityId(), new Color(20, 20, 20).getRed(), new Color(20, 20, 20).getRed());
EntityRegistry.registerModEntity(EntityBolide.class, “bolide”, 806, this.instance, 40, 1, true);EntityRegistry.registerModEntity(EntityBlockSittable.class, “EntityBlockSittable”, 1, this, 500, 5, false);
! GameRegistry.registerTileEntity(TileEntityBlockBank.class, “Modpg:block_bank”);
GameRegistry.registerTileEntity(TileEntitySpot.class, “Modpg:spot”);
GameRegistry.registerTileEntity(TileEntityEclairage.class, “Modpg:eclairage”);
GameRegistry.registerTileEntity(TileEntityLampadaire.class, “Modpg:lampadaire”);
GameRegistry.registerTileEntity(TileEntityTrophee.class, “Modpg:trophee”);
GameRegistry.registerTileEntity(TileEntityHote.class, “Modpg:hotte”);
GameRegistry.registerTileEntity(TileEntityMicrowaves.class, “Modpg:microwaves”);
GameRegistry.registerTileEntity(TileEntityOven.class, “Modpg:oven”);
GameRegistry.registerTileEntity(TileEntityComptoir.class, “Modpg:comptoir”);
GameRegistry.registerTileEntity(TileEntityPlacard.class, “Modpg:placard”);
GameRegistry.registerTileEntity(TileEntityToaster.class, “Modpg:toaster”);
GameRegistry.registerTileEntity(TileEntityEvier.class, “Modpg:evier”);
GameRegistry.registerTileEntity(TileEntityFrigo.class, “Modpg:frigo”);
GameRegistry.registerTileEntity(TileEntityCoffre.class, “Modpg:coffre”);
GameRegistry.registerTileEntity(TileEntityMachineStup.class, “Modpg:MachineStupTileEntity”);
! NetworkRegistry.INSTANCE.registerGuiHandler(instance, new GuiHandler());
proxy.registerRender();
}:::
-
envoi ton build.gradle
-
:::
buildscript { repositories { mavenCentral() maven { name = "forge" url = "http://files.minecraftforge.net/maven" } maven { name = "sonatype" url = "https://oss.sonatype.org/content/repositories/snapshots/" } } dependencies { classpath 'net.minecraftforge.gradle:ForgeGradle:1.2-SNAPSHOT' } } apply plugin: 'forge' version = "2.4.5" group= "fr.powergame.modpg" // http://maven.apache.org/guides/mini/guide-naming-conventions.html archivesBaseName = "ModPg" minecraft { version = "1.7.10-10.13.4.1448-1.7.10" runDir = "eclipse/assets" } dependencies { // you may put jars on which you depend on in ./libs // or you may define them like so.. //compile "some.group:artifact:version:classifier" //compile "some.group:artifact:version" // real examples //compile 'com.mod-buildcraft:buildcraft:6.0.8:dev' // adds buildcraft to the dev env //compile 'com.googlecode.efficient-java-matrix-library:ejml:0.24' // adds ejml to the dev env // for more info… // http://www.gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html // http://www.gradle.org/docs/current/userguide/dependency_management.html } processResources { // this will ensure that this task is redone when the versions change. inputs.property "version", project.version inputs.property "mcversion", project.minecraft.version // replace stuff in mcmod.info, nothing else from(sourceSets.main.resources.srcDirs) { include 'mcmod.info' // replace version and mcversion expand 'version':project.version, 'mcversion':project.minecraft.version } // copy everything else, thats not the mcmod.info from(sourceSets.main.resources.srcDirs) { exclude 'mcmod.info' } }
:::
Je ne touche qu’à la version. 2.4.3 tout allait bien 2.4.4 tout fout le camp, 2.4.5 je comprend pourquoi.
ps: J’ai édit le premier message.
En fait, je suis presque sûr que ma noobitude m’a fait faire une connerie ici:
NetworkRegistry.INSTANCE.registerGuiHandler(instance, new GuiHandler());
-
pourquoi ton runDir est mis sur eclipse/assets ? çà devrait être eclipse
pourquoi il y a-t-il “@SuppressWarnings(“static-access”)” dans ta classe principale ? je pense que le problème vient de là
pour ton gui handler : pourquoi çà viendrait de là ?
-
Parce que c’est la seule chose de nouvelle par rapport à avant.
edit: Le “@SuppressWarnings(“static-access”)” c’est pour éviter les message d’erreurs jaunes sur this.instance
-
Je vois pas comment çà pourrait venir de là. mais as-tu essayé d’enlever le suppress warnings et de modifier le runDir ?
-
Oh, donc en fait il ne faut pas faire this.instance? Mais juste instance?
EntityRegistry.registerGlobalEntityID(EntityKart.class, "kart", EntityRegistry.findGlobalUniqueEntityId(), new Color(200, 200, 0).getRed(), new Color(0, 0, 0).getRed()); EntityRegistry.registerModEntity(EntityKart.class, "kart", 801, this.instance, 40, 1, true);
Devient:
EntityRegistry.registerGlobalEntityID(EntityKart.class, "kart", EntityRegistry.findGlobalUniqueEntityId(), new Color(200, 200, 0).getRed(), new Color(0, 0, 0).getRed()); EntityRegistry.registerModEntity(EntityKart.class, "kart", 801, instance, 40, 1, true);
Jusque là je n’ai jamais eu de problème lié à ça mais j’éditerai quand j’aurai tenté tout ça.
Edit: Non ça ne change rien.
-
Déjà, je vois plusieurs problèmes, en premier lieu, ta méthode devrait être “init” et non “Init”, en second lieu,
java new Color(200, 200, 0).getRed()
va renvoyer uniquement la couleur rouge. Relance un build avec cette commande ```
gradlew build –stacktrace -
:::
!
:::
! Ps: Convention java actualisée pour le “init” et j’ai viré les couleurs, je ne me sers pas des oeufs de toute façon. -
<dossier de=“” forge=“”>/.gradle/gradle.log
ça sera plus simple avec le contenu de ce fichier. Car les screen de la console …As-tu des fichiers avec des accents ou des caractères spéciaux dans le nom ?</dossier>
-
:::
Powered By MCP:
http://modcoderpack.com/
Searge, ProfMobius, Fesh0r,
R4wk, ZeuX, IngisKahn, bspkrs
MCP Data version : unknown
All projects evaluated.
Selected primary task ‘DefaultTaskParameter{taskName=‘build’,projectPath=‘null’}’
Tasks to be executed: [task ‘:compileApiJava’, task ‘:processApiResources’, task ‘:apiClasses’, task ‘:sourceMainJava’, task ‘:compileJava’, task ‘:processResources’, task ‘:classes’, task ‘:jar’, task ‘:compileTestJava’, task ‘:processTestResources’, task ‘:testClasses’, task ‘:test’, task ‘:extractMcpData’, task ‘:getVersionJson’, task ‘:extractUserDev’, task ‘:genSrgs’, task ‘:reobf’, task ‘:assemble’, task ‘:check’, task ‘:build’]
:compileApiJava (Thread[main,5,main]) started.
:compileApiJava
Skipping task ‘:compileApiJava’ as it has no source files.
:compileApiJava UP-TO-DATE
:compileApiJava (Thread[main,5,main]) completed. Took 0.026 secs.
:processApiResources (Thread[main,5,main]) started.
:processApiResources
Skipping task ‘:processApiResources’ as it has no source files.
:processApiResources UP-TO-DATE
:processApiResources (Thread[main,5,main]) completed. Took 0.01 secs.
:apiClasses (Thread[main,5,main]) started.
:apiClasses
Skipping task ‘:apiClasses’ as it has no actions.
:apiClasses UP-TO-DATE
:apiClasses (Thread[main,5,main]) completed. Took 0.009 secs.
:sourceMainJava (Thread[main,5,main]) started.
:sourceMainJava
Executing task ‘:sourceMainJava’ (up-to-date check took 0.106 secs) due to:
Input file C:\Users\TRINITY\Desktop\Modding\Workspace Eclipse\forge-1.7.10\src\main\java\fr\powergame\modpg\common\Modpg.java has changed.
:sourceMainJava (Thread[main,5,main]) completed. Took 0.763 secs.
:compileJava (Thread[main,5,main]) started.
:compileJava
Failed to get resource: GET. [HTTP HTTP/1.1 403 Forbidden: https://libraries.minecraft.net//forgeSrc/1.7.10-10.13.4.1448-1.7.10/forgeSrc-1.7.10-10.13.4.1448-1.7.10.pom]
Failed to get resource: GET. [HTTP HTTP/1.1 403 Forbidden: https://libraries.minecraft.net/org/scala-lang/scala-parser-combinators_2.11/1.0.1/scala-parser-combinators_2.11-1.0.1.pom]
Failed to get resource: GET. [HTTP HTTP/1.1 403 Forbidden: https://libraries.minecraft.net/org/scala-lang/scala-swing_2.11/1.0.1/scala-swing_2.11-1.0.1.pom]
Failed to get resource: GET. [HTTP HTTP/1.1 403 Forbidden: https://libraries.minecraft.net/org/scala-lang/scala-xml_2.11/1.0.2/scala-xml_2.11-1.0.2.pom]
file or directory ‘C:\Users\TRINITY\Desktop\Modding\Workspace Eclipse\forge-1.7.10\libs’, not found
Executing task ‘:compileJava’ (up-to-date check took 1.19 secs) due to:
Input file C:\Users\TRINITY\Desktop\Modding\Workspace Eclipse\forge-1.7.10\build\sources\java\fr\powergame\modpg\common\Modpg.java has changed.
file or directory ‘C:\Users\TRINITY\Desktop\Modding\Workspace Eclipse\forge-1.7.10\libs’, not found
Compiling with JDK Java compiler API.
warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
:compileJava (Thread[main,5,main]) completed. Took 4.753 secs.
:processResources (Thread[main,5,main]) started.
:processResources
Skipping task ‘:processResources’ as it is up-to-date (took 0.285 secs).
:processResources UP-TO-DATE
:processResources (Thread[main,5,main]) completed. Took 0.297 secs.
:classes (Thread[main,5,main]) started.
:classes
Skipping task ‘:classes’ as it has no actions.
:classes (Thread[main,5,main]) completed. Took 0.005 secs.
:jar (Thread[main,5,main]) started.
:jar
Executing task ‘:jar’ (up-to-date check took 0.123 secs) due to:
Input file C:\Users\TRINITY\Desktop\Modding\Workspace Eclipse\forge-1.7.10\build\classes\main\fr\powergame\modpg\common\Modpg$3.class has changed.
Input file C:\Users\TRINITY\Desktop\Modding\Workspace Eclipse\forge-1.7.10\build\classes\main\fr\powergame\modpg\common\Modpg.class has changed.
Input file C:\Users\TRINITY\Desktop\Modding\Workspace Eclipse\forge-1.7.10\build\classes\main\fr\powergame\modpg\common\Modpg$4.class has changed.
:jar (Thread[main,5,main]) completed. Took 1.694 secs.
:compileTestJava (Thread[main,5,main]) started.
:compileTestJava
Skipping task ‘:compileTestJava’ as it has no source files.
:compileTestJava UP-TO-DATE
:compileTestJava (Thread[main,5,main]) completed. Took 0.008 secs.
:processTestResources (Thread[main,5,main]) started.
:processTestResources
Skipping task ‘:processTestResources’ as it has no source files.
:processTestResources UP-TO-DATE
:processTestResources (Thread[main,5,main]) completed. Took 0.01 secs.
:testClasses (Thread[main,5,main]) started.
:testClasses
Skipping task ‘:testClasses’ as it has no actions.
:testClasses UP-TO-DATE
:testClasses (Thread[main,5,main]) completed. Took 0.007 secs.
:test (Thread[main,5,main]) started.
:test
file or directory ‘C:\Users\TRINITY\Desktop\Modding\Workspace Eclipse\forge-1.7.10\build\classes\test’, not found
Skipping task ‘:test’ as it has no source files.
:test UP-TO-DATE
:test (Thread[main,5,main]) completed. Took 0.01 secs.
:extractMcpData (Thread[main,5,main]) started.
:extractMcpData
Skipping task ‘:extractMcpData’ as it is up-to-date (took 0.003 secs).
:extractMcpData UP-TO-DATE
:extractMcpData (Thread[main,5,main]) completed. Took 0.011 secs.
:getVersionJson (Thread[main,5,main]) started.
:getVersionJson
Executing task ‘:getVersionJson’ (up-to-date check took 0.0 secs) due to:
Task has not declared any outputs.
:getVersionJson (Thread[main,5,main]) completed. Took 0.317 secs.
:extractUserDev (Thread[main,5,main]) started.
:extractUserDev
Failed to get resource: GET. [HTTP HTTP/1.1 403 Forbidden: https://libraries.minecraft.net/net/minecraftforge/forge/1.7.10-10.13.4.1448-1.7.10/forge-1.7.10-10.13.4.1448-1.7.10.pom]
Skipping task ‘:extractUserDev’ as it is up-to-date (took 1.263 secs).
:extractUserDev UP-TO-DATE
:extractUserDev (Thread[main,5,main]) completed. Took 1.271 secs.
:genSrgs (Thread[main,5,main]) started.
:genSrgs
Skipping task ‘:genSrgs’ as task onlyIf is false.
:genSrgs SKIPPED
:genSrgs (Thread[main,5,main]) completed. Took 1.236 secs.
:reobf (Thread[main,5,main]) started.
:reobf
Executing task ‘:reobf’ (up-to-date check took 0.003 secs) due to:
No history is available.
:reobf FAILED
:reobf (Thread[main,5,main]) completed. Took 0.891 secs.FAILURE: Build failed with an exception.
- What went wrong:
Execution failed for task ‘:reobf’.
MALFORMED
- Try:
Run with –stacktrace option to get the stack trace. Run with --debug option to get more log output.
BUILD FAILED
Total time: 16.849 secs
:::
J’ai fais “gradlew build --info” pour avoir ça.
Sinon oui maintenant que tu me le dis je crois que je me suis permis tout dernièrement de nommer des textures avec accent. Je modifie tout ça de suite pour voir ce qu’il en est.
Edit:
Bingo! En plein dedans, va falloir que j’arrête de taffer les textures à pas d’heure, ça me fait faire n’importe quoi.
Merci Robin et bien sûr les autres pour m’avoir aidé et avoir donné de votre temps. - What went wrong: