Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Builderboy

Pages: 1 ... 292 293 [294] 295 296 ... 375
4396
200$ for an 8 Gig, although i really like 32 gig for all the music/apps that i have, so it would be 300$ for a new one.  Yeah Apple sure knows how to charge you for stuff that you cant fix yourself :/

4397
The Axe Parser Project / Re: Features Wishlist
« on: April 07, 2010, 10:18:30 pm »
Heh, yeaah once we write a bit sending routine, we use it to write a byte sending routine XD Haha the joys of asm ^^

4398
what do you mean the same size?

Oops i meant the same screen ratio.  3/2

Yeah it wasn't on purpose, but it still sucks :/ just glad that insurance covers it because its 200$ to repair :O

4399
The Axe Parser Project / Re: Features Wishlist
« on: April 07, 2010, 10:14:56 pm »
I was reading about linking, and would it be faster to have one line be a clock, and then the other line be the bit to be sent?  When the receiving calc detects a change in the clock line, it inputs the bit line into memory.  Seems like it would be faster?  I'm just theorizing tho :P

4400
This would be so awesome, plus the screen size of an iTouch is exactly the same as an 84 ^^ Although i dont know how you'd handle the keypresses since the screen is they only method of input o.O

Either way, some kid at school smashed my iTouch, so i'm waiting to get a new one (yay insurance!)

4401
Portal X / Re: Portal X
« on: April 07, 2010, 08:32:27 pm »
Mmmm maybe because when you write to the 96th column, its column number 95? (since you start from 0)? Dunnoww....


Anyway, i have been working more on making the engine look a bit nicer, but i have a predicament.  The bounding box for the character MUST be square for the inter-portal collisions to work.  This is all fine and dandy until you try to fit a good looking person onto a 5x5 sprite D: Especialy because the feet MUST go to the corners for collision to look normal.  So I'm off to either make a good looking sprite (and walking animation) or try to come up with an alternative.

4402
Axe / Re: Routines
« on: April 07, 2010, 08:17:24 pm »
Yep, thats true, i didn't do any optimizing at all in this routine :P I'm really no good at it yet.

4403
The Axe Parser Project / Re: Bug Reports
« on: April 07, 2010, 10:22:54 am »
When an error occurs during compilations, the percent complete is not always there, or its at random values that change compile to compile. 

4404
The Axe Parser Project / Re: Features Wishlist
« on: April 07, 2010, 10:21:14 am »
Hah, at this point i dont think we even have to worry about compiling speed.  It might be the difference between 1 second and 1.1 seconds ^^ Gosh i love the Axe compiling speed, especially after having worked with the slow version for so long ;)

4405
The Axe Parser Project / Re: Features Wishlist
« on: April 07, 2010, 10:17:33 am »
Mmmm it would be nice for Axe to optimize division by any number multiple of 2 into a chain of bitshifts.  I was at first surprised how slow /64 was compared to /2 :P

4406
Axe / Re: Routines
« on: April 07, 2010, 10:15:38 am »
Heh, yeah the pixel drawing routine is kinda convoluted because of the 8 pixels per byte thing, and the need to do bitmasking and stuff.  I'll get the code commented later today.

4407
TI Z80 / Re: Digimon Virtual Pet Idea
« on: April 07, 2010, 10:14:50 am »
Whats weird is that under no circumstance is the 64th row used by the TiOS at all ??? Maybe they liked odd numbers :P

4408
Axe / Re: Physics Lessons
« on: April 07, 2010, 01:23:39 am »
OK here is a quick (kinda) lesson on trig and the wonders of Triangles!  Unplanned, so its coming before collisions :P

************
Trigonometry    NOTE: put your calc in degrees mode!
************

Trig is one of those things that can be very usefull in games, but is actualy fairly
difficult to figure out without some good instruction.  That is where this tutorial
is going to try to help.  

trigonometry is the mathematics of trianlges.  Take this triangle for instance

Code: [Select]
      |\
      | \
  a   |  \ C    (hypotenuse)
(leg) |   \
      |    \
      +-----
         b (leg)

It is a right triangle because the angle between side A and side B is 90 degrees.  This is
the only type of trignale we will discuss in this tutorial, and usualy it is the only one you
will need.

In addition to having 3 sides, there are also 3 angles. AB, AC, and BC.  You can also call them
by the sides that are *opposite* to that angle, so angle AB would be angle C.  We already
established that angle AB is 90 degrees.  This triangle is a RIGHT triangle, because it has one
right (90 degree) angle, and Right Triangles are your friend :)

For starters, here is the pythagorean theorem:

A^2 + B^2 = C^2

Hmmm interesting, for all Right Trignales, the sum of each leg squared, equals the hypotenuse squared.
(remember, the legs are the two sides that make the right angle)  What this means for us is that
for any right triangle, if we are given 2 sides, we can find the other with this equation.  This
is a way to calculate the distance to a point, as you can use the 2 legs as the X and Y distances
to a point.

