mirror of
https://github.com/a-b-street/abstreet.git
synced 2024-11-22 14:52:07 +03:00
Fix mapbox demo. #1023
This commit is contained in:
parent
0e87b78c0c
commit
358ae97f02
@ -100,9 +100,10 @@ impl PiggybackDemo {
|
||||
pub fn spawn_traffic(&mut self) {
|
||||
let mut rng = sim::SimFlags::for_test("spawn_traffic").make_rng();
|
||||
let mut timer = Timer::new("spawn traffic");
|
||||
sim::ScenarioGenerator::small_run(&self.map)
|
||||
.generate(&self.map, &mut rng, &mut timer)
|
||||
.instantiate(&mut self.sim, &self.map, &mut rng, &mut timer);
|
||||
let scenario =
|
||||
sim::ScenarioGenerator::small_run(&self.map).generate(&self.map, &mut rng, &mut timer);
|
||||
self.sim
|
||||
.instantiate(&scenario, &self.map, &mut rng, &mut timer);
|
||||
}
|
||||
|
||||
/// Reset the traffic simulation.
|
||||
|
Loading…
Reference in New Issue
Block a user