Omnimaga

Calculator Community => TI Calculators => Axe => Topic started by: squidgetx on September 19, 2011, 11:25:07 pm

Title: Finishing Touches; Animations, Graphics & Menu Tutorial
Post by: squidgetx on September 19, 2011, 11:25:07 pm
So buttsfredkin suggested I write a tutorial on this subject, so I guess I might as well. This tutorial is going to be a little less structured than usual; I'm just going to list off a series of bullet point tips for you guys. Enjoy!

Note; For clarity purposes I've left the code relatively unoptimized.

Code: (Simple fly-in) [Select]
"Text"->Str1
0->X 
40->V
While V   //While it has some velocity
Text(X/8,Y,Str1)  //We'll use *8 precision
V-1->V+X->X  //Decrease velocity by 1 and add it to the position
End

Code: (Grayscale borderline inside the box) [Select]
Rect(x,y,w,h)
RectI(x+1,y+1,w-2,h-2)
Rect(x,y,w,h)^^r
RectI(x+2,y+2,w-4,h-4
Code: (Pokemon style box) [Select]
Rect(x,y,w,h)
RectI(x+2,y+2,w-4,h-4)
Pxl-off(x,y)
Pxl-off(x+w,y)
Pxl-off(x,y+h)
Pxl-off(x+w,y+h)
Use your imagination!

Code: (custom font) [Select]
.Let's pretend that the fontset is stored in Pic1
Lbl W  //write routine, arguments are x, y and pointer to text
For(E,0,length(r3)-1)  //For the length of the word
Pt-On(E*8+r1,r2,{r3+E}-$41*8+Pic1)   //Take value of text character and use it to draw the letter.
End

Well I'm done for now, I might add some more stuff if I can think of it in the morning.
Title: Re: Finishing Touches; Animations, Graphics & Menu Tutorial
Post by: MGOS on September 20, 2011, 12:52:37 am
Wow, nice tutorial, squidgetx.
The only thing I don't understand is the dollar sign in the Pt-On()-Function in the last example. Is this new to axe in 1.0.x, in which menu can I get it, or is it just a typing mistake?
Title: Re: Finishing Touches; Animations, Graphics & Menu Tutorial
Post by: LincolnB on September 21, 2011, 09:41:31 am
Yay for squigetx!! This will be useful information. Also, by the dollar sign in Pt-On, did you mean hexadecimal notation?
Title: Re: Finishing Touches; Animations, Graphics & Menu Tutorial
Post by: Munchor on September 21, 2011, 11:51:57 am
Wow, nice tutorial, squidgetx.
The only thing I don't understand is the dollar sign in the Pt-On()-Function in the last example. Is this new to axe in 1.0.x, in which menu can I get it, or is it just a typing mistake?

$ means the Hexadecimal notation symbol, not sure of what it is in Axe ;)

Nice tutorial squidgetx!