Skip to content

Commit

Permalink
add missing playerConnect emit to client (dev.playersReconnect)
Browse files Browse the repository at this point in the history
  • Loading branch information
xxshady committed Jun 25, 2024
1 parent 4e6594c commit 75c3afe
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/altv-inject/server/setup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -343,6 +343,10 @@ export class ServerSetup {

sharedSetup.emitAltEvent<"server_baseObjectCreate">("baseObjectCreate", p)
sharedSetup.emitAltEvent<"server_playerConnect">("playerConnect", p)

_alt.Player.all.filter(player => player !== p).forEach(player => {
(player as unknown as alt.Player).emitRaw(CLIENT_EVENTS.playerConnect, p)
})
})
.catch(e => {
this.log.error(e.stack)
Expand Down

0 comments on commit 75c3afe

Please sign in to comment.