Author Topic: 0.12.13 Released  (Read 956 times)

chrisws

  • Moderator
  • Newcomer
  • *****
  • Posts: 11
    • View Profile
0.12.13 Released
« on: 13. September 2018, 12:35:41 »
SmallBASIC 0.12.13 is now available.

There's not a huge list of changes, but a few nice things.

- Pressing F2 in the editor now loads the help page in the new web site.
- Pressing F11 now toggles full-screen mode.
- Fixed the SEQ bug

Plus some other changes you can read about here:

http://smallbasic.github.io/posts/2018-09-13.html

Cheers,
Chris

PS: Check my new android game "Air cave"



B+

  • Hero Member
  • *****
  • Posts: 764
    • View Profile
Re: 0.12.13 Released
« Reply #1 on: 13. September 2018, 16:24:27 »
Ah good! Tested window sizing with Johnno's Parallax Image Test mod 2018-02-04 (attached) now mod'd again today.

Oh my full screen is full!, good bye task bar access. f2 works Window (help reference) is under graphics, I guessed System first.

« Last Edit: 13. September 2018, 16:27:42 by B+ »

B+

  • Hero Member
  • *****
  • Posts: 764
    • View Profile
Re: 0.12.13 Released
« Reply #2 on: 13. September 2018, 18:02:41 »
Another test of Window .ask
Code: [Select]
' window ask test.bas SmallBASIC 0.12.13 (B+=MGA) 2018-09-13

w = window()
w.ask("Would you like to test a yes or no question?", "Test a Yes/No Question")
? "You selected ";
if w.answer then print "No." else print "Yes."
pause



chrisws

  • Moderator
  • Newcomer
  • *****
  • Posts: 11
    • View Profile
Re: 0.12.13 Released
« Reply #3 on: 17. September 2018, 12:54:43 »
Script BASIC using MsgBox.
I've just build the newest version from source on 32-bit Linux and it seems to work fine. :)

Hi Tomaaz,

If you are okay with building from source code there's something you might like to try:

1. clone or download the SmallBASIC plugins project:
$ git clone https://github.com/smallbasic/smallbasic.plugins.git

2.  build the plugins project
$ ./configure && make

3. setup environment variable SBASICPATH, something like this:
export SBASICPATH=/home/chrisws/src/smallbasic.plugins/nuklear/.libs

4. switch over to your SmallBASIC checkout, then
$ ./configure && make

5. Run the nuklear overview.bas sample:
./src/platform/console/sbasic ../smallbasic.plugins/nuklear/samples/overview.bas

You should see something like the attached image

Here's a link to the overview.bas program:
https://github.com/smallbasic/smallbasic.plugins/blob/master/nuklear/samples/overview.bas


« Last Edit: 17. September 2018, 13:01:04 by chrisws »

Tomaaz

  • Full Member
  • ***
  • Posts: 213
    • View Profile
Re: 0.12.13 Released
« Reply #4 on: 30. September 2018, 17:50:24 »
To be honest - I'm not scared of compiling from source, but I wouldn't say I'm a fan. ;) I will try. Is step 4 compiling SmallBasic itself or do I need to do all steps after I have SmallBasic already build?

Tomaaz

  • Full Member
  • ***
  • Posts: 213
    • View Profile
Re: 0.12.13 Released
« Reply #5 on: 03. October 2018, 20:07:53 »
Doesn't work, unfortunately:

Quote
Opened: overview.bas 3445 bytes


 * COMP-ERROR AT Main:0 *
Description:
Unit nuklear.sbu not found or wrong version


chrisws

  • Moderator
  • Newcomer
  • *****
  • Posts: 11
    • View Profile
Re: 0.12.13 Released
« Reply #6 on: 26. October 2018, 10:52:04 »
The error indicates the .so file (equivalent to .dll in windows) was not found in the environment variable SBASICPATH

Could you please try pasting this in the console/bash:

$ env | grep SBASICPATH

Then check to ensure this references the location of where you build the plugin code.

Tomaaz

  • Full Member
  • ***
  • Posts: 213
    • View Profile
Re: 0.12.13 Released
« Reply #7 on: 26. October 2018, 19:36:53 »
I was able to fix it. It works fine.

Tomaaz

  • Full Member
  • ***
  • Posts: 213
    • View Profile
Re: 0.12.13 Released
« Reply #8 on: 26. October 2018, 19:51:33 »
But I've tried other examples and it looks like there is something wrong with circle (see screenshot).

B+

  • Hero Member
  • *****
  • Posts: 764
    • View Profile
Re: 0.12.13 Released
« Reply #9 on: 27. October 2018, 09:17:48 »
Looks like a poor test of DRAWPOLY what is code for that?

Tomaaz

  • Full Member
  • ***
  • Posts: 213
    • View Profile
Re: 0.12.13 Released
« Reply #10 on: 27. October 2018, 18:28:08 »
Code: [Select]
nk.circle("line", x + 130, y + 140, 110)

When I say "circle" I mean... circle.

B+

  • Hero Member
  • *****
  • Posts: 764
    • View Profile
Re: 0.12.13 Released
« Reply #11 on: 27. October 2018, 19:17:13 »
Code: [Select]
nk.circle("line", x + 130, y + 140, 110)

When I say "circle" I mean... circle.

If you mean circle why does it say line?  ;D

Tomaaz

  • Full Member
  • ***
  • Posts: 213
    • View Profile
Re: 0.12.13 Released
« Reply #12 on: 27. October 2018, 19:32:50 »
You can change it to "fill" if you wish, but the resulting circle will be as bad. I thought you were SmallBasic expert here...

B+

  • Hero Member
  • *****
  • Posts: 764
    • View Profile
Re: 0.12.13 Released
« Reply #13 on: 27. October 2018, 20:53:03 »
Well this "expert" thinks you are NOT showing all of the code sample.
Code: [Select]
rem adapted from love-nuklear example, see: https://github.com/keharriso/love-nuklear.git

import nuklear as nk
color rgb(128,54,0), 1
option predef grmode 304x304

while 1
  if nk.windowBegin("Draw Example", 2, 2, "100%", "100%") then
    [x, y, w, h] = nk.windowGetBounds()
    nk.line(x + 10, y + 40, x + 50, y + 40, x + 50, y + 80)
    nk.curve(x + 50, y + 80, x + 80, y + 40, x + 100, y + 80, x + 80, y + 80)
    nk.polygon("line", x + 100, y + 150, x + 60, y + 140, x + 70, y + 70)
    nk.circle("line", x + 130, y + 140, 50)
    nk.ellipse("fill", x + 30, y + 150, 20, 40)
    nk.arc("fill", x + 150, y + 80, 40, 3 * PI / 2, 2 * PI)
    nk.rectMultiColor(x + 95, y + 50, 50, 50, "#ff0000", "#00ff00", "#0000ff", "#000000")
    'nk.image(img, x + 120, y + 120, 70, 50)
    nk.text("DRAW TEXT", x + 15, y + 75, 100, 100)
  endif
  nk.windowEnd()
wend

« Last Edit: 27. October 2018, 21:11:34 by B+ »

Tomaaz

  • Full Member
  • ***
  • Posts: 213
    • View Profile
Re: 0.12.13 Released
« Reply #14 on: 27. October 2018, 21:09:22 »
I'm showing only the part I have problem with. Do you really think I'm not able to find which part is responsible for that "circle" on the screen? Please, give me some credit. The whole example (and two more) comes with SmallBASIC plugins project, so you can easily test it  yourself.