Currently, I am using

Code:
If sub(Str1,T-1,1)n="X"

But I need it for up to 10 characters, which would slow the engine down alot. I am wondering if you might have an idea on how to look at all of them to determine if it should move or not without having to do a lot of the above...
You could do

Code:
For(X,1,10
If sub(Str1,T-1,1)n=sub("ABCDEFGHIJ",x,1
Stuff
End
I thought about that, and that would probably cause really bad lag... I guess I am just gonna have to program it a couple different ways, see which is faster...
I'm pretty sure Kerm's solution is the most efficient possible, sadly.
Unfortunately, yes. I tried finding an alternate way with one less substring, but no dice. Sad
Probably, but I will try all that I can to see if I can find something better...
Please do. Some of the other 1337 might know...
I should post my movement code for my engine. It is a crazy 100 line function (*4 for each direction) and is faster if it is not able to be moved, which is unfortunate. There are ~6 things tested with for loops from 0-63. I can't wait to see what it will perform like...
*cough* 10SPF *cough* Smile Just Joking
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement