#bitfighter IRC Log

Index Search ←Prev date Next dateβ†’

IRC Log for 2020-06-09

Timestamps are in GMT/BST.

06:41:46BFDiscordBridge<raptor> using mDebugObjectSizes helps you verify you are handling your network data properly. if pack/unpack does not match, then that means you did not code/decode the same number of bits in a particular net object
06:43:26BFDiscordBridge<raptor> I don't know about the EventConnections
08:41:51BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> Well, I manage to get more information by outputting endingPosition and getBitPosition()
08:41:58BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> It expected 417 bits and I read only 190.
08:42:12BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> By looking thru the code, I've receive 53 bytes
08:42:28BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> 53 bytes however, is 424 bits
08:42:53BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> so I'm not entirely sure. Could it be strings are variable bits?
08:49:39BFDiscordBridge<raptor> strings are variable - they use StringTableEntry or raw strings (huffman processed)
08:55:40BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> I see.
08:56:15BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> Damn. This can be problematic because I'm not sure if it is U32, U32, StringTableEntry or U32, StringTableEntry, U32.
08:56:41BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> outputting just binary makes text not easily recognizable due to huffmann encoding...
08:56:47BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> i wish it was ascii... 😦
08:58:08BFDiscordBridge<raptor> the secret is always in the pack vs unpack methods
08:58:25BFDiscordBridge<raptor> both will use STE or huffman string
09:08:28BFDiscordBridge<raptor> the pack/unpack methods must be symmetrical
09:26:12BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> Sorry what is the difference. I thought STE is a huffman string
09:34:27BFDiscordBridge<raptor> a STE is just a number - both server/client keep a list of Strings (huffman encoded) where the index in the list can be passed from server to client
09:35:03BFDiscordBridge<raptor> so common game messages are stored in this way, but a chat message would not be
09:35:58BFDiscordBridge<raptor> so server might say to client: use STE #31, and the client will use that to look up the string in its copy of the string table
09:42:06BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> I'm sorry but isn't it you defined TableStringEntry testString and you read it by testString.getString()
09:42:06BFDiscordBridge<ChumpChange> Nice shooting @πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ! You just ranked up to level 3 !
09:42:11BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> What do you mean #31?
09:43:29BFDiscordBridge<raptor> phaicm, yes that's correct, too
09:44:05BFDiscordBridge<raptor> you define a STE, and both client and server will both have a copy of identical string tables
09:44:24BFDiscordBridge<raptor> so to reduce network data, only the *index* of the STE is passed between client/server
09:44:38BFDiscordBridge<raptor> #31 is just an example index saying "go look up string at index 31"
09:45:35BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> How am I supposed to define TableStringEntry's normally?
09:46:19BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> The client send's a string (its a full string as in "123-abcdef") I can see it using huffmann encoding to process this string for sending the packet
09:46:25BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> would this be a case for TableStringEntry?
09:48:57BFDiscordBridge<raptor> no
09:49:03BFDiscordBridge<raptor> a STE is sent as just a number
09:49:11BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> Ah. So this is my mistake
09:49:38BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> what variable type should I be using instead? ByteDataPtr and do a manual readString()?
09:51:22BFDiscordBridge<raptor> you mean if it's not an STE?
09:53:13BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> yes.
09:53:18BFDiscordBridge<raptor> take a look here: https://github.com/bitfighter/bitfighter/blob/master/zap/TextItem.cpp#L335
09:53:32BFDiscordBridge<raptor> it calls bitstream->writeString()
09:53:44BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> I am also getting help from Torque3D community. They just explained that TableStingEntry sends the string for the first time.
09:53:50BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> then sends only the index.
09:53:55BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> afterwards.
09:53:57BFDiscordBridge<raptor> ah yes, that's right
20:23:26BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> Thanks for the advise. I managed to get my expected string to be read from my server
20:23:51BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> However, I kinda cheated since I don't know how to properly declare my arguments from TNL_IMPLEMENT_RPC
20:24:31BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> it seems it wrote the following parameters U32, U48, U16, TableStringEntry
20:24:52BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> since U48 is not a thing i cheated and did U32, U32, U32, TableStringEntry
20:24:58BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> since they are equivalent (bit wise)
20:25:17BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> do you know a dataType that is U48?
20:47:22BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> oh
20:47:26BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> C /// Packed representaion of an IPAddress. struct IPAddress { U32 netNum; ///< Address of the host in IP address format. U16 port; ///< Port field of the network address. };
21:34:34BFDiscordBridge<πŸ’œα΅–Κ°α΅ƒβ±αΆœα΅πŸ’œ> Yes this worked.

Index Search ←Prev date Next dateβ†’

These logs were automatically created by BFLogBot on irc.freenode.net.