Page 2 of 11

Posted: Sun Feb 05, 2006 2:04 am
by blueznl
i had so many requests for this so i finally gave in... you can now download a downloadable copy of the survival guide... visit the pages and download it if you want, note that it's just a bunch of html files grouped together but it works, sort of

here's the direct download link

http://www.xs4all.nl/~bluez/datatalk/survival_guide.arj

Posted: Sun Feb 05, 2006 2:38 am
by Intrigued
blueznl wrote:i had so many requests for this so i finally gave in... you can now download a downloadable copy of the survival guide... visit the pages and download it if you want, note that it's just a bunch of html files grouped together but it works, sort of

here's the direct download link

http://www.xs4all.nl/~bluez/datatalk/survival_guide.arj
Unless you keep repackaging folks may want to still consider coming back to your pages online for up-to-date coverage?

Posted: Sun Feb 05, 2006 8:42 am
by blueznl
that would be smarter, yes :-)

(though repackaging is done by a little batch file, so it ain't that bad :-) i just tend to forget to do that :-))

Posted: Sun Feb 05, 2006 8:49 am
by Dare2
Ah. Arj! * fires up 7zip *

Thanks, blueznl. It will be handy as a general offline reference!

Posted: Sun Feb 05, 2006 9:49 am
by blueznl
yeah i admit i'm an oldie by now

to be honest, wanted to zip it first, but found out i don't have a command line zip thingy installed anymore :-)

besides, i always liked arj and arj32 just that little bit more...

Posted: Mon Feb 06, 2006 9:38 pm
by blueznl
slight update / error correction on the unicode part...

Posted: Sat Feb 11, 2006 5:27 pm
by Andre
@blueznl: thanks for your hard work :!: :D

I would be happy if you agree to release the offline version on tutorials page on www.PureArea.net :)

Posted: Sat Feb 11, 2006 5:39 pm
by srod
This really is outstanding work. Well done, and thanks.

Posted: Sat Feb 11, 2006 11:52 pm
by blueznl
andre, how do you mean? you want to host the .arj file or something? if so go ahead :-)

Posted: Sun Feb 12, 2006 1:20 am
by Andre
blueznl wrote:andre, how do you mean? you want to host the .arj file or something? if so go ahead :-)
Exactly (probably as .zip too) - so thanks. :D

Posted: Wed Feb 15, 2006 8:00 pm
by akee
Hmmmm.... The doc still states that PB is 59 euro. I think it is now US$69... :)

Posted: Wed Feb 15, 2006 8:17 pm
by Fred
there is both prices in fact.

Posted: Wed Feb 15, 2006 8:44 pm
by blueznl
akee wrote:Hmmmm.... The doc still states that PB is 59 euro. I think it is now US$69... :)
don't forget, the guide is totally unofficial unsupported and pretty much useless anyway, so i can get away with anything i say, sort of :-)

Posted: Sat Nov 25, 2006 1:19 pm
by Trond
Either there are some errors and omissions with your description of PB's type conversions, or there's some bugs in PB. :wink: You and Fred should decide what these are.
expressions are evaluated left to right
Unless you're really unlucky:

Code: Select all

Procedure Test(b)
  Debug b
EndProcedure

; This is evaluated from right to left
c = Defined(a, #PB_Variable) + a + Defined(a, #PB_Variable)
Debug c

; From the middle and outwards to the sides?!?!?!?
Test(Defined(z, #PB_Variable) + z + Defined(z, #PB_Variable))
types 'change upwards' in this sequence: long> quad > float > double
types never change 'downwards'

Code: Select all

a.l
f.f
d.d

; Type changes downwards from float to long here
;             V
q.q = 2*(92/8.+5)
Debug q

; And here    V
Debug 2*(92/8.+5)

a = 2*(92/8.+5)
Debug a

f = 2*(92/8.+5)
Debug f

d = 2*(92/8.+5)
Debug d

Code: Select all

f.f
q.q

; The type changes here from quad to long to float
; That's downwards from quad to long
;     V
a = q + f
Note that not only the Cos() itself, but also the parameters of Cos() can force a typechange!

Code:

a.f = Cos(z.f)+10*22
b.f = Cos(z.d)+10*22

In the above the expression behind a.f is evaluated as a float, whilst the one behind b.f is evaluated as a double
That makes it sound as if that was the case for all functions, but actually Cos() is a special "overloaded" function that returns a float if passed a float and returns a double if passed a double. Only the return type of a function can force a typechange.

Posted: Sat Nov 25, 2006 1:48 pm
by Trond
a.f = 3
b.l = 1 + 2 / a.f

Notice the mathematic priority! It's NOT going to do something like ( 1 + 2 ) / 3 but it does 1 + ( 2 / 3 ). However, it will not start with typing a float as it still works from left to right.
Here, the 1 will acutally be treated as a float although you give the impression that that will not happen. Why?
Because: 2/a.f is a float, and when you add a constant and a float the result is a float. Also, the result of the entire expression is a float because if the 1 was a long it would be converted. It would be faster to add after the division because that would make the convertion more efficient, but the result is the same, the integer at 1 will be converted to a float.
h.q[10,10] ; takes 10x10x4 = 400 bytes (an array of 10 by 10 quads)
How many bytes does a quad use?

A 'global' variable can be changed from anywhere in the program, except under the following conditions:
another variable with the same name is declared Protected or Static inside a procedure
the same variable name was used as a parameter in a procedure definition
And, it cannot be changed before it was declared as global.

Variables are always local to the procedure they are defined in.
Unless, they are declared as global inside that procedure.