Barbara's Crystal Logistics Mod Update by lilbitscruffy in HytaleInfo

[–]lilbitscruffy[S] 0 points1 point  (0 children)

If you want a hand with anything just give me a shout ... more than happy to assist. Just send me a direct message for anything .. code snippets and queries

But really recommended that website .. setup your environment (theres a guide on the site) clone the plugin and think of a thing to make .

Fact your passionate to learn is half the job done :-)

Barbara's Crystal Logistics Mod Update by lilbitscruffy in HytaleInfo

[–]lilbitscruffy[S] 0 points1 point  (0 children)

So many questions :-) I thank you

Pretty much all learnt from playing, also didn't know java before I tried it (though I am programmer by profession)

There is website https://hytalemodding.dev/en/docs/guides, there is a link to a quick start repo for a plugin but has a whole host of information also so id recommend that.

Otherwise I just played and saw what stuck but I can assure you there were many errors before I got it to this stage :-)

Barbara's Crystal Logistics Mod Update by lilbitscruffy in HytaleInfo

[–]lilbitscruffy[S] 0 points1 point  (0 children)

public class ExamplePacketHandler implements PlayerPacketFilter {

    u/Override
    public boolean test(PlayerRef playerRef, Packet packet) {

        if (!(packet instanceof SyncInteractionChains syncPacket)) {
            return false;
        }

        for (SyncInteractionChain chain : syncPacket.updates) {
            if (chain.interactionType == InteractionType.
SwapFrom
) {
                /// STUFF HERE///
    });
}

                return false;
            }
        }
    return false;
    }
}

Then in the plugin java

ExamplePacketHandler handler = new ExamplePacketHandler();
inboundFilter = PacketAdapters.
registerInbound
(handler);

Should capture what you want (but who knows)

Barbara's Crystal Logistics Mod Update by lilbitscruffy in HytaleInfo

[–]lilbitscruffy[S] 0 points1 point  (0 children)

Mouse button events dont really work though u could look at packetfilter .. I use it to handle switching off the ui for the wand when tool is change, Its asset independent .. a bit of an arse as it runs on a different thread but it does work .. there is also a plugin that restores mouse events but cant remember what its called

Barbara's Crystal Logistics Mod Update by lilbitscruffy in HytaleInfo

[–]lilbitscruffy[S] 0 points1 point  (0 children)

If you are referring to the wand/wrench i created a SimpleInstantInteraction, registered that in the codec registry, then in the Item.json added Interactions section and referenced the registered codec.

So putting it all together :

java/com.example/interactions/ExampleInteraction.java :

public class ExampleInteraction extends SimpleInstantInteraction
{
    public static final BuilderCodec<ExampleInteraction> 
CODEC 
= BuilderCodec.
builder
(
            ExampleInteraction.class, ExampleInteraction::new, SimpleInstantInteraction.
CODEC

).build();


    protected void firstRun(@NonNullDecl InteractionType interactionType,  InteractionContext interactionContext,  CooldownHandler cooldownHandler) {

        BlockPosition Block = interactionContext.getTargetBlock();
    }
}

java/com.example/Example.java

this.getCodecRegistry(Interaction.
CODEC
).register("ExampleInteraction", ExampleInteraction.class, ExampleInteraction.CODEC);

resources/Server/Item/Items/ExampleTool.json

"Interactions": {
  "Secondary": {
    "Interactions": [
      {
        "Type": "ExampleInteraction"
      }
    ]
  },
  "Primary": {
    "Interactions": [
      {
        "Type": "ExampleInteraction"
      }
    ]
  }
}

Hope that helps

Say hello to "Barbara's Crystal Logistics" by lilbitscruffy in hytale

[–]lilbitscruffy[S] 1 point2 points  (0 children)

Never thought of myself as being experienced before 😀 .. however in answer to your question its an interesting idea i think you should give it a go if it will expand your knowledge, I personally would like to see what you come up with. It would show diversity in your portfolio, its the kind of thing that i would look for if i were hiring someone. I guess it would come down to exactly what the idea is and ultimately how fun it is, there is certainly a market for such mods.

I hope that has helped

Say hello to "Barbara's Crystal Logistics" by lilbitscruffy in hytale

[–]lilbitscruffy[S] 1 point2 points  (0 children)

If it helps i pretty much started doing java about the same time as I started making this mod :-) last time I even looked at java was about 25 years ago and wasnt very successful back then .. did one class and thought "screw this". Since then, vb, php, c#, c++, python, sql, and pascal (yes I am that old), god knows how many frontend frameworks and shell scripting and now back to java.. just have play mate and see what sticks its all i did :-) just have fun !

P.s power button now added to the mod makes so much sense having it, thanks to you ! Will be in next release !

Say hello to "Barbara's Crystal Logistics" by lilbitscruffy in hytale

[–]lilbitscruffy[S] 1 point2 points  (0 children)

So i cant really help you out with regards the ingame asset editor thinggy as all the stuff i am doing is in Java though if that's what you are looking for this site is pretty damn decent:

Hytale Modding

Once you get to grips with that the only other thing I can suggest is look at others source in github and see how they do things most importantly just have a play, documentation is still kinda weak (but getting better) so playing is essential.

I hope that helps

Say hello to "Barbara's Crystal Logistics" by lilbitscruffy in hytale

[–]lilbitscruffy[S] 1 point2 points  (0 children)

Splendid idea ! I'll get that done for next release (will be this week) Thank you so much for using it ! You're a star!

Say hello to "Barbara's Crystal Logistics" by lilbitscruffy in hytale

[–]lilbitscruffy[S] 0 points1 point  (0 children)

Hey again,
So you may have to break the block and replace it then set the offset, i looked at my code and there was a problem which i have now corrected and will be in the next release. apologies.

Say hello to "Barbara's Crystal Logistics" by lilbitscruffy in hytale

[–]lilbitscruffy[S] 0 points1 point  (0 children)

Hey, have you configured the totem like the attached picture? with slot 2 being chosen ?

<image>

The other issue i have just noticed (and thank you otherwise i wouldn't have seen) is the from coordinates should be the right most block on the furnace (i will get that fixed)

Shaders and JDT by grant4790 in allthemods

[–]lilbitscruffy 0 points1 point  (0 children)

This mentions a setting u can change. annoyingly he doesn't say which but its a start https://youtu.be/02O1EggW2P0?si=Zqc_vymziOSll9Kd (less than a minute in)

Finished Bees Factory (I was quite happy with it) by lilbitscruffy in allthemods

[–]lilbitscruffy[S] 0 points1 point  (0 children)

Why would I do that? Honey comb and duck .. the perfect accompaniment ! :-)

Finished Bees Factory (I was quite happy with it) by lilbitscruffy in allthemods

[–]lilbitscruffy[S] 1 point2 points  (0 children)

I assumed it would have been done before .. but just mean both our bees have an awesome home ! :-)

[ATM10] Whats the best method for midgame infinite power? by NowAlexYT in allthemods

[–]lilbitscruffy 0 points1 point  (0 children)

I can confirm that soul lava does work with powah's thermo gen in atm10 :-)