MCPcopy Create free account
hub / github.com/OpenFodder/openfodder / Recruit_Draw_Soldiers

Method Recruit_Draw_Soldiers

Source/Recruits.cpp:1804–1873  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1802}
1803
1804void cFodder::Recruit_Draw_Soldiers() {
1805 sRecruit_Screen_Pos* Data20 = mRecruit_Screen_Positions;
1806 sRecruit_Screen_Pos* dword_3B1C7;
1807
1808 for (; ; Data20 = dword_3B1C7) {
1809
1810 dword_3B1C7 = Data20;
1811
1812 if (Data20->mX < 0)
1813 break;
1814
1815 int16 Data0;
1816 int16 Data8 = Data20->mX;
1817 int16 DataC = Data20->mY;
1818 int16 Data4 = Data20->mFrame;
1819 ++Data20;
1820 dword_3B1C7 = Data20;
1821
1822 if (Data4 == 0)
1823 continue;
1824
1825 --Data4;
1826 if (Data4 >= 3) {
1827 //loc_177E3
1828 Data4 -= 3;
1829 Data0 = 0x0A;
1830 Data0 += Data4;
1831
1832 // Sprite reached end of last curve
1833 if (DataC >= 0xB7)
1834 Data0 += 4;
1835
1836 // Sprite on last curve
1837 else if (DataC > 0x7C)
1838 Data0 += 2;
1839
1840 // First dip of mountain is frame 0
1841 Data4 = 0;
1842
1843 // Second Dip is frame 1
1844 if (Data20 > &mRecruit_Screen_Positions[0x46]) {
1845 Data4 = 1;
1846
1847 // Last leg of mountain
1848 if (Data20 > &mRecruit_Screen_Positions[0x7A])
1849 Data4 = 2;
1850 }
1851 }
1852 else
1853 Data0 = 9; // Hill Piece
1854
1855 //loc_1784C
1856 if (mVersionCurrent->isPC()) {
1857 DataC -= 8;
1858
1859 // Hill pieces are 16bit graphics
1860 if (Data0 != 9)
1861 GUI_Draw_Frame_8(Data0, Data4, Data8, DataC);

Callers

nothing calls this directly

Calls 1

isPCMethod · 0.80

Tested by

no test coverage detected