• Axe Q&A 5 5
Currently:  

Author Topic: Axe Q&A  (Read 600389 times)

0 Members and 1 Guest are viewing this topic.

Offline BlakPilar

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 734
  • Rating: +44/-1
    • View Profile
Re: Axe Q&A
« Reply #1230 on: December 16, 2011, 07:57:43 pm »
Is there any way to "re-declare" an array? For example, doing "Data(0,0,0)->GDB0" at one point, then doing "Data(6,3,5)->GDB0" later? Or, after the array has been declared, would I need to do something like "6->{GDB0+0}:3->{GDB0+1}:5->{GDB0+2}" to change values?

Offline parserp

  • Hero Extraordinaire
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1455
  • Rating: +88/-7
  • The King Has Returned
    • View Profile
Re: Axe Q&A
« Reply #1231 on: December 16, 2011, 08:06:08 pm »
How would I learn tilemapping/scrolling for a platformer? I don't know how to adapt the ones in the tutorials section to make it work. ???

Offline leafy

  • CoT Emeritus
  • LV10 31337 u53r (Next: 2000)
  • *
  • Posts: 1554
  • Rating: +475/-97
  • Seizon senryakuuuu!
    • View Profile
    • keff.me
Re: Axe Q&A
« Reply #1232 on: December 16, 2011, 08:20:53 pm »
Is there any way to "re-declare" an array? For example, doing "Data(0,0,0)->GDB0" at one point, then doing "Data(6,3,5)->GDB0" later? Or, after the array has been declared, would I need to do something like "6->{GDB0+0}:3->{GDB0+1}:5->{GDB0+2}" to change values?
If your program doesn't writeback, then this is okay. It would be much easier to store values to a free RAM space, then alter them there.
In-progress: Graviter (...)

Offline Quigibo

  • The Executioner
  • CoT Emeritus
  • LV11 Super Veteran (Next: 3000)
  • *
  • Posts: 2031
  • Rating: +1075/-24
  • I wish real life had a "Save" and "Load" button...
    • View Profile
Re: Axe Q&A
« Reply #1233 on: December 16, 2011, 09:10:40 pm »
Is there any way to "re-declare" an array? For example, doing "Data(0,0,0)->GDB0" at one point, then doing "Data(6,3,5)->GDB0" later? Or, after the array has been declared, would I need to do something like "6->{GDB0+0}:3->{GDB0+1}:5->{GDB0+2}" to change values?
If your program doesn't writeback, then this is okay. It would be much easier to store values to a free RAM space, then alter them there.
Alternatively, you can store data to a variable instead of a constant and then your can re-assign pointers all you want.
« Last Edit: December 16, 2011, 09:10:59 pm by Quigibo »
___Axe_Parser___
Today the calculator, tomorrow the world!

Offline epic7

  • Chopin!
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2200
  • Rating: +135/-8
  • I like robots
    • View Profile
Re: Axe Q&A
« Reply #1234 on: December 16, 2011, 09:12:13 pm »
How would I learn tilemapping/scrolling for a platformer? I don't know how to adapt the ones in the tutorials section to make it work. ???
I found it difficult to follow Yunhua's tutorial :P
I learned it from aeTIos and butts.
But, I'll show you how it works.

Offline parserp

  • Hero Extraordinaire
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1455
  • Rating: +88/-7
  • The King Has Returned
    • View Profile
Re: Axe Q&A
« Reply #1235 on: December 16, 2011, 09:12:44 pm »
allright! :D

Offline BlakPilar

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 734
  • Rating: +44/-1
    • View Profile
Re: Axe Q&A
« Reply #1236 on: December 16, 2011, 09:19:39 pm »
If your program doesn't writeback, then this is okay. It would be much easier to store values to a free RAM space, then alter them there.
Alternatively, you can store data to a variable instead of a constant and then your can re-assign pointers all you want.
Ahh, thanks guys!

Offline Darl181

  • «Yo buddy, you still alive?»
  • CoT Emeritus
  • LV12 Extreme Poster (Next: 5000)
  • *
  • Posts: 3408
  • Rating: +305/-13
  • VGhlIEdhbWU=
    • View Profile
    • darl181.webuda.com
Re: Axe Q&A
« Reply #1237 on: December 17, 2011, 12:48:45 pm »
That's one of the advantages of compiled languages. Larger source code does not mean larger compiled code. You can add line breaks and comments and long-named labels all you want; the compiled code will always be the same size.
Cool :)
Does the same apply for If <condition>:Stuff:End versus <condition>?stuff ?
I've noticed some things don't work in the latter, such as getKey(x) for the condition and Pt-***.
« Last Edit: December 17, 2011, 12:49:08 pm by Darl181 »
Vy'o'us pleorsdti thl'e gjaemue

Offline epic7

  • Chopin!
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2200
  • Rating: +135/-8
  • I like robots
    • View Profile
Re: Axe Q&A
« Reply #1238 on: December 17, 2011, 12:49:25 pm »
What does ? do?

Offline Darl181

  • «Yo buddy, you still alive?»
  • CoT Emeritus
  • LV12 Extreme Poster (Next: 5000)
  • *
  • Posts: 3408
  • Rating: +305/-13
  • VGhlIEdhbWU=
    • View Profile
    • darl181.webuda.com
Re: Axe Q&A
« Reply #1239 on: December 17, 2011, 12:50:01 pm »
It's basically a short version of If afaict, tho there's some differences apparently.
Vy'o'us pleorsdti thl'e gjaemue

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: Axe Q&A
« Reply #1240 on: December 17, 2011, 12:50:50 pm »
I am prety sure it is the same.
but can be used for other optimizations because it works inline.
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________

Offline epic7

  • Chopin!
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2200
  • Rating: +135/-8
  • I like robots
    • View Profile
Re: Axe Q&A
« Reply #1241 on: December 17, 2011, 12:51:07 pm »
*guess*
So

If getKey(2)
X--
End

Would be the same as

getKey(2)?X--

?

Offline Darl181

  • «Yo buddy, you still alive?»
  • CoT Emeritus
  • LV12 Extreme Poster (Next: 5000)
  • *
  • Posts: 3408
  • Rating: +305/-13
  • VGhlIEdhbWU=
    • View Profile
    • darl181.webuda.com
Re: Axe Q&A
« Reply #1242 on: December 17, 2011, 12:53:23 pm »
getKey(2)?X--
Evidently not, when I tried something like that it threw an error at compile-time. :/
« Last Edit: December 17, 2011, 12:53:30 pm by Darl181 »
Vy'o'us pleorsdti thl'e gjaemue

Offline epic7

  • Chopin!
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2200
  • Rating: +135/-8
  • I like robots
    • View Profile
Re: Axe Q&A
« Reply #1243 on: December 17, 2011, 12:54:25 pm »
Ok then, so there are some differences. :P

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: Axe Q&A
« Reply #1244 on: December 17, 2011, 12:56:22 pm »
i think that is becasue X-- is a command, not a value.  Try x-1->x
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________