mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-22 17:49:43 +01:00
Add bounds-check to entcolours in editor rendering
I have no idea why neither conveyors and moving and disappearing platforms rendered in the editor or in-game use Graphics::drawentcolours(), but this needs to be bounds-checked just as I did for the in-game rendering function.
This commit is contained in:
parent
c325085ddb
commit
3ffe1b2e3b
1 changed files with 8 additions and 0 deletions
|
@ -2676,6 +2676,10 @@ void editorrender()
|
|||
fillboxabs((edentity[i].x*8)- (ed.levx*40*8),(edentity[i].y*8)- (ed.levy*30*8),16,16,graphics.getBGR(255,164,255));
|
||||
break;
|
||||
case 2: //Threadmills & platforms
|
||||
if (!INBOUNDS_VEC(obj.customplatformtile, graphics.entcolours))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
tpoint.x = (edentity[i].x*8)- (ed.levx*40*8);
|
||||
tpoint.y = (edentity[i].y*8)- (ed.levy*30*8);
|
||||
drawRect = graphics.tiles_rect;
|
||||
|
@ -2733,6 +2737,10 @@ void editorrender()
|
|||
}
|
||||
break;
|
||||
case 3: //Disappearing Platform
|
||||
if (!INBOUNDS_VEC(obj.customplatformtile, graphics.entcolours))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
tpoint.x = (edentity[i].x*8)- (ed.levx*40*8);
|
||||
tpoint.y = (edentity[i].y*8)- (ed.levy*30*8);
|
||||
drawRect = graphics.tiles_rect;
|
||||
|
|
Loading…
Reference in a new issue