| 3792 | } |
| 3793 | |
| 3794 | void cFodder::Sprite_Draw_Frame(sSprite* pDi, int16 pSpriteType, int16 pFrame, cSurface *pDestination) { |
| 3795 | auto SheetData = Sprite_Get_Sheet(pSpriteType, pFrame); |
| 3796 | |
| 3797 | mVideo_Draw_PaletteIndex = SheetData->mPalleteIndex & 0xFF; |
| 3798 | mVideo_Draw_FrameDataPtr = SheetData->GetGraphicsPtr(); |
| 3799 | |
| 3800 | mVideo_Draw_Columns = SheetData->mColCount; |
| 3801 | mVideo_Draw_Rows = SheetData->mRowCount - pDi->field_52; |
| 3802 | |
| 3803 | #if defined(_OFED) || defined(_OFBOT) |
| 3804 | mMapTile_DrawY = (mMapTile_MovedVertical * 16) + mMapTile_RowOffset; |
| 3805 | mMapTile_DrawX = (mMapTile_MovedHorizontal * 16) + mMapTile_ColumnOffset; |
| 3806 | |
| 3807 | mVideo_Draw_PosX = (int16)((SheetData->mModX + pDi->field_0) - mMapTile_DrawX); |
| 3808 | #else |
| 3809 | mVideo_Draw_PosX = (int16)((SheetData->mModX + pDi->field_0) - mMapTile_DrawX + 0x40); |
| 3810 | #endif |
| 3811 | |
| 3812 | mVideo_Draw_PosY = (int16)((SheetData->mModY + pDi->field_4) - mVideo_Draw_Rows - pDi->field_20 - mMapTile_DrawY); |
| 3813 | mVideo_Draw_PosY += 0x10; |
| 3814 | |
| 3815 | if (Sprite_OnScreen_Check()) { |
| 3816 | pDi->field_5C = 1; |
| 3817 | if(!mStartParams->mDisableVideo) |
| 3818 | mGraphics->Video_Draw_8(pDestination); |
| 3819 | } |
| 3820 | else |
| 3821 | pDi->field_5C = 0; |
| 3822 | } |
| 3823 | |
| 3824 | bool cFodder::Sprite_OnScreen_Check() { |
| 3825 |
nothing calls this directly
no test coverage detected