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 - zigzag

Pages: [1]
1
QB64 Discussion / Re: Is this fast enough as general circle fill?
« on: June 26, 2018, 07:01:16 am »
Hasn't anyone considered using this method?

Code: QB64: [Select]
  1. Radius% = 1000
  2. Cx% = Radius%
  3. Cy% = Radius%
  4.  
  5. FOR X% = 0 TO Radius%
  6.   Y% = SQR(Radius% * Radius% - X% * X%)
  7.   LINE (Cx% + X%, Cy% - Y%)-(Cx% + X%, Cy% + Y%)
  8.   LINE (Cx% - X%, Cy% - Y%)-(Cx% - X%, Cy% + Y%)

2
QB64 Discussion / Re: What is the point of DRAW "x" and PLAY "x" ?
« on: June 18, 2018, 06:01:41 pm »
Currently, no, I have a project that might involve PLAY, instead. Can I see that version of Draw you are talking about?

3
QB64 Discussion / Re: What is the point of DRAW "x" and PLAY "x" ?
« on: June 18, 2018, 03:09:09 pm »
Interesting. I see no one knows what was the purpose of the x command. Unfortunately, QBASIC guide is not clear, and many people believed it was necessary to use that weird syntax. But actually, on older versions of Microsoft Basic, there is a clue: on MSX Basic (that is pretty similar to GWBasic), the x command was supposed to be used like:

Quote
DRAW "xa$;"

https://www.msx.org/wiki/DRAW

It made no sense at all neither in GWBasic, nor in QBASIC... but after more than 30 years it's still here, because too many people don't know there is no need for it

4
QB64 Discussion / Re: What is the point of DRAW "x" and PLAY "x" ?
« on: June 18, 2018, 11:35:37 am »
Gwbasic, too, allowed the simpler syntax. And the use of x was different,  since it was followed by the variable's name

5
QB64 Discussion / What is the point of DRAW "x" and PLAY "x" ?
« on: June 18, 2018, 10:33:40 am »
Both QBasic, and QB64, accept any string with the DRAW or PLAY command. So, what is the point of:

Code: QB64: [Select]
  1. DRAW "x"+VARPTR$(A$)

when one can just use

Code: QB64: [Select]
  1. DRAW A$

that is much clearer?

Pages: [1]