Welcome, Guest
You have to register before you can post on our site.

Username/Email:
  

Password
  





Search Forums

(Advanced Search)

Forum Statistics
» Members: 308
» Latest member: Donaldvem
» Forum threads: 1,741
» Forum posts: 17,901

Full Statistics

Latest Threads
The QB64 IDE shell
Forum: Utilities
Last Post: JasonPag
09-16-2024, 05:37 PM
» Replies: 9
» Views: 762
Importance regarding Ches...
Forum: Utilities
Last Post: JasonPag
09-01-2024, 06:34 PM
» Replies: 0
» Views: 31
Chess and Analysis and En...
Forum: Utilities
Last Post: JasonPag
08-28-2024, 02:37 PM
» Replies: 0
» Views: 32
DAY 009:_PutImage
Forum: Keyword of the Day!
Last Post: grymmjack
09-02-2023, 02:57 PM
» Replies: 54
» Views: 2,034
Fall Banner Contest?
Forum: Site Suggestions
Last Post: grymmjack
08-31-2023, 11:50 PM
» Replies: 36
» Views: 1,261
ColorPicker - Function th...
Forum: Dav
Last Post: Dav
08-31-2023, 11:04 PM
» Replies: 3
» Views: 315
Goals(1) = New Tile()
Forum: Works in Progress
Last Post: RhoSigma
08-31-2023, 09:45 PM
» Replies: 3
» Views: 127
micro(A)v11
Forum: QBJS, BAM, and Other BASICs
Last Post: bplus
08-31-2023, 09:14 PM
» Replies: 90
» Views: 3,589
Updating The Single Most ...
Forum: QBJS, BAM, and Other BASICs
Last Post: bplus
08-31-2023, 09:13 PM
» Replies: 7
» Views: 254
QBJS Image Question
Forum: QBJS, BAM, and Other BASICs
Last Post: bplus
08-31-2023, 05:49 PM
» Replies: 5
» Views: 155

 
  Tech Invaders 4 Warp Edition
Posted by: SierraKen - 06-29-2022, 06:01 PM - Forum: Programs - Replies (6)

Hi all,

Below are the additions to this version of Tech Invaders. I'm really happy with this version. Here's a photo too. Tell me what you think, thanks. As with version 3, this is also controlled with the mouse.

-SierraKen

Additions: A Warp Starfield Backdrop, 5 different Boss Robots total, small change to the enemy explosion sounds, a fix to the enemy shot which will now be deleted as soon as the enemy is destroyed.

And various other small fixes.
There is no ending to this game, after the 5th Boss Robot, it will go back to the first but your points and levels will remain increasing.



[Image: Tech-Invaders-4-Warp-Edition-by-Sierra-Ken.jpg]

Code Deleted, a better version is below that doesn't have high pitched explosions. A YouTube video of the newer one is also below.

Print this item

  VB5 - Decimal places are missing
Posted by: Kernelpanic - 06-29-2022, 04:25 PM - Forum: Help Me! - Replies (5)

A VB5 program, almost like QBasic. - The decimal places are not calculated, but why not? I just can't find the error. Everything is the same as the 2nd screenshot, everything is correct there.

Does anyone know where the error is? Thanks.

[Image: Angebot-VB5-Nachkomma-Fehlt.jpg]

Print this item

  XP-compatibility
Posted by: BG 7 - 06-29-2022, 10:17 AM - Forum: Help Me! - Replies (6)

How about the Win XP-compatibility of QB64 Phoenix Edition ?

After having compiled our program with QB64pe v.0.80 the exe-file doesn't run on Win XP:
"Error execuring program"!
(No problems at all using Win 10)

Is it possible to use earlier versions of QB64 (or QB64 Phoenix Edition in the future)
to compile XP-compatible exe-files ?

Thanks for any hints !

Print this item

  CMYK color
Posted by: James D Jarvis - 06-29-2022, 03:35 AM - Forum: Utilities - Replies (1)

CMYK or process color is the model used in print. I spent years doing print work and just find it easier to mix colors using that color model. 
Each color is expressed as a % of Cyan C, Magenta M, Yellow Y, and Black K
White is 0,0,0,0
Red is 0,100,80,0 to 0,100,100,0
Greys are 0,0,0,1 to 99   or C,M & Y set to the same value from 1 to 99



Code: (Select All)
Screen _NewImage(640, 480, 32)
Color _RGB32(0, 0, 0), _RGB32(255, 255, 255)
Cls
'a simple demo of the color values
Do
    Print "Enter C,M,Y,K"
    Input c, m, y, k

    k& = cmyk~&(c, m, y, k)

    Line (200, 200)-(400, 400), k&, BF
Loop Until c = -100


Function cmyk~& (c As Long, m As Long, y As Long, k As Long)
    ' CMYK process color Cyan, Magenta, Yellow, Black each  expressed as a percent from 0 to 100
    r = 255 * (100 - c)
    r = (r / 100) * ((100 - k) / 100)
    g = 255 * (100 - m)
    g = (g / 100) * ((100 - k) / 100)
    b = 255 * (100 - y)
    b = (b / 100) * ((100 - k) / 100)
    cmyk~& = _RGB32(r, g, b)
End Function

Print this item

Sad qb64 0.8.2 - Compilation problem on Linux.
Posted by: Fifi - 06-29-2022, 03:16 AM - Forum: Announcements - Replies (10)

Hello,

I don't know if it's the new way to create qb64 (using a make file) but there is kind of a problem on Linux.

Yes, both the qb64 executable itself and the executable it creates can't be started anymore with a double click on their relevant file icon.

