Skip to content

Commit

Permalink
Block 모양별 2D map
Browse files Browse the repository at this point in the history
  • Loading branch information
승호 이 committed Jan 6, 2025
1 parent e55cdf3 commit af8f883
Show file tree
Hide file tree
Showing 3 changed files with 199 additions and 0 deletions.
195 changes: 195 additions & 0 deletions BlockMap.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,195 @@
#pragma once

char blockModel[][4][4] =
{
/* ㅁ
ㅁㅁㅁ */
{
{0,0,0,0},
{1,0,0,0},
{1,1,1,0},
{0,0,0,0}
},
{
{0,1,0,0},
{0,1,0,0},
{1,1,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,1,1,0},
{0,0,1,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,1,0,0},
{1,0,0,0},
{1,0,0,0}
},

/* ㅁ
ㅁㅁㅁ */
{
{0,0,0,0},
{0,0,1,0},
{1,1,1,0},
{0,0,0,0}
},
{
{1,1,0,0},
{0,1,0,0},
{0,1,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,1,1,0},
{1,0,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,0,0,0},
{1,0,0,0},
{1,1,0,0}
},

/* ㅁ
ㅁㅁㅁ */
{
{0,0,0,0},
{0,1,0,0},
{1,1,1,0},
{0,0,0,0}
},
{
{0,1,0,0},
{1,1,0,0},
{0,1,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,1,1,0},
{0,1,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,0,0,0},
{1,1,0,0},
{1,0,0,0}
},

/* ㅁ
ㅁ */
{
{1,0,0,0},
{1,0,0,0},
{1,0,0,0},
{1,0,0,0}
},
{
{0,0,0,0},
{1,1,1,1},
{0,0,0,0},
{0,0,0,0}
},
{
{1,0,0,0},
{1,0,0,0},
{1,0,0,0},
{1,0,0,0}
},
{
{0,0,0,0},
{1,1,1,1},
{0,0,0,0},
{0,0,0,0}
},

/* ㅁㅁ
ㅁㅁ */
{
{0,0,0,0},
{1,1,0,0},
{1,1,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,1,0,0},
{1,1,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,1,0,0},
{1,1,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,1,0,0},
{1,1,0,0},
{0,0,0,0}
},

/* ㅁㅁ
ㅁㅁ */
{
{0,0,0,0},
{0,1,1,0},
{1,1,0,0},
{0,0,0,0}
},
{
{1,0,0,0},
{1,1,0,0},
{0,1,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{0,1,1,0},
{1,1,0,0},
{0,0,0,0}
},
{
{1,0,0,0},
{1,1,0,0},
{0,1,0,0},
{0,0,0,0}
},

/* ㅁㅁ
ㅁㅁ */
{
{0,0,0,0},
{1,1,0,0},
{0,1,1,0},
{0,0,0,0}
},
{
{0,1,0,0},
{1,1,0,0},
{1,0,0,0},
{0,0,0,0}
},
{
{0,0,0,0},
{1,1,0,0},
{0,1,1,0},
{0,0,0,0}
},
{
{0,1,0,0},
{1,1,0,0},
{1,0,0,0},
{0,0,0,0}
}
};
1 change: 1 addition & 0 deletions HongLabTetris.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@
<ClCompile Include="HongLabTetris.cpp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="BlockMap.h" />
<ClInclude Include="Board.h" />
<ClInclude Include="Cell.h" />
<ClInclude Include="Engine.h" />
Expand Down
3 changes: 3 additions & 0 deletions HongLabTetris.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,8 @@
<ClInclude Include="GameMode.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="BlockMap.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
</Project>

0 comments on commit af8f883

Please sign in to comment.