MCPcopy Create free account
hub / github.com/ddnet/ddnet / IsEmpty

Method IsEmpty

src/game/editor/mapitems/layer_tune.cpp:61–79  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

59}
60
61bool CLayerTune::IsEmpty() const
62{
63 for(int y = 0; y < m_Height; y++)
64 {
65 for(int x = 0; x < m_Width; x++)
66 {
67 const int Index = GetTile(x, y).m_Index;
68 if(Index == 0)
69 {
70 continue;
71 }
72 if(Editor()->IsAllowPlaceUnusedTiles() || IsValidTuneTile(Index))
73 {
74 return false;
75 }
76 }
77 }
78 return true;
79}
80
81void CLayerTune::BrushDraw(CLayer *pBrush, vec2 WorldPos)
82{

Callers 2

BrushDrawMethod · 0.45
FillSelectionMethod · 0.45

Calls 2

IsValidTuneTileFunction · 0.85

Tested by

no test coverage detected