This commit is contained in:
parent
afcfbf7547
commit
fcfea94be6
3 changed files with 15 additions and 16 deletions
|
@ -137,6 +137,11 @@ int Height=GetHeight();
|
|||
if ((X>=0 && X<Width) && (Y>=0 && Y<Height))
|
||||
{
|
||||
Map[X][Y]=Blk;
|
||||
TRACE2("%i %i\n",Blk.Set,Blk.Tile);
|
||||
if (Blk.Tile==0)
|
||||
{ // Only use one zero tile
|
||||
Map[X][Y].Set=0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -222,7 +227,8 @@ int Height=GetHeight();
|
|||
for (int X=0; X<Width; X++)
|
||||
{
|
||||
sMapElem &ThisElem=Get(X,Y);
|
||||
if (ThisElem.Set==Tile.Set && ThisElem.Tile==Tile.Tile) return(TRUE);
|
||||
if (ThisElem.Tile==Tile.Tile)
|
||||
if (ThisElem.Set==Tile.Set || Tile.Tile==0) return(TRUE);
|
||||
}
|
||||
}
|
||||
return(FALSE);
|
||||
|
|
|
@ -18,21 +18,21 @@ Class6=CMapEditDoc
|
|||
Class7=CMapEditView
|
||||
|
||||
ResourceCount=11
|
||||
Resource1=IDD_MULTIBAR (English (U.S.))
|
||||
Resource2=IDD_LAYERTILE_GUI
|
||||
Resource3=IDR_TOOLBAR (English (U.S.))
|
||||
Resource1=IDR_MAINFRAME (English (U.S.))
|
||||
Resource2=IDD_MULTIBAR (English (U.S.))
|
||||
Resource3=IDD_MAPSIZE
|
||||
Resource4=IDD_DIALOGBAR (English (U.S.))
|
||||
Resource5=IDD_LAYER_LIST_DIALOG
|
||||
Resource5=IDD_ABOUTBOX (English (U.S.))
|
||||
Class8=CMultiBar
|
||||
Resource6=IDR_MAINFRAME (English (U.S.))
|
||||
Resource6=IDD_NEW_LAYER
|
||||
Resource7=IDR_MAPEDITYPE (English (U.S.))
|
||||
Class9=CLayerList
|
||||
Class10=CMapSizeDlg
|
||||
Resource8=IDD_MAPSIZE
|
||||
Resource8=IDD_LAYER_LIST_DIALOG
|
||||
Class11=CGfxToolBar
|
||||
Class12=CLayerTileGUI
|
||||
Resource9=IDD_NEW_LAYER
|
||||
Resource10=IDD_ABOUTBOX (English (U.S.))
|
||||
Resource9=IDD_LAYERTILE_GUI
|
||||
Resource10=IDR_TOOLBAR (English (U.S.))
|
||||
Class13=CNewMapGUI
|
||||
Resource11=IDD_NEWMAP
|
||||
|
||||
|
|
|
@ -211,7 +211,6 @@ BOOL CTileBank::Select(int BrushID,BOOL DownFlag)
|
|||
TRACE0("Selected Blank\n");
|
||||
|
||||
}
|
||||
// TRACE3("Start %i=%i,%i\n",SelStart,SelStart%TileBrowserWidth,SelStart/TileBrowserWidth);
|
||||
}
|
||||
else
|
||||
if (!DownFlag && SelStart!=-1)
|
||||
|
@ -234,11 +233,6 @@ int BW=TileSet[CurrentSet].GetTileBrowserWidth();
|
|||
CPoint S=IDToPoint(SelStart-1,BW);
|
||||
CPoint E=IDToPoint(SelEnd-1,BW);
|
||||
|
||||
|
||||
//CPoint Start=CPoint(min(S.x,E.x), min(S.y,E.y));
|
||||
//CPoint End=CPoint( max(S.x,E.x), max(S.y,E.y));
|
||||
//int Width=(End.x-Start.x)+1;
|
||||
//int Height=(End.y-Start.y)+1;
|
||||
int Width=abs(E.x-S.x)+1;
|
||||
int Height=abs(E.y-S.y)+1;
|
||||
|
||||
|
@ -257,7 +251,6 @@ int MaxTile=TileSet[CurrentSet].GetTileCount();
|
|||
{
|
||||
for (int X=0; X<Width; X++)
|
||||
{
|
||||
// ThisElem.Tile=PointToID(CPoint(Start.x+X,Start.y+Y),BW);
|
||||
ThisElem.Tile=SelStart+X+(Y*BW);
|
||||
ThisBrush.Set(X,Y,ThisElem);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue