userDaniel Pcancel

1,979 Commits over 488 Days - 0.17cph!

Today
Update: apped hex prefix when emitting native method address Tests: none, trivial change
Today
Update: emit address of native function Trying to chase up why sometimes names missmatch with what VS disassembly window shows Tests: viewed BasePlayer::BoxTest
Today
Bugfix: use mnemonics instead of bytes when checking if decoding should finish My initial attempt to inpsect raw opcode didn't work in all cases, leading to false-positive parsing aborts. Tests: viewed BasePlayer::ServerUpdate and BasePlayer::BoxTest
Today
Update: better detection when to stop decoding stream - now tracks max referenced jump address and stops on last ret or jmp -offset Tests: viewed nested call in BasePlayer::BoxTest
Today
Bugfix: ensure instruction pointer gets saved to list only if we stopped parsing teh stream Previously we could add the ip to the list before we decided to stop decoding, leading to out of sync issues Tests: viewed BasePlayer::BoxTest
Today
Update: change asm text color if it's a potential address Tests: viewed BasePlayer::BoxTest
Today
Bugfix: avoid double-draw Tests: viewed BasePlayer::BoxTest
Today
Update: Add relative jump arrows This was much more painful than expected, but a bit of hodge-podge and it's gud Tests: viewed BasePlayer::BoxTest
Yesterday
Update: hook up native symbol resolution - ServerProfiler.Core built from 0b3b7d86 This gets us various mono_... calls, but still missing some function names - guessing those are mono-related but not part of mono dll itself Tests: Viewed BasePlayer::BoxTest and stepped through nested calls
Yesterday
Update: separate out JITViewer logic from ServerProfiler - ServerProfiler.Core built from 1074407d - also contains native symbol resolving logic, but not plugged in yet JITViewer functionality is now editor only(dll won't ship with builds). Tests: viewed BasePlayerr::BoxTest
Yesterday
Update: couple improvements to JIT viewer display - relative jumps are shown as "signed hex" offsets, to avoid jnz 0xffffffffffffffe cases - avoid duplication of address when we have a method name for a jitted address Tests: viewed BasePlayer::BoxTest and BasePlayer::ServerUpdateParallel
3 Days Ago
Clean: get rid of debug logs Tests: none, trivial change
3 Days Ago
Update: remember selecter row index between dissasm states Tests: viewed BasePlayer::BoxTest
3 Days Ago
Update: use consecutive int3s to stop decoding Doesn't always apply, but when it does saves a lot Tests: viewed BasePlayer::BoxTest
3 Days Ago
Update: allow inspecting instructions at address-like values Need to improve stream decoding in those cases, as it can run away to 12k lines of assembly even though the method was over on line 10. Tests: viewed BasePlayer::BoxTest
3 Days Ago
Clean: logic refactor in prep for multiple view support Tests: viewed BasePlayer::BoxTest
3 Days Ago
Update: resolve addresses to methods/trampolines where possible - ServerPorfiler built from 18130132 A bit ugly, but don't care for now Tests: viewed BasePlayer::ServerUpdateParallel
3 Days Ago
Bugfix: jump addresses are now valid - Also added ability to show opcode bytes - ServerProfiler built from 95cd43f7 Was due to invalid use of library API (I should've RTFMd) Tests: viewed BasePlayer::ServerUpdateParallel
4 Days Ago
Clean: remove binary dumping debug code Mystery byte was caused by fopen using "w" mode isntead of "wb", which allows windows to handle special characters. In our case it was injecting an extra byte that was screwing over jumps. But it was all debug code anyway. Tests: none, trivial change
4 Days Ago
Bugfix: treat instruction stream as 64bit, not 32bit - ServerProfiler built from 6c5c94dd Got mislead by Unity's mono --version reporting it as x86. Last bug left - an unexpected byte appearing mid instruction stream when copying from unmanaged, but missing on managed side Tests: viewed BasePlayer::ServerUpdateParallel
4 Days Ago
Bugfix: use ListView+labels intead of multiline TextField Fixes weird disappearing text and gets rid of the vertex limit for text Tests: viewed BasePlayer.ServerUpdateParallel
4 Days Ago
Update: display 32-bit disassembled instruction stream in editor window - ServerProfiler built from 5bff6c48 Couple weird issues - textfield goes invisible half-way through (but can copy the text out of it and goes back visible before end), binary stream differs between managed and unmanaged sides. Will chase up next Tests: viewed BasePlayer::ServerUpdateParallel
4 Days Ago
New: ServerProfiler can now dump raw binary of a managed method after JIT - using debug binary built from facc83cb Baby steps. No idea how to read it yet, and will need to explore how to control optimization levels. Tests: Exported Assembly-CSharp!BasePlayer::ServerUpdateParallel
8 Days Ago
Merge: from spectate_related_cmd_fixes - sleeping-/usersinrange commands now run from spectated player's position, if spectating Tests: used commands when spectating
8 Days Ago
Update: when running sleeping-/usersinrange, prefer to query from spectating target position Tests: used the commands while spectating
8 Days Ago
Merge: from spectate_command_fix - Bugfix for spectate doing nothing when spectating far-away player - Bugfix for error on respawn after spectate if previously didn't have a spectate target Tests: used spectate out of network range 10 times in a row, used keybind to spectate twice in a row - no issues
8 Days Ago
Bugfix: Spectating - when no valid spectator found when starting to spectate, ensure we still set the right SubStrategy - If no spectate targets were found, chat message now contains the used filter Could easily happen for people using keybinds, as keybind sends "spectate True" Tests: using keybind, spectated other player twice in a row - no more errors
8 Days Ago
Bugfix: Spectating - ensure Spectating flag always gets sent to the owner Fallout from the queue skipping optimization Tests: Went outside of network range, waited for subscription to unsub and and started spectating on a 2p server. Did it 10 times - no failures
9 Days Ago
Update: Adopt Scientist2FSM to be aware of ghostship navmesh Need to double check aiming logic (sometiems they aim at the sky), and investigate how initial on-navmesh spawning is done. Also need to convert variant FSMs Tests: spawned ship navmesh offset and with a rotation. Ran around into different areas of the ship and rooms - they pursued
9 Days Ago
Update: serverocclusiondebug - clarify what invalid grid means Now explicitly saying that server occlusion treats path with one or more invalid grid positions as unblocked Tests: none, trivial change
9 Days Ago
Bugfix: server occlusion - skip occlusion for players outside of the occlusion grid Tests: checked occlusion between y:90 and y:110 - previously would stutter(OcclusionV1) or would occlude(OcclusionV2). Tested hiding behind a hill - still works
9 Days Ago
Update: introduce BaseEntity.ServerNavMeshPos property and use it instead of the methods Incomplete work(need to expose transform matrices), will return after bugfixing Tests: none
10 Days Ago
Update: LimitedTurnNavAgent sets npc's position via helper functions - ScientistNPC2 overrides it to optionally map on to the detached navmesh if it's on a ghost ship - LimitedTurnNavAgent uses navmesh positions to calculate steering to waypoint in FaceTarget mode (think it was the original intent anyway) There's a bunch more code that needs to be converted just to be safe with strong waves Tests: spawned ghost ship away from craggy, enabled AI, and ran around to different areas - scientist caught up, were able to shoot me
10 Days Ago
Update: GhostShip spawns navmesh instead of NavMeshSurface - Disabled NavMeshSurface on GhostSHip prefab (will need to do it for the rest later) This stops NavMeshSurface constrantly running add-remove navmesh every server frame. Need to figure out how to tie it to NPCs Tests: visualzied navmesh in editor via gizmos, checked profiler to not see any more NavMeshSurface::UpdateActive calls
10 Days Ago
Merge: from baseplayer_serverupdateparallel - Optim for OcclusionV2 - remove extra hash lookup in a busy loop Tests: with UsePlayerUpdateJobs 2 - toggled invis in close proximity and far away, suicided away from spawn and flew back, teleported around
10 Days Ago
Optim: OcclusionV2 - skip resetting lastPlayerVisibility every frame Turns out didn't need to make the other half of changes Tests: used invis close and far away
10 Days Ago
Update: UseOcclusionV2 - simplify toggling invis - when enabling invis, notify occlusion tracking that we destroyed entity on subscriber's end - when disabling invis, skip sending snapshots - occlusion will handle it Halfway to remove the constant hashSet.Remove calls in GatherPairs loop Tests: UsePlayerUpdateJobs 2, toggled invis in front of player. went invis, flew outside network range, flew back, disabled invis - spawned correctly.
11 Days Ago
Merge: from baseplayer_serverupdateparallel - Bugfix for UsePlayerUpdateJobs 2 not replicating players for spectators - Bugfix for leaking players in occlusion groups Tests: spectated players from far away. Inspected server state after killing a sleeper
11 Days Ago
Bugfix: ServerOcclusion - clean up players from all of their occlusion groups on server destroy Turns out we were leaving a lot of "zombie" players once sleepers were killed. This would slow down server occlusion eventually. Tests: on Craggy, killed a sleeper, moved to a different network group, and checked in debugger if the occlusion group only contains my player
11 Days Ago
Bugfix: UseOcclusionV2 - handle spectating players Since we no longer do bidirectional checks when iterating occlusion groups, we ended up missing out on spectators and wouldn't allow replication to them. Tests: on craggy with UsePlayerUpdateJobs 2, flew far away to get outside of network range then started spectating - could see target moving.
11 Days Ago
Merge: from main
11 Days Ago
Merge: from spectate_dontfloodsnapshots - Bugfix for occlusion not destroying all players in UsePlayerUpdateJobs 2 mode Tests: 2p on craggy - used hill as obstruction, checked entity lists on both clients in editor
11 Days Ago
Bugfix: UsePlayerTasks - calculate end of batch correctly in SendEntityDestroyMessages_AsyncState This was causing server occlusion to skip sending some of destroy commands (from last batch), leaving a phantom player Tests: on Craggy went on behind hill, then checked editor entity list - confirmed that replicated players got removed on both ends
11 Days Ago
Merge: from main
12 Days Ago
Merge: from spectate_dontfloodsnapshots - Fixes spectate not working in UsePlayerUpdateJobs 2 case Tests: tried to spectate occluded player
12 Days Ago
Bugfix: Ensure initial player snapshot gets sent to spectator in UsePlayerUpdateJobs 2 case Tests: on craggy with UsePlayerUpdateJobs 2, took 2nd player behind a hill to occlude, then tried to spectate them - confirmed that the first snapshot got sent.
12 Days Ago
Merge: from main
15 Days Ago
Clean: post-submit feedback - rename entity_prefabId field to entity_prefab_id - rename AddShortEntity to AddShortEntityField More consistent with other examples Tests: compiles in editor
15 Days Ago
Merge: from analytics_entity_createdestroy - minor code clean Tests: editor compiles
15 Days Ago
Merge: from analytics_entity_createdestroy - we now collect entity spawn and destroy events once the server has started up (part of `gameplay_analytics` servervar) Tests: observed logs of analytics in CLIENT+SERVER editor