MCPcopy Create free account
hub / github.com/SimHacker/micropolis / simFrame

Method simFrame

MicropolisCore/src/MicropolisEngine/src/simulate.cpp:98–118  ·  view source on GitHub ↗

comefrom: doEditWindow scoreDoer doMapInFront graphDoer doNilEvent */

Source from the content-addressed store, hash-verified

96
97/* comefrom: doEditWindow scoreDoer doMapInFront graphDoer doNilEvent */
98void Micropolis::simFrame()
99{
100
101 if (simSpeed == 0) {
102 return;
103 }
104
105 if (++speedCycle > 1023) {
106 speedCycle = 0;
107 }
108
109 if (simSpeed == 1 && (speedCycle % 5) != 0) {
110 return;
111 }
112
113 if (simSpeed == 2 && (speedCycle % 3) != 0) {
114 return;
115 }
116
117 simulate();
118}
119
120
121/* comefrom: simFrame */

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected