Jump to content

Recommended Posts

Posted
1 minute ago, Choonster said:

The way you're sending the command chat message with EntityPlayerSP#sendChatMessage should work.

Wait Where i put the "String/Command in" does it suppose to be EntityPlayerSP.sendChatMessage?

for some reason i typed this:

EntityPlayerSP.sendChatMessage("hi")

in Eclipse it said it's an error? what's wrong?

Posted
Just now, Modder123 said:

Wait Where i put the "String/Command in" does it suppose to be EntityPlayerSP.sendChatMessage?

for some reason i typed this:

EntityPlayerSP.sendChatMessage("hi")

in Eclipse it said it's an error? what's wrong?

 

Your code was already calling the method correctly.

 

I use Class#member to refer to instance (non-static) fields and methods. I use Class.member to refer to static fields and methods.

 

EntityPlayerSP#sendChatMessage is an instance method, it needs to be called on an instance of EntityPlayerSP (i.e. Minecraft#hePlayer).

 

This is a basic Java concept.

 

 

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Posted

I don't understand it.... I type EntityPlayerSP.sendChatMessage("hi");

In eclipse it said it's an error but you're saying me it's not an error...

 

Ugh... im seriously confused.... 

 

maybe i should forget about this project.... or i dont know now...

like it soo confusing me eclipse saying an error in EntitySP.sendChatMessage("hi);

And i did import it.... I dont understand whats wrong...

Posted (edited)
18 minutes ago, Choonster said:

ClientTickEvent is an event just like KeyInputEvent, you subscribe to it in the same way. It's even fired on the same event bus (the FML bus).

I need do something like this:

MinecraftForge.EVENT_BUS.register(new ClientTickEvent());

? I putted the KeyInPut one in the preInit Event.

Edited by Modder123
i did submit it by accident
Posted
9 minutes ago, Modder123 said:

I don't understand it.... I type EntityPlayerSP.sendChatMessage("hi");

In eclipse it said it's an error but you're saying me it's not an error...

 

I'm saying that is an error, but your original code (on Pastebin) didn't have that error.

 

You're trying to call the method on the class as if it were a static method, but it's not a static method so you need to call it on an instance of the class instead.

 

 

8 minutes ago, Modder123 said:

MinecraftForge.EVENT_BUS.register(new ClientTickEvent());

 

In 1.8, ClientTickEvent (as with all events in net.minecraftforge.fml packages) is fired on the FML event bus (FMLCommonHandler#bus), not the Forge event bus (MinecraftForge.EVENT_BUS). You need to register your event handler on the FML event bus to handle ClientTickEvent.

 

In 1.8.9+, the FML event bus has been merged into the Forge event bus, so all events that were previously fired on the FML event bus are now fired on the Forge event bus instead and the FMLCommonHandler#bus method has been deprecated.

 

 

1 minute ago, Modder123 said:

it saying I need to Add a Phase? for what the Phase is?

 

Each subclass of TickEvent (including ClientTickEvent) is fired twice per tick of its corresponding system (server, client, world, player or render), once at the beginning with Phase.START and once at the end with Phase.END.

 

If you don't check for a specific Phase, your code will run twice per tick instead of once.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Posted (edited)
29 minutes ago, Modder123 said:

but oh well.... i guess i'm not the right person for this kind of coding stuff.....

 

Modding requires a solid understanding of Java and OO programming. Spend some time learning the basics of these and you'll find modding a lot easier.

Edited by Choonster

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Posted
2 hours ago, Choonster said:

 

Modding requires a solid understanding of Java and OO programming. Spend some time learning the basics of these and you'll find modding a lot easier.

Yeah i know, I know some Simple / Basic Java Stuff My only problem is OOP D: it's really confusing :(

 

  • 2 years later...
Posted (edited)

I appear to have the same problem (or close) to what you people are talking about. however, this is the message I get:

 

[Error] FML appears to be missing any signature data. This is not a good thing.

 

------

 

So I'm using a premium account but I also get more messages from the console relating to FML. In standards, i feel that a certain batch file or somehow getting my signature data to be linked to forge from FML would solve this. Although i dont really think a batch file would fix that issue because FML is nothing related to a batch. btw heres a batch below that I did. Its not really an advanced batch.

 

java -server -Xmn512M -Xms1024M -Xmx1024M -jar forge-1.12.2-14.23.5.2844-universal.jar -0 nogui
pause

 

Edited by RyletXela
had to fix batch
  • Guest locked this topic
Guest
This topic is now closed to further replies.

Announcements



×
×
  • Create New...

Important Information

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