PathOfBuildingCommunity / PathOfBuildingCommunity/PathOfBuilding
Refactor `pathDist` variable to always be numerical
Nessuno ha ancora preso questa issue.
- Lingua principale
- Lua
- Stelle
- 5.4k
- Fork
- 2.4k
- Merge medio
- 1g 12h
- PR unite (30g)
- 26
Descrizione
The pathDist attribute is a bit of a mess. It can either assume the normal distance if there is a path, or some magic values (100, 1000, "Anoint", "Cluster"), depending on the circumstances. I'd recommend refactoring "Anoint" and "Cluster" to yet another two magic numbers to avoid having to check for the type of the attribute and to decouple computation with and presentation of these magic numbers, as well as documenting them. However, that's out of scope for this PR.
Originally posted by @ppoelzl in https://github.com/PathOfBuildingCommunity/PathOfBuilding/pull/2250#r606424703
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia leggendo la discussione su pathDist nella pull request #2250 e individua ogni utilizzo dell’attributo pathDist. Il refactoring è completo quando pathDist è sempre numerico e la presentazione non dipende più dal controllo di valori stringa come "Anoint" o "Cluster".
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- lua
- Ambito
- game-dev
- Tipo di issue
- Refactoring
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 25/100