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

Method n_life

MicropolisCore/src/CellEngine/src/cellengine.cpp:1795–1814  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1793
1794
1795void CellEngine::n_life()
1796{
1797 long sum;
1798
1799#define LIFE ( \
1800 ((c & 1) \
1801 ? (((sum = SUM8REG(1)) == 2) || \
1802 (sum == 3)) \
1803 : ((SUM8REG(1) == 3) ? 1 : 0)) | \
1804 ((c & 0x7f) << 1))
1805
1806 if (inflation) {
1807 int last = 0;
1808 int heat = 0;
1809
1810 CAM_MASKED_REG_HEAT6_LOOP(LIFE)
1811 } else {
1812 CAM_MASKED_REG_LOOP(LIFE)
1813 }
1814}
1815
1816
1817void CellEngine::n_brain()

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected