Skip to content

Commit eea5251

Browse files
committed
Showing borders!
1 parent fb160b8 commit eea5251

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,5 @@ sysinfo.txt
2727

2828
# Builds
2929
*.apk
30-
*.unitypackage
30+
Assets/ConsolePro
31+
ConsolePro.meta

Assets/Scripts/Demo.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,15 +89,18 @@ private void updateRectangles() {
8989

9090
tmpColor = new Color32[(int) (rect.width * rect.height)];
9191
for (int k = 0; k < tmpColor.Length; ++k)
92-
tmpColor [k] = Color.black;
93-
92+
tmpColor[k] = Color.black;
93+
9494
mTexture.SetPixels32((int) rect.x, (int) rect.y, (int) rect.width, (int) rect.height, tmpColor);
95+
9596
int index = mPacker.getRectangleId(j);
9697
Color color = convertHexToRGBA((uint) (0xFF171703 + (((18 * ((index + 4) % 13)) << 16) + ((31 * ((index * 3) % 8)) << 8) + 63 * (((index + 1) * 3) % 5))));
9798

9899
tmpColor = new Color32[(int) ((rect.width - 2) * (rect.height - 2))];
99100
for (int k = 0; k < tmpColor.Length; ++k)
100101
tmpColor[k] = color;
102+
103+
mTexture.SetPixels32((int) (rect.x + 1), (int) (rect.y + 1), (int) (rect.width - 2), (int) (rect.height - 2), tmpColor);
101104
}
102105

103106
mTexture.Apply();

0 commit comments

Comments
 (0)