123
-=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- (c) WidthPadding Industries 1987 0|632|0 -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=- -=+=-
Socoder -> JSE -> JSE - Jay's Scripting Engine

Page : 1 2 3 4 5 6 7 8 9 10 Prev 11 12 Next 13 14
Thu, 05 Aug 2021, 07:09
Jayenkai
This link should work... Let me know if it does. Though it might require a couple of clicks for the new version to update first.
lrTBGsBd.BAS

-=-=-
''Load, Next List!''
Thu, 05 Aug 2021, 13:36
Pakz
It works! The link itself does look a bit dangerous though
Thu, 05 Aug 2021, 14:19
Dan
Looks like these optical illusions !
Fri, 06 Aug 2021, 04:49
Jayenkai
Copy+Pasted from this morning's AGameAWeek blog.

-=-=-

There's a new button on the main GUI.
.. But what does it do!?!



You'll want to refresh to make sure your version of JSE is up to v3gen before the new button appears.
Hit the button and the current project gets uploaded to the server.
If it worked, you'll be given a unique link to your project which you can share online.
Click the screen to copy the link to your clipboard.

And that's about as complicated as it gets.

You CAN click it again to update the project, should you end up fixing it up or something.
The link will remain the same, and only the code will change.


The download key, and updater key are saved to your browser, and also exported/imported inside the .jse file when you use those functions in the folder view. This allows you to move from system to system, carry all your code with you, and have the ability to update projects.

Be absolutely sure that you do this, because if you lose that updater key, I (currently) have absolutely no way to let you update projects in the future.
Again, I'm trying my best to do everything without requiring you to log in, which will probably bite me in the arse later when people start abusing the functionality, but ... for now it's working "enough"!

Downloaded projects (eg, when you click a link) won't allow you to upload them back to the server.

Additionally, Duplicated projects (eg, if you click New Project then try to upload that, with it being identical to someone elses version) will appear to be uploading just fine, but will thereafter act like Downloaded projects.

I need to figure out a way to not do that permanently. I can imagine people starting a new project, and hitting upload instantly, then never being able to upload their project ever again.
Hmmm...

So, I'll be tweaking it during the day, to do what needs to be done. I also need to add some kind of moderation functionality into the mix, so I can double/triple check on things that are being uploaded.
But.. Yeah, it should work.
Be sure to let me know how broken it is, on your end

GotoJSE.com/WwdqwjnS.BAS

-=-=-
''Load, Next List!''
Sun, 08 Aug 2021, 08:53
Jayenkai
  --v

A few new commands for today.

Pen and Ink do the same thing, selecting from a predetermined set of colours. (Colour charts coming later, once I can be arsed, but .. If you know the CPC's 27 colours... Them! Unless you use UsePalette C64, in which case them, or UsePalette ZX which be those and BBC are that then.)

Paper uses the same colours, and "Border n" (Not Border r,g,b) also does, too.
Phew!!
The Pen/Paper/Ink/Border commands were seemingly different on all the different BASIC systems, so I've tried to make them as obvious as I can, but .. there are obviously differences from the originals as you'll remember them.
Sorry about that..


Tying myself up in knots with these commands, if I'm honest, and .. Oh boy, here comes Mode!!!

Mode 0-4, "System", ScaleMode
ScaleMode is the same as the Graphics command's third parameter. 0 for unscaled, 1 for scaled, 2 for scaled + fit to screen, 3 for Pixel scaled.

System is either "Hires" or the usual systems "CPC", "C64", "ZX", "BBC"
Then the mode number sets to one of a set of default resolutions.

The chart for modes and resolutions is available here, in the command list.
They should hopefully line up roughly to what you'd use for modes on those systems.
Unfortunately, the width-scaling thing doesn't quite work right, so for example, a CPC Mode 0 ends up squished, whereas it should be 2xpixel wide to fill the screen out.
I'm currently working on getting that to work.

Such a simple little command, but ... OH MY GOD!!!!

... Currently unfinished commands GamePadDistance and GamePadAngle will (eventually) tell you the angle+distance of the thumbtacks or DPad.
At the minute, they combine values of DPad and Left Thumbstick, as I've not yet added parameters to the mix.. But .. Yeah, that'll be the purpose of those.

-=-=-
''Load, Next List!''
Mon, 09 Aug 2021, 02:31
Pakz
I have been learning Lua. While reading about it I noticed they have this special version called LuaJit. The speed with this just in time compiler version was benched at the speed of regular c language. Though not always it is mentioned which version is used in which suite. I noticed one fantasy console on android that said they used this jit version.

I have no idea what a just in time system does though
Mon, 09 Aug 2021, 02:53
Jayenkai
"Compiling" would suggest taking the code and changing it directly into Javascript.
JSE doesn't do that. It does do a lot of tweaking to your code to make it easier to parse, but in the end it's still just parsing the script.

I have considered translating code to Javascript, but given browser securities I don't think I can do that directly in the browser.
Sending all your code, every time you click run, to the server, and spitting out Javascript that it can read and run, would indeed be quicker at running, but it would..
A) definitely require a server at the other end. Turn off your internet, and you *should* still be able to use JSE.
B) be slower when you click "run".. boooooo!!!
C) bog down the server... booooooo!!!

I've been avoiding that!

-=-=-
''Load, Next List!''
Sat, 14 Aug 2021, 09:09
Jayenkai
  --v

Gosh, that was a struggle to get going.
Right then.. New Framework.
Instead of "GameHandler("Game Name","Easy|Normal|Hard")" you can now use "GameHandler("Game Name","Calendar")" and you'll get a neatly presented calendar based "Time Tunnel"!!
It only displays dates for the current year, but each day of the year has its own Win parameter (WinLevel command) and also a highscore.

With this new menu system, you can easily make games with 365/6 levels.. Assuming you can create those levels.
I mean, you could also have entirely new adventures, and massive sprawling worlds for each day, instead of just a single level, but.. You get the idea..

.. Apologies that the mouse/touch interface is tap-only. I coded myself into a corner, there!!!

You'll want to refresh to get v.3geq for it to work.

-=-=-
''Load, Next List!''
Wed, 18 Aug 2021, 15:50
Jayenkai
  --v

*shrugs*

-=-=-
''Load, Next List!''
Wed, 18 Aug 2021, 17:06
shroom_monk
Pakz I have no idea what a just in time system does though


I only have a passing experience with JIT compilation, so my explanation might be a little shaky, but as I understand it:

When you have a language that runs in some kind of virtual machine (like Lua and Javascript do), you naturally get some overhead, so your program runs more slowly than it might if written in a language that compiles to machine code. But you don't want to just compile the whole program to machine code, because that can take a big block of time before you can run any code at all, and tends to defeat the point of using those kinds of languages in the first place.

Just-In-Time (JIT) compilation is a compromise. While running your program, the VM will keep an eye out for any small fragments of code that get run repeatedly. Such fragments of code are good candidates for optimisation, because even a small speed increase will be magnified by that code getting run many times. The VM will compile that bit of code into machine code in the background, and when it's done will drop that newly compiled machine code in where previously it would have run the original code fragment. If applied judiciously by the VM, the result ought to be that programs tend to run faster, without needing to compile the entire program.

I think most Javascript VMs used in web browsers these days use JIT compilation, so JSE probably already benefits from this without needing to explicitly implement anything like it!

-=-=-
A mushroom a day keeps the doctor away...

Keep It Simple, Shroom!
Thu, 19 Aug 2021, 02:52
Jayenkai
Yeah, if you load up JSE, run the Optimisationalism 2 test, you should find that once the Javascript JIT stuff has settled, the script should speed up quite a bit.

One of the things I've been trying to do lately is rewrite chunks of code to speed up that JIT stuff.
Replacing a couple of ifs with a switch/case* can sometimes make quite a difference, but in other situations, the opposite is true and where you "thought" a switch/case would be better suited, it actually turns out that the JIT compiler works better with a bunch of if's.
It's tricky to know what's best, but that's what optimisation's all about, right!?!
Hmm..

Writing scripts in ways that make it slightly easier for the Javascript to "compile" means having to write things in ways that my 80's BASIC mindset is not quite good at!!

Yeah, it'd be great if I could "actually compile" what's written in the JSE code box, but I'm fairly sure that'd mean having back+forth with the server. I don't think browser securities would allow me to do that.
To be honest, I've not really looked into it, yet, but I'm pretty sure it would be more hassle than it's worth.

-=-=-
''Load, Next List!''
Thu, 19 Aug 2021, 09:35
Jayenkai
A few ground tweaks, today.

Not should now function in basic ways. It's probably not foolproof, so let me know if you find any instances where it's misbehaving.
Minus numbers should also now function properly. .. I think.. Again, if they don't, let me know.
Third and also probably broken, I did a bunch of work on And/Or stuff, and am finding those just as difficult to trip up.

In all three cases, let me know if you spot any errors.
And also, I DID try my best not to break anything along the way, but .. Well, this is some fairly groundwork-based stuff, and a few important things had to be tweaked to get things working.

Aaagh!

-=-=-
''Load, Next List!''
Fri, 20 Aug 2021, 09:35
Jayenkai

View on YouTube

  --v

Ooooooohhhh...
I was expecting the C64 version to look vaguely similar, but .. Oh my god, it's freakin' identical!!!!

-=-=-
''Load, Next List!''
Sat, 21 Aug 2021, 04:09
Jayenkai
  --v

Swirly!

-=-=-
''Load, Next List!''
Sun, 22 Aug 2021, 10:09
Dan
Great, i could watch it for hours !

Reminds me of the windows lines screensaver.
Sun, 22 Aug 2021, 12:29
AndyH
Looking really nice!
Fri, 27 Aug 2021, 03:14
Jayenkai


Recent additions

You can now UsePalette "nes", "sms" or "atari" for NES, Sega Master System or Atari 2600 colour palettes.

The Flip buffer (frontbuffer/backbuffer stuff) is now active. I think I managed to get it working in a way that doesn't cause too much of a slowdown, but do please let me know if it gets too bad, and I'll add some kind of disabler or rework the methodology.
To activate it, simply use the Flip command once. Any further uses will update the screen, or otherwise won't.

I'll now get to work on alt-image buffers, and see if I can keep them going nice and fast. *shrugs*

-=-=-
''Load, Next List!''
Sat, 28 Aug 2021, 04:01
Jayenkai
  --v


-=-=-
''Load, Next List!''
Sun, 29 Aug 2021, 02:37
Dan
I have played around with the "Starfield with Nebulae" example.

I wanted to display text at the end of the example, so i have tried few things out, before i found the "ResetDraw" command in the help file.

Then i have noticed something odd.

Add this , at the end of the code



When you start it for the first time, it will run ok.
When you start it the next time, the Print "Hi" command will output some dots instead of "HI"

This will last until you refresh the page.

Then again, the 1st start will be normal and all others will have dots ...

(windows - Srware iron browser)
Sun, 29 Aug 2021, 02:49
Jayenkai
Grrr...
That's the text misaligning again.
More work needed there, methinks.



-=-=-
''Load, Next List!''
Sun, 29 Aug 2021, 04:58
Jayenkai
OK, updated again!!
Those darn text alignments, grrrr!!

Should now be a little more stable. Be sure to refresh to get up to version 3gfd.

-=-=-
''Load, Next List!''
Sun, 29 Aug 2021, 06:09
Jayenkai
Redid the Starfield+Nebulae.
This time around, the Nebulae are drawn to the BG buffer, then that's drawn alongside a scrolling starfield.
Mmmm..
Needs a decent system, though!

> Reveal 🔎

-=-=-
''Load, Next List!''
Sun, 29 Aug 2021, 12:34
shroom_monk
Those are some awesome looking nebulae!
Sun, 29 Aug 2021, 12:44
Jayenkai
Aye, not bad for a bunch of ovals!
Tue, 31 Aug 2021, 04:32

 
Jayenkai
Created : 31 August 2021
Edited : 31 August 2021
System : Cross Platform
Language : Basic

A Boatload of Balls

Throw your balls at the targets.

Open in JSE
Screenshots
 
Help Platdude shoot his balls at the targets. Row your boat to and from, fire the balls, and burst all the targets before landing the balls in the buckets.
Earn a score greater than 500 points for a Star.
Reach 1000 points for a BIG star!



SourceCode/GotoJSE > Reveal 🔎

 
Sat, 04 Sep 2021, 07:33
Dan
I was just playing around with the JSE and have noticed that the images/symbols are always drawn as 32x32 ?

  --v

Page : 1 2 3 4 5 6 7 8 9 10 Prev 11 12 Next 13 14