You still can launch qb64 with the command "./qb64" (when you're in its folder), but there was not this problem with the 2.0.2 nor with any other previous releases.

Question: just to make a test, is it still possible to compile QB64 Phoenix Edition with the method of the previous 2.0.2 setup_lnx.sh bash script?

If yes, what are the modifications (if any) to make to that previous bash script to successfully compile qb64 0.8.2 ?

Another "glitch": if you place qb64 into a folder with a name containing a space (e.g. "/home/me/qb64 official"), then the run_qb64.sh bash script generated by the setup_lnx.sh bash script will not work.

TIA
Cheers.
Fifi

Print this item

  Forum animated avatar specs
Posted by: doppler - 06-28-2022, 09:54 AM - Forum: Help Me! - Replies (1)

Old forum pre phoenix had animated avatars.  I saved my gifs (changed them semi often).  My avatar here should be moving.

What are the limits X, Y, BBP and file size ?

Print this item

Lightbulb My new Linux install script for QB64 Phoenix Edition
Posted by: Fifi - 06-26-2022, 06:05 AM - Forum: General Discussion - Replies (5)

Hello all,

I've updated my multi lingual (English, French, German, Italian, Portugese and Russian) Linux installation script that now install (and can smoothly uninstall) the current version of QB64 Phoenix Edition and InForm 1.3 together.

I'm still working on it to propose making a backup before uninstalling, translating in Ukrainian as well ass other goodies.

You can get my script on my web server here: multi lingual Linux install script

This is why I'd appreciate to be able to automatically downloads a kind of "last stable" release, always at the same place and with the same name (so, no numbering, the date of the file is enough) without being obliged i) to check every day if there is a new build, ii) then to modify the script for each new release in order to propose this script to be officially included in the project.

Then the users would have to only download this small script like it was possible few years ago on ab64.org.

Please let me know what you think?
Cheers.
Fifi

Print this item

  Triangles with line thickness
Posted by: James D Jarvis - 06-24-2022, 12:22 AM - Forum: Utilities - No Replies

A couple subs for drawing triangles with a line thickness over 1 pixel.

Code: (Select All)
Screen _NewImage(800, 500, 32)
'Filled triangles with lines with a defined thickness
'you can make an empty circle by assigning a value of 0 to the fill color
Locate 16, 8: Print "FatTriangle  x1,y1,x2,y2,x3,y3,thickness,linecolor,fillcolor"
Locate 14, 25: Print "TrimTriangle  x1,y1,x2,y2,x3,y3,thickness,linecolor,fillcolor"
Locate 11, 33: Print "BlendTriangle  x1,y1,x2,y2,x3,y3,thickness,linecolor,fill1,fill2"
Locate 27, 8: Print "FatTriangle  x1,y1,x2,y2,x3,y3,thickness,linecolor,fillcolor"
Locate 28, 8: Print " the fill color can be set to 0 so you can draw an unfilled rectangle"

fattriangle 101, 101, 130, 130, 130, 200, 4, _RGB32(150, 100, 50), _RGB32(200, 150, 100)

trimtriangle 201, 101, 230, 10, 230, 200, 2, _RGB32(150, 100, 50), _RGB32(200, 150, 100)

blendtriangle 301, 101, 330, 10, 430, 150, 3, _RGB32(150, 100, 50), _RGB32(200, 150, 50), _RGB32(190, 190, 50)


trimtriangle 11, 301, 30, 360, 100, 400, 2, _RGB32(150, 100, 50), 0 'yeah it's empty use fill color 0 to just draw a triangle
trimtriangle 31, 301, 50, 360, 110, 400, 2, _RGB32(150, 100, 50), 0


Sub blendtriangle (x1, y1, x2, y2, x3, y3, TT, lc&, f1&, f2&)
    'draw a filled triangle with a border with a defined thickness

    fx = x1
    If x2 < fx Then fx = x2
    If x3 < fx Then fx = x3
    XX = x1
    If x2 > XX Then XX = x2
    If x3 > XX Then XX = x3
    YY = y1
    If y2 > YY Then YY = y2
    If y3 > YY Then YY = y3
    sr = _Red(f1&)
    er = _Red(f2&)
    sg = _Green(f1&)
    eg = _Green(f2&)
    sb = _Blue(f1&)
    eb = _Blue(f2&)
    rr = (er - sr) / (XX - fx)
    gg = (eg - sg) / (XX - fx)
    bb = (eb - sb) / (XX - fx)
    rc = sr: gc = sg: bc = sb
    tri& = _NewImage(XX + 1, YY + 1, 32)
    _Dest tri&
    For lx = fx To XX
        Line (lx, 0)-(lx, YY), _RGB32(rc, gc, bc)
        rc = rc + rr
        gc = gc + gg
        bc = bc + bb
    Next lx
    fatLine x1, y1, x2, y2, TT, lc&
    fatLine x2, y2, x3, y3, TT, lc&
    fatLine x3, y3, x1, y1, TT, lc&

    _Dest 0
    _MapTriangle _Seamless(x1, y1)-(x2, y2)-(x3, y3), tri& To(x1, y1)-(x2, y2)-(x3, y3)
    _FreeImage tri& '<<< this is important!

End Sub


Sub trimtriangle (x1, y1, x2, y2, x3, y3, TT, lc&, fc&)
    'draw a filled triangle with a border with a defined thickness
    XX = x1
    If x2 > XX Then XX = x2
    If x3 > XX Then XX = x3
    YY = y1
    If y2 > YY Then YY = y2
    If y3 > YY Then YY = y3
    tri& = _NewImage(XX + 1, YY + 1, 32)
    _Dest tri&
    fatLine x1, y1, x2, y2, TT, lc&
    fatLine x2, y2, x3, y3, TT, lc&
    fatLine x3, y3, x1, y1, TT, lc&
    px = (x1 + x2 + x3) / 3
    py = (y1 + y2 + y3) / 3
    If fc& <> 0 Then Paint (px, py), fc&, lc&
    _Dest 0
    _MapTriangle _Seamless(x1, y1)-(x2, y2)-(x3, y3), tri& To(x1, y1)-(x2, y2)-(x3, y3)
    _FreeImage tri& '<<< this is important!

End Sub




Sub fattriangle (x1, y1, x2, y2, x3, y3, TT, lc&, fc&)
    'draw a triangle with points on lines built by circles to make a line thicker then 1 pixel.
    fatLine x1, y1, x2, y2, TT, lc&
    fatLine x2, y2, x3, y3, TT, lc&
    fatLine x3, y3, x1, y1, TT, lc&

    px = (x1 + x2 + x3) / 3
    py = (y1 + y2 + y3) / 3
    If fc& <> 0 Then Paint (px, py), fc&, lc&
End Sub


Sub fatLine (x0, y0, x1, y1, TT, kk As _Unsigned Long)
    If Abs(y1 - y0) < Abs(x1 - x0) Then
        If x0 > x1 Then
            fatLineLow x1, y1, x0, y0, TT, kk
        Else
            fatLineLow x0, y0, x1, y1, TT, kk
        End If
    Else
        If y0 > y1 Then
            fatLineHigh x1, y1, x0, y0, TT, kk
        Else
            fatLineHigh x0, y0, x1, y1, TT, kk
        End If
    End If
End Sub
Sub fatLineLow (x0, y0, x1, y1, tt, kk As _Unsigned Long)
    dx = x1 - x0
    dy = y1 - y0
    yi = 1
    If dy < 0 Then
        yi = -1
        dy = -dy
    End If
    'D = (2 * dy) - dx
    d = (dy + dy) - dx
    y = y0

    For x = x0 To x1
        CircleFill x, y, tt, kk

        If d > 0 Then
            y = y + yi
            ' D = D + (2 * (dy - dx))
            d = d + ((dy - dx) + (dy - dx))
        Else
            ' D = D + 2 * dy
            d = d + dy + dy
        End If
    Next x
End Sub
Sub fatLineHigh (x0, y0, x1, y1, tt, kk As _Unsigned Long)
    dx = x1 - x0
    dy = y1 - y0
    xi = 1
    If dx < 0 Then
        xi = -1
        dx = -dx
    End If
    ' D = (2 * dx) - dy
    D = (dx + dx) - dy
    x = x0

    For y = y0 To y1
        CircleFill x, y, tt, kk

        If D > 0 Then
            x = x + xi
            ' D = D + (2 * (dx - dy))
            D = D + ((dx - dy) + (dx - dy))
        Else
            ' D = D + 2 * dx
            D = D + dx + dx
        End If
    Next y
End Sub
Sub CircleFill (CX As Long, CY As Long, R As Long, C As _Unsigned Long)
    'sub by SMcNeill makes a filled circle without worrying about using the paint comamnd to fill an empty circle
    Dim Radius As Long, RadiusError As Long
    Dim X As Long, Y As Long
    Radius = Abs(R): RadiusError = -Radius: X = Radius: Y = 0
    If Radius = 0 Then PSet (CX, CY), C: Exit Sub
    Line (CX - X, CY)-(CX + X, CY), C, BF
    While X > Y
        RadiusError = RadiusError + Y * 2 + 1
        If RadiusError >= 0 Then
            If X <> Y + 1 Then
                Line (CX - Y, CY - X)-(CX + Y, CY - X), C, BF
                Line (CX - Y, CY + X)-(CX + Y, CY + X), C, BF
            End If
            X = X - 1
            RadiusError = RadiusError - X * 2
        End If
        Y = Y + 1
        Line (CX - X, CY - Y)-(CX + X, CY - Y), C, BF
        Line (CX - X, CY + Y)-(CX + X, CY + Y), C, BF
    Wend
End Sub

Print this item

  RS232 made easier. No guessing.
Posted by: doppler - 06-23-2022, 09:30 PM - Forum: Utilities - No Replies

All free to boot.  Only requires 2 comm ports and null modem cable (adapter), (and or another 1:1) cable.  With this free software, you can be "man in the middle" (MITM).  If you know what MITM means than you will definitely want this software.

https://www.compuphase.com/software_termite.htm

If you are going to do any RS232 QB64 programming.  YOU WILL WANT THIS.  If you want to re-engineer an old dos program using 232.  YOU WILL WANT THIS.  If you want to analyze any RS2332 stream.  YOU WILL WANT THIS.

This does require a windows machine to run (win2000 and beyond).

Print this item

  Tech Invaders 3
Posted by: SierraKen - 06-23-2022, 12:59 AM - Forum: Programs - Replies (8)

This is a new and improved version of my old Tech Invaders 2 I made a few years ago. This version uses your mouse to control your shooter back and forth and press the button to fire. 
I also changed the looks of your shooter and the enemies as well as different sounds. As with Tech Invaders 2, this will automatically generate a small text (.txt) file called toptentech.txt in the same directory you save this game in, which is for the Top Ten scores. It will save your score if you beat any of the current ones. Thanks goes to B+ and the rest of the gang a few years ago for some help. I did make version 2 when I was fairly new with QB64 so it probably has around 5 times more code than needed, but I didn't want to keep messing with over 1000 lines of code and countless variables to make it smaller. 
Enjoy!


Code deleted because of a much better version I posted below.

Print this item