+Random Terrain Posted September 15, 2010 Share Posted September 15, 2010 I started switching over to def in my latest program so it would be easier to read, but it doesn't work because of NOT. Here's an example that works: a{0} = !a{1} loop drawscreen goto loop Replace that with def and it won't work: def Test_00 = a{0} def Test_01 = a{1} def Test_02 = a{2} def Test_03 = a{3} def Test_04 = a{4} def Test_05 = a{5} def Test_06 = a{6} def Test_07 = a{7} Test_00 = !Test_01 loop drawscreen goto loop I even switched to the latest version of bB posted here: http://www.atariage.com/forums/topic/168036-new-build-improved-if-then/page__view__findpost__p__2081991 It didn't help. Did I discover a bug? Thanks. Quote Link to comment Share on other sites More sharing options...
+Gemintronic Posted September 15, 2010 Share Posted September 15, 2010 I didn't mention anything but I think I encountered that with my "4 Way Scrolling Platform Engine" example. Sadly, I just worked around it and forgot about it 'till now Quote Link to comment Share on other sites More sharing options...
SeaGtGruff Posted September 15, 2010 Share Posted September 15, 2010 I'd think it *should* work, so I'd say it's a bug. Here's a possible workaround: def Test_01 = a{1} def !Test_01 = !a{1} I can't test it right now, but I think it might work. Michael Quote Link to comment Share on other sites More sharing options...
+batari Posted September 15, 2010 Share Posted September 15, 2010 The problem seems to be with spacing. This doesn't work: def Test_00 = a{0} def Test_01 = a{1} def Test_02 = a{2} def Test_03 = a{3} def Test_04 = a{4} def Test_05 = a{5} def Test_06 = a{6} def Test_07 = a{7} Test_00 = !Test_01 loop drawscreen goto loop But this does: def Test_00=a{0} def Test_01=a{1} def Test_02=a{2} def Test_03=a{3} def Test_04=a{4} def Test_05=a{5} def Test_06=a{6} def Test_07=a{7} Test_00 = !Test_01 loop drawscreen goto loop bB is supposed to ignore extra spaces, but somehow they are not being ignored in defs. 1 Quote Link to comment Share on other sites More sharing options...
+Random Terrain Posted September 15, 2010 Author Share Posted September 15, 2010 (edited) bB is supposed to ignore extra spaces, but somehow they are not being ignored in defs. At least there's an immediate solution. Thanks! I'll update the bB page. I'd think it *should* work, so I'd say it's a bug. Here's a possible workaround: def Test_01 = a{1} def !Test_01 = !a{1} I can't test it right now, but I think it might work. It didn't work until the spaces were removed, but when the spaces are removed, it isn't needed anyway. Thanks. Edited September 15, 2010 by Random Terrain Quote Link to comment Share on other sites More sharing options...
SeaGtGruff Posted September 16, 2010 Share Posted September 16, 2010 (edited) Oddly enough, when I was making my first post I was wondering if the spaces around the "=" would confuse bB, because I seemed to recall a similar issue with "const", although I thought that was fixed for "const", so I went ahead and put spaces around the "=". Michael Edited September 16, 2010 by SeaGtGruff Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.