Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

Hey,

 

I tried to find out how to send a console command as server with MinecraftServer.getServer().getCommandManager().executeCommand(...),

so that the ICommandSender isn't a player...

I tried making my class an instance of ICommandSender and using "this" but that didn't work.

Also I tried using my main class or using MinecraftServer.getServer().

 

MinecraftServer.getServer().getCommandManager().executeCommand(MinecraftServer.getServer(), "say " + player.getDisplayName());

So whats wrong here?

 

Could you help me so I can send server commands like "/say" with a mod?

 

Thanks :D

  • Author

Okay... the command seems to be sent now (didnt change anything at all)

 

but the console always returns that the command is not known... even "say" or "help"...

  • Author

MinecraftServer.getServer().getCommandManager().executeCommand(MinecraftServer.getServer(), "help");

Am I just stupid or whats wrong? D:

  • Author

So I also tried in the Main class during preInit event but still

[23:05:58] [server thread/INFO]: Unknown command. Try /help for a list of commands

 

while simply doing:

 

MinecraftServer.getServer().getCommandManager().executeCommand(MinecraftServer.getServer(), "help");

 

please help :(

  • Author

I'm sorry...

 

I did it exactly your way... still didn't work

 

And I'm using cauldron 1.7.10... could that be the problem?

No, you don't understand.  Cauldron is so dead, it is not being developed any more, not even for 1.7.10.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Guest
This topic is now closed to further replies.

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.