TheBrokenRail
TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-29 10:23:54 +00:00
Port over most of the RaspberryJuice API

If both ProjectileEvent and ChatEvent have a sender ID and an invalid flag, why not create a base class they both inherit from? Then you could make a generic version of getProjectileHits and getChatPosts, rather than having two mostly identical functions.

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-29 10:23:54 +00:00
Port over most of the RaspberryJuice API

Also, all these methods and variables should be static.

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-29 10:23:54 +00:00
Port over most of the RaspberryJuice API

What about messages not sent by the local player? I maintain it would be better to track this server-side, especially aince you could also track the sender's ID

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-29 10:23:54 +00:00
Port over most of the RaspberryJuice API

This could probably be a dedicated clear() method.

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-29 10:23:54 +00:00
Port over most of the RaspberryJuice API

Forgive the typos, I typed this on my my phone while in bed.

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-28 00:23:36 +00:00
Port over most of the RaspberryJuice API

Oh, one last thing! On RJ, does events.chat.posts include the <username> in messages? Because as it is, this PR does. (I really need to find an old enough version of Bukkit and try out RJ…

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-28 00:18:58 +00:00
Port over most of the RaspberryJuice API

OK, I have a few more requests (I promise, this is the last time!):

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-27 07:35:01 +00:00
Port over most of the RaspberryJuice API

Yes, there's already a Base64 encoder in the skin mod. It shouldn't be too difficult to create misc/base64.cpp and add an encoder.

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-27 07:34:07 +00:00
Port over most of the RaspberryJuice API

Oh my, that is cursed. And correct me if I'm wrong, but you still wouldn't be able to type ,s right, it would just replace them with ;?

TheBrokenRail pushed to master at minecraft-pi-reborn/minecraft-pi-reborn 2024-10-27 04:56:33 +00:00
e6deab9664 Fix Headless Bug
TheBrokenRail pushed to master at minecraft-pi-reborn/minecraft-pi-reborn 2024-10-26 22:03:26 +00:00
69fcc6cdb3 800th Commit! Regenerating gui_blocks And Performance Fixes
TheBrokenRail pushed to master at minecraft-pi-reborn/runtime 2024-10-26 22:03:11 +00:00
377f9ddbc4 Update header
TheBrokenRail pushed to master at minecraft-pi-reborn/minecraft-pi-reborn 2024-10-26 06:00:26 +00:00
251fc1d1ea 800th Commit! Regenerating gui_blocks And Performance Fixes
TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-23 17:02:23 +00:00
Port over most of the RaspberryJuice API

Pretty sure it's still recursive. MC calls Gui::addMessage which gets re-routed to Gui_addMessage_injection which calls the original which then calls Gui::addMessage which gets re-routed to…

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-23 14:42:51 +00:00
Port over most of the RaspberryJuice API

Uh, the recursion check is actually pretty important...

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-23 14:42:51 +00:00
Port over most of the RaspberryJuice API

You can use std::unordered_map::contains

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-23 14:42:51 +00:00
Port over most of the RaspberryJuice API

Wait a minute, if the API call is delineated by ,. Does that mean setting a sign to text including , is impossible?

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-23 14:42:51 +00:00
Port over most of the RaspberryJuice API

\ also has to be replaced with \\. Also maybe escaping chat messages should be its own function, since it's done twice?

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-23 14:42:51 +00:00
Port over most of the RaspberryJuice API

Wait why? Does ItemEntity not have an ID on Java or RJ?

TheBrokenRail commented on pull request minecraft-pi-reborn/minecraft-pi-reborn#116 2024-10-23 14:42:51 +00:00
Port over most of the RaspberryJuice API

Gui::addMessage calls itself recursively when wrapping, make sure to only store the parameters of the top call. (Also should this be converted to Unicode?)