@xx_amaba_xx/robloxbot 0.3.0 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +21 -13
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -46,12 +46,12 @@ Control a Roblox character through the headless RakNet protocol with a working w
46
46
  | Leave game | ✅ Web transport |
47
47
  | Find public servers | ✅ Web transport |
48
48
  | List friends | ✅ Web transport |
49
- | Walk / jump | ⚠️ Stubbed (RakNet not implemented) |
50
- | Chat / whisper | ⚠️ Stubbed (RakNet not implemented) |
51
- | Character state (spawn, health, position) | ⚠️ Stubbed |
49
+ | Walk / jump | ✅ RakNet transport |
50
+ | Chat / whisper | ✅ RakNet transport |
51
+ | Character state (spawn, health, position) | ⚠️ Partial (local + server sync) |
52
52
  | VLM/LLM image understanding | ✅ HTTP service |
53
53
  | YOLO object/player detection | ✅ HTTP service |
54
- | Headless (no Roblox client needed) | ✅ RakNet transport stub |
54
+ | Headless (no Roblox client needed) | ✅ RakNet transport |
55
55
  | Termux / Android compatible | ✅ No native Node modules |
56
56
 
57
57
  ---
@@ -166,7 +166,7 @@ await bot.joinFriend("FriendOne");
166
166
 
167
167
  `joinFriend` looks up the username in your friends list (case-insensitive) and joins them via the Roblox `FollowUser` protocol. Throws if the username isn't in your friends list.
168
168
 
169
- ### Movement (stubbed)
169
+ ### Movement (RakNet)
170
170
 
171
171
  ```js
172
172
  await bot.walk("f", 2); // walk forward 2 seconds
@@ -177,16 +177,24 @@ await bot.walkRight(2);
177
177
  await bot.jump(3, 0.5); // jump 3 times, 0.5s between
178
178
  ```
179
179
 
180
- > ⚠️ These are stubs. They log a warning and return a result object without sending anything, because the RakNet packet spec isn't implemented yet. See [Roadmap](#roadmap-known-ceilings).
180
+ Movement sends `ROBLOX_MOVEMENT_UPDATE` (0x88) packets via RakNet transport with position, velocity, cframe, moveDirection, isGrounded, isJumping, and walkSpeed. Requires active game server connection (`bot.start()`). Throws if transport not connected.
181
181
 
182
- ### Chat (stubbed)
182
+ Default walkspeed: 16 studs/s. `jump` sends two packets per jump (up + land) with proper physics state.
183
+
184
+ Returns `{ direction, duration, distance, position, sent: true, simulated: false }` or `{ count, interval, position, sent: true, simulated: false }` for jumps.
185
+
186
+ ### Chat (RakNet)
183
187
 
184
188
  ```js
185
189
  await bot.chat("Hello world!");
186
190
  await bot.whisper("FriendOne", "Hey there!");
187
191
  ```
188
192
 
189
- > ⚠️ Stubbed — same limitation as movement.
193
+ Chat sends `ROBLOX_CHAT_MESSAGE` (0x90) packets via RakNet transport. Requires active game server connection (`bot.start()`). Throws if transport not connected.
194
+
195
+ `whisper` uses channel 2 (whisper channel). Target userId resolution not yet implemented.
196
+
197
+ Returns `{ message, sent: true, simulated: false }` or `{ message, to, sent: true, simulated: false }` for whispers.
190
198
 
191
199
  ### Events
192
200
 
@@ -671,12 +679,12 @@ src/
671
679
  utils.js # loadEnv, sleep, buildRobloxUri
672
680
  transport/
673
681
  base.js # Transport ABC interface
674
- raknet.js # RakNet headless skeleton (encode/decode + stubs)
682
+ raknet.js # RakNet transport (UDP, handshake, framing, ACKs)
675
683
  web.js # Roblox web API (real implementation + fetch)
676
684
  core/
677
685
  character.js # Character state tracking
678
- movement.js # Walk/jump (stubbed over transport)
679
- chat.js # Say/whisper (stubbed over transport)
686
+ movement.js # Walk/jump (RakNet transport)
687
+ chat.js # Say/whisper (RakNet transport)
680
688
  game_join.js # joinGame/joinUser/joinFriend/joinServer/leaveGame/findServers/listFriends
681
689
  plugins/
682
690
  auto-reconnect.js # Auto-reconnect with exponential backoff
@@ -702,7 +710,7 @@ src/
702
710
 
703
711
  | Problem | Impact | Workaround |
704
712
  |---------|--------|------------|
705
- | **Walk/jump/chat don't reach the game** | RakNet transport is a skeleton — `connect()`/`send()` throw `NotImplementedError`. Local simulation updates `bot.character.position` but nothing reaches Roblox. | Reverse-engineer RakNet protocol, implement socket+handshake in `src/transport/raknet.js`, fill `src/constants/packets.js` with real field layouts. |
713
+ | **Walk/jump/chat send packets (packet formats need validation against real traffic)** | RakNet transport implemented — UDP socket, handshake, framing, ACKs. Packet structures are educated guesses from community reverse-engineering; need validation against real captures. | Validate packet structures by capturing real Roblox traffic; update `PACKET_FIELDS` in `src/constants/packets.js` accordingly. |
706
714
  | **Character state not populated from game** | `spawn`, `health`, `position` come from local simulation, not server packets. | Implement RakNet receive loop that decodes player spawn/movement packets into `bot.character.update()`. |
707
715
  | **No real entity positions** | `bot.entities` only tracks manually added entities. Other players' positions aren't received. | Implement RakNet player join/leave/movement packet handling. |
708
716
  | **No real inventory** | `bot.inventory` only tracks manually added items. | Implement RakNet inventory packets or Roblox inventory web API calls. |
@@ -718,7 +726,7 @@ src/
718
726
  | Item | Plan |
719
727
  |------|------|
720
728
  | RakNet packet spec | Reverse-engineer from real client traffic; fill `packets.js` field layouts |
721
- | Real walk/jump/chat | Implement RakNet socket + framing; `movement.js`/`chat.js` already structured to send packets |
729
+ | Real walk/jump/chat | ✅ Implemented — sends 0x88/0x90 packets. Need packet validation against real traffic. |
722
730
  | Real entity tracking | Wire RakNet player packets into `entities.js` |
723
731
  | Real inventory | Wire RakNet inventory packets or web API into `inventory.js` |
724
732
  | Plugin marketplace | Document `npm install` pattern for third-party plugins |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xx_amaba_xx/robloxbot",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "A mineflayer-style headless Roblox bot library for Node.js/Termux",
5
5
  "main": "src/index.js",
6
6
  "type": "module",