1
0
mirror of https://github.com/TerryCavanagh/VVVVVV.git synced 2024-06-26 14:38:30 +02:00
This makes the modifiers for removing tiles only work if you're using tools 0 or 1 (wall or background). In the future it might be worth it to add some extra subtools for spikes, but for now this should be fine.
Also, there was a small inconsistency with the tool drawn and the tool used. If you started holding down V, then started holding down Z, you would place tiles like you're holding V (9x9) but your cursor would look like you're holding Z (3x3). The `if` chain for drawing the resized cursors has been flipped around for this.
This commit is contained in:
AllyTally 2020-08-01 16:23:56 -03:00 committed by Ethan Lee
parent 720cd7642a
commit c8b4c0f1e7

View File

@ -3046,30 +3046,32 @@ void editorrender()
if(ed.drawmode<3)
{
if(ed.zmod && ed.drawmode<2)
if(ed.bmod && ed.drawmode<2)
{
fillboxabs((ed.tilex*8)-8,(ed.tiley*8)-8,24,24, graphics.getRGB(200,32,32));
}
else if(ed.xmod && ed.drawmode<2)
{
fillboxabs((ed.tilex*8)-16,(ed.tiley*8)-16,24+16,24+16, graphics.getRGB(200,32,32));
}
else if(ed.cmod && ed.drawmode<2)
{
fillboxabs((ed.tilex*8)-24,(ed.tiley*8)-24,24+32,24+32, graphics.getRGB(200,32,32));
}
else if(ed.vmod && ed.drawmode<2)
{
fillboxabs((ed.tilex*8)-32,(ed.tiley*8)-32,24+48,24+48, graphics.getRGB(200,32,32));
fillboxabs((ed.tilex*8),0,8,240,graphics.getRGB(200,32,32));
}
else if(ed.hmod && ed.drawmode<2)
{
fillboxabs(0,(ed.tiley*8),320,8,graphics.getRGB(200,32,32));
}
else if(ed.bmod && ed.drawmode<2)
else if(ed.vmod && ed.drawmode<2)
{
fillboxabs((ed.tilex*8),0,8,240,graphics.getRGB(200,32,32));
fillboxabs((ed.tilex*8)-32,(ed.tiley*8)-32,24+48,24+48, graphics.getRGB(200,32,32));
}
else if(ed.cmod && ed.drawmode<2)
{
fillboxabs((ed.tilex*8)-24,(ed.tiley*8)-24,24+32,24+32, graphics.getRGB(200,32,32));
}
else if(ed.xmod && ed.drawmode<2)
{
fillboxabs((ed.tilex*8)-16,(ed.tiley*8)-16,24+16,24+16, graphics.getRGB(200,32,32));
}
else if(ed.zmod && ed.drawmode<2)
{
fillboxabs((ed.tilex*8)-8,(ed.tiley*8)-8,24,24, graphics.getRGB(200,32,32));
}
}
//If in directmode, show current directmode tile
@ -5328,6 +5330,7 @@ void editorinput()
if(key.rightbutton)
{
//place tiles
if(ed.drawmode < 2) {
if(ed.bmod)
{
for(int i=0; i<30; i++)
@ -5386,6 +5389,11 @@ void editorinput()
{
ed.placetilelocal(ed.tilex, ed.tiley, 0);
}
}
else
{
ed.placetilelocal(ed.tilex, ed.tiley, 0);
}
for(size_t i=0; i<edentity.size(); i++)
{
if(edentity[i].x==ed.tilex + (ed.levx*40)&& edentity[i].y==ed.tiley+ (ed.levy*30))