Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Ball Sub - draws several kind of filled, textured balls (circles)
#11
Hey @dbox, when I was working on the last update I came across a possible QBJS error, thought I'd mention it.  I narrowed it down to this: It errors out when this is on the same line: 
_Display: If displayStatus%% = 1 Then _AutoDisplay

But it works OK when splitting that up on two lines iistead.  Here's a snippet showing that.  You can comment it out an uncomment the workaround way to see.

- Dav


Find my programs here in Dav's QB64 Corner
Reply
#12
Might be confounded by the function of the same name?

This might give somebody an epileptic seizure. I ran it for a few seconds, couldn't take it much more. So many patterns! Also using alpha channel. It would have taken me the rest of my life to do anything like this.

This is not a reproach. I expected the program to display a separate ball for each technique, maybe going in a loop until [ESC] is pressed to show the possibilities. Combine this with JDJ's planet-maker. Cool
Reply
#13
I dunno.  Maybe.  Only know that line bugs it out for some reason.  Yeah, I just set it up to loop balls like that only to demo all of them quick.  The SUB should be used differently for other programs.  (And I sincerely hope this doesn't cause anyone to have a seizure!) 

Hey - I remember that planet maker program posted a while back  - that was cool.  You give me an idea to work on, a "Moon' looking ball with craters.

- Dav

Find my programs here in Dav's QB64 Corner
Reply
#14
(08-23-2023, 05:44 PM)Dav Wrote: Hey @dbox, when I was working on the last update I came across a possible QBJS error, thought I'd mention it.  I narrowed it down to this: It errors out when this is on the same line: 
_Display: If displayStatus%% = 1 Then _AutoDisplay

But it works OK when splitting that up on two lines instead.
Thanks @Dav, I've seen this issue before but it doesn't look like I ever logged it. 

I have now:  https://github.com/boxgaming/qbjs/issues/79

I'll look at getting that fixed in the next release.
Reply
#15
@DAV great balls. This could be a lot of fun making some puzzle type games, etc!

Could you make them a certain color? While maintaining the texture/patterns?

That could be super fun to make puzzles with.
grymmjack (gj!)
GitHubYouTube | Soundcloud | 16colo.rs
Reply
#16
Thanks, @grymmjack.  Yes, the color can be specified with the r,g,b,a values, for Red/Green/Blue/Alpha.

Usage:  ball (kind, x, y, size, r, g, b, a) 

Example, A gradient ball (0), at x/y location of 200,200, size of 50, Full Red color with no alpha transparency (255,0,0,255).

ball 0, 200, 200, 50, 255, 0, 0, 255

- Dav

Find my programs here in Dav's QB64 Corner
Reply




Users browsing this thread: 1 Guest(s)