December 06, 2021, 02:29:41 am

The Gang Garrison 2 Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

NOTICE: Due to a rise in bot activity, new posters need to be approved before posting.

Join the community Discord server!

Pages: [1]

Author Topic: [CSP] Emote Chat  (Read 1621 times)

BasedUser

  • Junior Member
  • **
  • Karma: 9
  • Offline Offline
  • Posts: 59
  • Fairô and Balancedô
[CSP] Emote Chat
« on: August 22, 2020, 12:56:37 pm »

EMOTE(bubble) CHAT

Have you ever wanted to talk to your teammates, but your server host or version doesn't have the chat plugin installed(-able)? Fear not, for this plugin solves your problems.

Using an extremely minimal UI and a simple protocol you can transfer binary data, or rather, TEXT, magically over to other people using this plugin!
  • How does it work?
Simple, really. Every character (assuming you're ANSI-compliant) uses a byte for storage, and this includes some non-ASCII characters, like Í and ё. Although there are a whopping 61 (62) emotes in the game, the plugin uses only 32 (aside from the header) to transfer 5 bits at a time instead of using base58 encoding that would bring a mathematician to joy, because I'm too dumb for that shit.
UTF-8 characters just get split up and sent over the network with no reassembly whatsoever (someone might implement this later).
  • What are the controls?
Press Y to start typing. Press enter to submit the message. Press F11 to stop being able to transmit messages, however you can still receive them (helps with the various serversent chat plugins).
You can also configure the size and position of emotechat by changing variables inside of the plugin.


This plugin is in an open beta. It could stand by every time you're in a server with a variation of chat, waiting for a F11 to toggle itself!

KNOWN BUGS:
* Hosts can't interact with emotechat (requires modification of GameServer/processClientCommands)
* Interferes with chat/chatv2's window, usually forces priority onto itself (press F11, rebind chatv2 or the plugin)

 :yaymoney: :z9: :c1: :detonatortaunt: :quote: :x29: :x15: :curly: :x11: :x15: :x24: :z6: :z4: :x27:

Current contributors:

  • me
  • Orpheon, for reminding me that GML isn't as bad as ANSI C
  • PrOF, double checked the decoder

« Last Edit: July 25, 2021, 03:59:03 pm by BasedUser »
Logged
Overconfident? That's me.

Quote from: discord
Sans: I wanted to play something but I forgot what it was
Beryllium: gg2

BasedUser

  • Junior Member
  • **
  • Karma: 9
  • Offline Offline
  • Posts: 59
  • Fairô and Balancedô
Re: [CSP] Emote Chat
« Reply #1 on: July 25, 2021, 04:01:28 pm »

Revision 1

- Fixed a bug where all chat activity would suddenly jump offscreen
- Fixed a bug on some machines where all chat activity would be aligned to the middle
- Fixed the text input box going outside of chat box
- Fixed chat box showing too much lines of text (though it may still do that)
Logged
Overconfident? That's me.

Quote from: discord
Sans: I wanted to play something but I forgot what it was
Beryllium: gg2
Pages: [1]
 

Page created in 0.03 seconds with 50 queries.