Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Add the simulation step driver and the game's random generator

Chiusa
#267 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
rust
Ambito
cli, game-dev

Direzione di ricerca

Start with the new sim module and the step call in app, then the calendar in timing, which the issue says moves out of the app. Build Sim::step in the order the issue gives, and add the seeded generator with its chance and pick reductions. Done means a unit test on the generator's first three values after seed 1 and on the calendar's one-step month flag passes, and run --headless --seed 1 prints identical sim lines on two runs. The replay's frame hashes must stay unchanged.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement

Core sim: the step of the original. Sim::step runs the six managers in the original's order (private spec simulation, main-loop 6.1): the game manager (total simulated time, the calendar, which moves here from the app, the month flag acted on one step late), the AI manager (the AI clock in whole ticks with its remainder, the removal list, the loop over the units taken by count before it starts, the event queue aged by one step), the world manager (the world clock), and the scenario, research and marketing managers as empty calls. The simulation's own random generator (the C runtime's formula, one 32-bit state, the chance and pick reductions as the original makes them), seeded through one seconds source at the three moments of main-loop 9.2: the wall clock in play, seed + n in a test run. run --headless --seed N. The [AI] keys of the ini read with their fallbacks. Log family sim (sim step <ms>, sim seed <n>, sim month <m> <y>).
Module: sim (new), app (the step call), timing (the calendar moves).
Done when a unit test checks the generator's first three values after the seed 1 against the C runtime's known sequence and the three reductions; a headless run with --seed 1 on a trial map prints identical sim lines twice; the month flag is acted on one step after the step that raised it (unit test on the calendar); the existing replay keeps its frame hashes.
Parent: #54
After: none

Lingua principale
Rust
Stelle
0
Fork
0
Merge medio
2h 34m
PR unite (30g)
143

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di RustyZoo/RustyZoo

Tutte le issue di RustyZoo/RustyZoo

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.