Add logs if a Graphics func was stopped from indexing OoB

This doesn't happen too often, but it'll be useful to people making
custom levels so they know that it can happen, when it does.
This commit is contained in:
Misa authored and Ethan Lee committed 2020-06-28 15:48:48 -04:00
1 parent c95c1ab250
commit 18b34d0066
1 file changed
+9
+9
View File
@@ -1143,6 +1143,7 @@ void Graphics::textboxtimer( int t )
{
if (!INBOUNDS(m, textbox))
{
puts("textboxtimer() out-of-bounds!");
return;
}
@@ -1153,6 +1154,7 @@ void Graphics::addline( std::string t )
{
if (!INBOUNDS(m, textbox))
{
puts("addline() out-of-bounds!");
return;
}
@@ -1163,6 +1165,7 @@ void Graphics::textboxadjust()
{
if (!INBOUNDS(m, textbox))
{
puts("textboxadjust() out-of-bounds!");
return;
}
@@ -2804,6 +2807,7 @@ void Graphics::textboxcenter()
{
if (!INBOUNDS(m, textbox))
{
puts("textboxcenter() out-of-bounds!");
return;
}
@@ -2815,6 +2819,7 @@ void Graphics::textboxcenterx()
{
if (!INBOUNDS(m, textbox))
{
puts("textboxcenterx() out-of-bounds!");
return;
}
@@ -2825,6 +2830,7 @@ int Graphics::textboxwidth()
{
if (!INBOUNDS(m, textbox))
{
puts("textboxwidth() out-of-bounds!");
return 0;
}
@@ -2835,6 +2841,7 @@ void Graphics::textboxmove(int xo, int yo)
{
if (!INBOUNDS(m, textbox))
{
puts("textboxmove() out-of-bounds!");
return;
}
@@ -2846,6 +2853,7 @@ void Graphics::textboxmoveto(int xo)
{
if (!INBOUNDS(m, textbox))
{
puts("textboxmoveto() out-of-bounds!");
return;
}
@@ -2856,6 +2864,7 @@ void Graphics::textboxcentery()
{
if (!INBOUNDS(m, textbox))
{
puts("textboxcentery() out-of-bounds!");
return;
}