Code: [Select]
              B
              /|
    / |    The distance from A to B is the hypotenuse of a right triangle, with X and Y
   /  |    as the legs.
  /   | Y
 /    |    Distance^2 = X^2 + Y^2     Take the square root, and we have:
/     |
A------+    Distance = SQRT(X^2 + Y^2)
            X

Now, we have worked with the sides, what about the angles?  The angles between two sides is the ammount
of rotation between them:

Code: [Select]
 |
  |          \                         /
  |           \                       /
  |            \                     /
  | 90 degrees  \   135 degrees     /  45 degrees
  |              \                 /
  +---------      --------        ---------

Somtimes we want to rotate a sprite or an object around a point.  Like this:

Code: [Select]
ZStandard
ZInteger
AxesOff
ClrDraw
For(F,0,360,5
Pt-On(29cos(F),29sin(F
End

What??? How did i just do that? Well the answer lies in trig, and in right triangles.  You may not think
that triangles have much to do with circles, but in fact, they have everything to do with eachother.
A circle contains all the points a certain radius from a center point.  So given a radius, there are
different X,Y points that lie onto a circle.  Does this look farmiliar?  Look again at the distance formula:

Distance = SQRT(X^2 + Y^2)

If we say that Distance is the radius, this distance equation becomes the equation of a circle!  :O
It gives us an euqation, where if we have a radius (distance) and an X or Y value, we can find the
other coordinate.  

Try solving the distance equation for Y

Distance = SQRT(X^2 + Y^2)
Distance^2 = X^2 + Y^2
Distance^2 - X^2 = Y^2
SQRT(Distance^2 - X^2) = Y

Y = SQRT(Distance^2 - X^2)

Try putting this into Y1 in your calculator, set Distance to 5 lets say, and graph it!  You get a circle!
(or half of one anyway... stupid functions...)

Wow, thats really cool, we can get a circle without doing any trig at all!



Now comes the final challenge, using the above equation, we can find all of the points on a circle, given
the radius, but what if we want a singe point?  We already have the radius, but we do not have any other

variables
to determine which point to use.  We need another, and that is the angle.  A circle goes accross 360 degrees
or angle, starting at the rightmost point at 0 degrees and rotating accross the circle counterclockwise until
it gets to 360 degrees, where it started.

Now it is time to introduce Sin, Cos, and Tan.  These functions pertain to triangles and their angles, and are
all very usefull.  For right triangles, you only take the sin, cos, or tan of angles that are NOT the Right

Angle
So for this triable they would be AC and BC

Code: [Select]
      |\ Sin of an angle equals the opposite leg over the hypotenuse
      | \ Sin(BC) = A/C Sin(AC) = B/C
  a   |  \ C    (hypotenuse) Cos of an angle equals the adjecent leg over the hypotenuse
(leg) |   \ Cos(BC) = B/C Sin(AC) = A/C
      |    \ Tan of an angle equals the opposite over the adjecent
      +----- Tan(BC) = A/B Tan(AC) = B/A
         b (leg)

These trigonometric equations give us some interesting power.  If we know Hypotenuse C and Angle BC,
we can find leg A.

Sin(BC) = A/C
Sin(BC)*C = A
A = Sin(BC)*C

And we can also find leg B as well

Cos(BC) = B/C
Cos(BC)*C = B
B = Cos(BC)*C

Do you know what this meants?  Given a distance, and an angle, we can find the coordinates of that point!

Code: [Select]
              B
              /|
    / |  
   /  |    
  /   | Y
 /    |  
/     |
A------+    
            X

Given the angle at A, and the distance AB, we can calculate the distances X and Y, which are the coordinates of
Point B.

X = R*Cos(A)
Y = R*Sin(B)

its that simple!  And for all angles, point B will be a distance of R form the center, which is the
*exact* definition of a circle!  Given an angle and a radius, using these two equations we can find a
specific point on a circle.

This program shows how the triangles fit into the circle as it travels around the circle:

Code: [Select]
ZStandard
ZInteger
AxesOff
ClrDraw
Degree
0->F

Circle(0,0,30
While 1
Line(0,0,A,B,0 //hypotenuse
Line(0,0,A,0,0 //right leg
Line(A,0,A,B,0  //left leg
29Cos(F)->A //find the coordinates of the next point on the circle
29Sin(F)->B
Line(0,0,A,B
Line(0,0,A,0
Line(A,0,A,B
F+5->F
End

4409
Portal X / Re: Portal X
« on: April 07, 2010, 12:46:26 am »
There is a possibility that turrets are going to be implemented, but for now all that is planned is environmental hazards like lasers, electric fields, spikes, ect...

4410
Humour and Jokes / Re: Girls interested in games, and calculators! D:
« on: April 07, 2010, 12:38:20 am »
Lol whats going on this night?? Everybody seems to be playing around with you DJ ;D

Pages: 1 ... 292 293 [294] 295 296 ... 375