Jump to content

Kinniken

Members
  • Posts

    266
  • Joined

  • Last visited

Posts posted by Kinniken

  1. Hi all,

    I was recently trying to setup my mod's dev environnement again, and the same build script that worked just fine last time I used it a few months ago is now failing with the error below:

     

    FAILURE: Build failed with an exception.
    
    * What went wrong:
    Could not resolve all dependencies for configuration ':forgeGradleUserDevPackage'.
    > Could not resolve net.minecraftforge:forge:1.12.2-14.23.5.2768.
      Required by:
          org.millenaire:Millenaire:7.0.0-beta.5
       > Could not resolve net.minecraftforge:forge:1.12.2-14.23.5.2768.
          > Could not get resource 'https://files.minecraftforge.net/maven/net/minecraftforge/forge/1.12.2-14.23.5.2768/forge-1.12.2-14.23.5.2768.pom'.
             > Could not GET 'https://files.minecraftforge.net/maven/net/minecraftforge/forge/1.12.2-14.23.5.2768/forge-1.12.2-14.23.5.2768.pom'.
                > sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
    

     

    The URL given works fine when tested in Chrome.

     

    Anybody has any idea about this issue? Something linked to a system update maybe?

     

    Thanks

  2. 47 minutes ago, Cadiboo said:

    This is exactly WHY you should use JSON, they will add their villages with JSON.

     

    I'm arguing for JSON advancements because thats the standard (How vanilla does it). If you want to use another method just make sure that it will support data packs etc.

    As a general rule you are right, in this case it just doesn't make sense. I already have a dynamic system to add content to my mod that's flexible and works well. In this new feature content discovered by the player, whether my own or added by other creators, will get tracked in a new UI, automatically, with no extra work for content creators. Having the advancement part being static in JSON is just more work for people, and if they don't do it, will lead to inconsistencies (my UI and the advancement system reporting different numbers).

    Also you are thinking of mod pack makers. That's one use case but not the main one for me. I have a lot of user-created content that can be downloaded and installed separately by players (check the site: https://www.millenaire.org/library/ and yes I know it needs a solid UI update ;) ). Independently each of them could override advancements with their extra content, but what happens when the player wants to add more than one?

    Lastly thinking about it thanks to this discussion, there is the matter of updates. I've always tried hard to keep Millénaire as backward compatible as possible with outside content. If I do this JSON thing, it means that outside content that override my advancements won't include villagers and buildings added by later updates to the mod. That's really a killer.

    I would have liked to have those neat looking progressive advancements but after all these discussions I think the impact on content creators just isn't worth it. I'll just grant them straight when the player has finished the list.

  3. If there's no option but that I guess I'll go with it. But really that focus on outside edits is a bit beside the point, once again these new advancements will be tied to hard coded features, this is not something mod pack makers would venture in. On the contrary, having those advancements containa statically defined list of my villagers is bad for external content creators as it means that their villagers won't get auto-included.

     

    Plenty of stuff in my mod can be changed without touching the code, in fact it's possible to add entire new cultures with their own villagers and buildings and quests without touching a line of Java. It's a lot more open that Minecraft itself in that respect. But for this feature it's just beyond the point.

  4. My mod adds villages (nothing to do with the vanilla ones) with a large number of different villager types, more than a hundred split over several cultures. And that list is moving from update to update - I add new ones regularly and occasionally remove some too. I wand to add advancements for meeting them all, probably split by cultures.

     

    If I do a trigger per villager type in JSON, it will be a nightmare to maintain, except if I generate the JSON from code, which is doable but ugly.

     

    Alternatively, I can forgot about the "partial progress" bar and just grant the advancement when the player has completed the list, that's easy to do from the code.

  5. I know how the format works, that's not my issue.

     

    However for what I want to do I would need dozens of triggers, with more added every time I add content. It would be a real pain to do this manually. If there is no better way, I guess I'll have to choose between handling it code-side without showing intermediary progress or coding a bit of code that generates the JSON from my mod's data, but that's really clunky.

  6. Hi,

     

    I would like to add to my mods some "multi-step" advancements, like the vanilla "balanced diet" one. Is this doable without having to add every "step" in the JSON file, in the same way that you can have single-step advancements with a custom trigger in the JSON that's actually handle code-size?

     

    If not I guess I'll have to write an advancement file generator ;)

     

    Thanks

  7. Some way of declaring an item obsolete so it neither generates warnings in old worlds nor get added to the registry of new worlds I guess.

     

    "it will always tell the player about that and there is no way around that nor should there be."

     

    If that is indeed the case then I have no choice... Ah well, would have been nice not to have to chose between keeping my code clean and scaring users with nasty-looking warnings.

     

  8. Oh and on this:

    "Note that you're not actually reusing the GuiScreen object - the sub-GUI is a separate object which exists at the same time as the parent GUI." 

     

    Sorry, I wasn't clear, I meant that I'm reusing the GuiScreen object from my original parent screen display to display it again once the second screen is closed. Between the parent screen and the child one it's not possible of course, they are not even instances of the same class in my case.

  9. onGuiClosed() looked like what I wanted... except that it's called from within displayGuiScreen() before the new GUI is set, so if I call displayGuiScreen() from within it my resetting of currentScreen gets overiden by the parent call.

     

    I don"t like the solution much but I went with putting my code in an overriden keyTyped(), that works fine.

     

    Thanks for the help.

  10. I can reuse the same GuiScreen object? Convenient, cool.

     

    Is there any callback for when a GUI is closed? I can't seem to find any at least for when the GUI is closed by using the escape key. The only solution I can see would be to override keyTyped() and reopen the older gui if I detect that the key pressed was escape, but that feels very hacky...

  11. Hi all,

     

    I would like to know if there is a good way to make blocks and items "obsolete" in new versions of a mod. As far as I know there are two ways of dealing with this:

    - Delete them from the mod. The cleanest, but popups an ugly-looking warning to players who upgrade existing worlds.

    - Keep them in the mod, but make them unavailable. That avoids the issue above but then the mod is stuck with dead items/blocks for ever, removing them later just ends up with the same issue as in the first option.

     

    Any better option?

     

    Thanks

  12. Hi all,

     

    I have two GUIs, one that extends GuiContainer to handle trade in my mod, and one with some user help that extends GuiScreen directly. There's a help button on the trade one that opens the other one, using Minecraft.getMinecraft().displayGuiScreen().

     

    It works fine, except that opening the help closes the other one. I'd prefer it if the player was taken back to the other one instead. Is this possible "natively", or do I need to do it manually by reopening the first GUI with whatever context it had?

     

    Thanks

  13. Thanks, that worked fine.

     

    For the stretching issue, it seems like drawEntityOnScreen() "assumes" that the target texture has the same size as the screen, and since in your example it was 256x256 instead, it scaled the output to that. I changed the size settings the following way:

     

    final int width = Minecraft.getMinecraft().getFramebuffer().framebufferTextureWidth;

    final int height = Minecraft.getMinecraft().getFramebuffer().framebufferTextureHeight;

     

    And I get an output whose proportions are fine, but of course whose size matches the screen which is not what I want. I'm guessing I need to adjust the matrix then? Any hint or doc on this?

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.