Closed goottime closed 2 months ago
Since raknet callbacks are not registered by default, all rpc and packets are blocked. your need to complete the raknet environment.
this is @infernus/create-app
cli tool issue, I will fix it later.
try using the latest @infernus/create-app
, note that pnpm may cache the dlx command package, which cannot be cleaned with pnpm cache clean
.
You may need to manually clear C:\Users\YOUR_USER_NAME\AppData\Local\pnpm-cache\dlx
.
import { onIncomingPacket, onIncomingRPC, onOutgoingPacket, onOutgoingRPC } from "@infernus/raknet";
onIncomingPacket(({ next }) => {
return next()
})
onIncomingRPC(({ next }) => {
return next()
})
onOutgoingPacket(({ next }) => {
return next()
})
onOutgoingRPC(({ next }) => {
return next()
})
I tried to install everything according to the documentation. But the gamemode refuses to work, there is a connection to the server, but no further actions are performed, although the infernus-starter gamemode should be executed. I also discovered that game events are not being processed or executed. I added a log to OnPlayerConnect, but it did not appear when connecting to the server. The message is only displayed when OnGamemodeInit and also when OnPlayerDisconnect I received an error.
To install and run I used the following commands:
pnpm dlx @infernus/create-app create
cd projectname
infernus install
pnpm install
pnpm dev