Refactor: NPC perception rules out of AiHandler, split NpcAiService / NpcHelperService
Los mantenedores suelen responder en 2 días
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 35/100
Línea de trabajo
Start with the design skill and the review findings A3 and A4 from split/09-perceptions; then trace perception handling across AiHandler, NpcAiService, and NpcHelperService. Map the proposed service responsibilities and Reflex registration before implementation. Done means the responsibilities are moved as described with no behavior change; the performance notes are optional.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Follow-up from the review of split/09-perceptions (architecture-reviewer findings A3 + A4).
Problem
AiHandler(adapter, ~720 lines) decides AI rules: loop rate, daily-state check,CallStateEnd, looking away
(ForgetHeroAfterLookingAwaychangesAttitudeTemp),PERC_MOVENPC,PERC_ASSESSBODY. None of it is testable
without a scene, and following one perception means reading AiHandler, NpcAiService and NpcHelperService.NpcAiService(~1,100 lines) andNpcHelperService(~620 lines) each took on a new responsibility: passive
perception broadcast/delivery, the body search, sight lines through alpha-tested polygons,Wld_DetectItem.
Proposal
NpcPerceptionService(new): passive perception broadcast + delivery,ExecutePassivePerception,
FindClosestSensedBody, and the body ofExecuteActivePerceptions(incl.PERC_MOVENPC,PERC_ASSESSBODY,
looking away).NpcSightDomain(new, owned byNpcHelperService):CanSee/CanSense,IsSightBlocked, see-through caches.NpcAiServicekeeps the state lifecycle and also getsCallStateEnd, the loop-rate and daily-state checks.AiHandlerkeeps only the Unity part:_npcPerceptionService.TickPerceptions(NpcData)and the state calls.Wld_DetectItemand the item distances could move to aWld_*/item service.
Plan with the design skill first (new service + Reflex registration), then implement. No behaviour change.
Related performance notes from the same review (can be done during the move):
FindClosestSensedBodywalks the whole NpcCache with a raycast per candidate on every perception tick.Wld_DetectItemwalks the whole VobCache per call.
- Lenguaje dominante
- C#
- Estrellas
- 33
- Forks
- 1
- Merge medio
- 1 d 21 h
- PR fusionados (30 d)
- 56
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de Gothic-Unity-Project/Gothic-Unity
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 69/100
Gothic-Unity-Project/Gothic-Unity#487 ·
Los mantenedores suelen responder en 2 días
-
bug
Dificultad 3/5 1-2 días Aptitud para principiantes 57/100
Gothic-Unity-Project/Gothic-Unity#494 ·
Los mantenedores suelen responder en 2 días
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 49/100
Gothic-Unity-Project/Gothic-Unity#489 ·
Los mantenedores suelen responder en 2 días
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 42/100
Gothic-Unity-Project/Gothic-Unity#488 ·
Los mantenedores suelen responder en 2 días
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 55/100
Gothic-Unity-Project/Gothic-Unity#486 ·
Los mantenedores suelen responder en 2 días
Todos los issues de Gothic-Unity-Project/Gothic-Unity
Issues similares
-
bug github_actions
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
endercodezz/BYDLO#336 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
sebastienros/jint#4449 ·
Los mantenedores suelen responder en 1 día
-
clawsweeper:bulk-filed clawsweeper:needs-security-review clawsweeper:no-new-fix-pr clawsweeper:source-repro impact:security issue-rating: 🦞 diamond lobster P2
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
openclaw/openclaw-windows-node#2010 · 2 comentarios · 1 reacción ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 77/100
imazen/imageflow-dotnet#72 · 1 comentario ·