thegrb93 / StarfallEx

Starfall, but with active development and more features. Write Garry's mod chips similar to E2, but in lua
https://discord.gg/yFBU8PU
Other
199 stars 111 forks source link

#1889 instances not deinitializing when they're supposed to #1892

Closed yingKatsu closed 4 days ago

yingKatsu commented 1 week ago

1889

most likely fullupdate related Untitled

thegrb93 commented 1 week ago

Is that in clientside or serverside or both?

NullLikesNothing commented 1 week ago

@thegrb93 It happens client-side as indicated by the screenshot.

Starfall '...' errored for player [redacted] Player disconnected!

Server-side wouldn't have this happen unless the client actually left the game

yingKatsu commented 1 week ago

yup clientside. i see my code erroring for people in this way when they experience lag spikes (someone loading a megapac) and their game freezes a sec, which is why im pretty sure its fullupdates again

thegrb93 commented 1 week ago

See if https://github.com/thegrb93/StarfallEx/pull/1893 fixes it

Advers commented 4 days ago

Still happens sometimes. Just happened to me a minute ago. Seemed to happen while the user was initializing or just after

Advers commented 4 days ago

nevermind, it just seems to be PVS or fullupdate dependent

thegrb93 commented 4 days ago

We need player entities to be always_transmit I think. The fact they go invalid and don't exist for other clients is just crazy.

thegrb93 commented 4 days ago

I think its something to do with source engine's anti-cheating

thegrb93 commented 4 days ago

Actually, I have another idea that'll work

wrefgtzweve commented 4 days ago

players can be invalid after a full update, They're resynced by default every 10s lots of servers up that though

it's not a anticheat thing but a garry hack to fix something https://wiki.facepunch.com/gmod/Networking_Usage#svplayerforcedupdateissue

yingKatsu commented 3 days ago

https://cdn.discordapp.com/attachments/921945120167833613/1304905421676478524/2024-11-09_14-24-29.mp4?ex=67311760&is=672fc5e0&hm=56a59544d94a55f28a1e14dd850018c855c8bac7c13fda521ebeebdba63af4ac& latest version of gmod with only latest ver of starfall and dev library for sf

playerInstances table emptying itself for some reason.

my chips have been nonsensically "CPU Quota Reached!" erroring for a while now noticed that their quota tooltips were freezing and not updating. the reason why is because the quota is literally not being calculated bc the for loop that loops all instances is looping an empty table the instances still run and delete as normal

code used:


local print = print
local printTable = printTable
dev.setGlobal()

print(SysTime())
for pl, insts in pairs(SF.playerInstances) do
    for instance in pairs(insts) do
        print(pl, instance.entity)
    end
end
thegrb93 commented 3 days ago

@yingKatsu can you open a new issue and tell how to make that happen?

thegrb93 commented 3 days ago

Nevermind, it was actually easy to reproduce

thegrb93 commented 3 days ago

@yingKatsu fixed now