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

Page : 1 2 3 4 Prev 5 6 Next 7 8 9 10 11 12 13 14
Tue, 18 May 2021, 04:37
Jayenkai
I think I need to add Data in, properly, first. It'll be easier to say "ReadTilemap" than have to do a giant for-loop to access everything.

Right now, trying to fill a tilemap using a for-loop is slow and pitiful. If instead I could get the engine to input everything into the array/tilemap via raw javascript, rather than through the slower parser, then it'd be much better.
Optimisation is the key for things like that.

> Reveal 🔎

Today I'm back to working on that project view. I'm thinking of using the icons to work instead of folders, and have some sort of filter system in place. Might work. Not sure! Will try!!

-=-=-
''Load, Next List!''
Tue, 18 May 2021, 04:57
Pakz
Yeah, I understand. It is not hard for me to drop the framerate with the c language using for loops and arrays!
Tue, 18 May 2021, 05:50
Pakz



I'm going through the examples and this one has the border leaving a bit of a smush. (This does not happen with full screen browser)


This is the
"WrapTilemap Top Left x,y"
example.

Everything else I got to seems solid so far!

edit: maybe a rounding problem?
Tue, 18 May 2021, 06:20
Jayenkai
Yeah, I decided to make the border a pixel out of the screen size, in the event of a mis-float making it slightly smaller and cutting off a pixel of your screen.
.. might have to extend the cls out by that much, too.
Will do that, later.

-=-=-
''Load, Next List!''
Tue, 18 May 2021, 12:38
Dan
Hi, here is another bug report which may go unnoticed:





Are Mirror and Flip essential tools? I mean, you could just draw the sprite with a negative scale, for those.. Is it necessary in the editor? If so, then rotate would probably be needed, too. Ugh.. Gonna need more space in the GUI!!!!


If mirroring and flipping can be done in code, then they can be left out of the editor (i guess).

For more space, i have an idea:

A button row, for e.g. above the palette.
When a button is clicked on, the palette area is replaced with tool-buttons.
When another button is clicked, the palette is active and the tools are hidden.

Some of painting apps on mobiles use that approach, or they use a pop-up menue with icons.
Tue, 18 May 2021, 13:07
Jayenkai
Gah, the old "not inside quotes" thing. Bah, humbug!!
You can see my inner working, there!

Bloody minuses..

I've been trying to find situations where negative numbers are "most likely" being referenced, and replace the - with '0-'s.
eg a = -5

But even after all my work, "print -5" still refuses to happen, because the parser thinks "print" might be a variable, and you might be asking for the value of "print with 5 subtracted"
It's alarmingly difficult to get that working right.
I'll keep attempting to figure it out, and hopefully not break even more!


For the Symbol editor, I'm starting to think that scroll+pan+zoom isn't unreasonable.
Seems like a "fixes a lot of issues at once" kind of solution.

.. FFS, now I need to code scrolling and panning and zooming, too!!!

-=-=-
''Load, Next List!''
Tue, 18 May 2021, 14:04
Jayenkai
Updates uploaded.
Today's updates are mostly of the Project List variety.
I opted against the "Let's code a whole Workbench style GUI" because I figured you'd more than likely want the latest projects at the forefront, and I couldn't fathom a nice way to do that with a pile of icons.
Any suggestions are, of course, welcome.

So we're back to "List" view again.
I've made the little disk icon be a toggle. You can click it to change the colour between one of 6, red, orange, yellow, green, blue, purple.
This is saved in your browser's save, but isn't exported, so if you import to a different browser, later, you'll end up having to set these again.

Once set, you can click the 6 icons up at the top to filter the view to only show "the projects on that disk"
It's not the most complicated setup, but I figured it was enough to achieve the goal.
Let me know what you think.

(Oh, and extra work on the Minuses!)

-=-=-
''Load, Next List!''
Wed, 19 May 2021, 04:00
Dan
Yes, it makes sorting and searching for saved code easier.

A permanent solution to the disk icons would be to let the user set it in the header part, something like


But, it is fine as it is now.

BTW, if the code is saved in the local storage, i wonder: is there a limit to how much code can be saved (and written) ?
Wed, 19 May 2021, 04:11
Jayenkai
Last I checked there's a 4Mb limit, though I think that might've increased.. I seem to remember 10, at some point?! I can't remember. Browser technology's always changing.

Currently, all of my exported code is 47kb. So. Um..
*shrugs*

Oh, and I fixed the saving of the disk settings, this morning. I'll be uploading that later tonight, but it basically involves an extra line of data in the export file.

-=-=-
''Load, Next List!''
Wed, 19 May 2021, 07:56
Jayenkai


Hey, Dan. Hopefully I've (finally!) fixed the input so that a QWERTZ layout should still work with the Gamepad functions.

Do me a favour and let me know if the lower-left (Y?) key triggers an A button response (based on it being where the Z key is on a QWERTY)..
And that the actual input still knows it's a Y key!
Ta for the help

-=-=-
''Load, Next List!''
Wed, 19 May 2021, 08:55
Dan
Hi,
i have tested my xbox controller and the keyboard.

Here is the report:

The buttons on the xbox controller work as intended. it is possible to have all buttons and all directions activated at the same time.

On the keyboard there are few things:
The key "y" , when pressed does not get reseted. The "A" stays on the screen until the z key is pressed.
(pressing the a button on the xbox controller does not reset it as well).


Pressing the menue key triggers "ButtonY" and it does not get reseted.
Pressing the windows key triggers the "ButtonB" but the windows start-menue gets opened. The key is reseted.

Pressing the left alt key triggers the "ButtonY" but the menue on the chrome browser is activated as well (the 3 vertical dots).
(the game looses the focus then)

Pressing the right strg/ctrl triggers "left" and "ButtonB" together, but the "left" is not reseted.

Numpad 0 and Insert key trigger the "ButtonX" but they do not get reseted as well.

And ^ key triggers "Right" and no reset.
Wed, 19 May 2021, 10:01
Jayenkai
A lot of those issues are browser based issues. That's why, for the most part, I prefer people to use WASD+IJKL, or Cursors+ZXCV, as opposed to hitting Shift/Ctrl/Alt/Winkey.
But, at least they.. Kinda work...!?!

In addition, a lot of "not resetting" is .. derp.. I only changed the code in the "keydown" function, and completely forgot about the "keyup"..
Gawd, there's a lot of jumping about, here!!

OK, I'll rejig a few bits and do another upload later tonight.
Thanks for the help

-=-=-
''Load, Next List!''
Wed, 19 May 2021, 12:21
Dan

Wed, 19 May 2021, 16:24
Jayenkai

JSE is here

Another upload done. Should hopefully fix most of the resetting issues you were having.
Now onto the next complicated issue.
As you can see in the above example, things are.. ALMOST functional.. (You might need to reload a couple of times, so it gets all the font files. grrr.. caching.. grrr..)

How unfortunate, then, that the available fonts don't include all of the original characters.
I mean, I know "Ascii standards aren't the same as they were in the 1980's", but .. Hmmm...
So, I'm left wondering what the best option, here, might be..
My head's screaming "Why don't you just make a tool that converts black and white pxiel-based bitmap fonts into high resolution, crisp, vector based fonts, after having figured out the file format for saving those very fonts!?!?!"

.. And another part of my head is just plain screaming..
Hmm..

What to do....

-=-=-
''Load, Next List!''
Thu, 20 May 2021, 05:33
Dan
Loading fonts worked ok sofar.

here are two screenshots, they show the differences between browsers on the same mobile phone.


and chrome

on android.

P.s. the screenshots are not a bug report

The keyboard/gamepad is better now, the keys do reset now.

I have launched the pico 8, and when the game is running, the alt key is somehow redirected (used) to the game, and the browser does not react to it.

I do not know how that is done but maybe you could set up, only for the alt key, the focus back to the canvas ?


Something like



It's just an idea.
Thu, 20 May 2021, 05:45
Jayenkai
Yeah, I could use .preventDefault() to stop it doing a lot of things, but then that would also stop it doing a lot of things!!
Ctrl+V to paste, for one.
I've opted not to do that!

Meanwhile...



In the above screenshot are 4 "characters" that I added to a font myself! \o/yeay\o/
The next step is to write a tool that takes crisp images of a complete 8-bit font, then runs through it, traces the outline of each shape and generates the correct path information, so that I can then convert all of that to a single font.
In the above image, the characters for the triangle shapes are 1033, 1034, 1035 and 1036..
So.. I could quite easily (I hope!) have 1000-1255 for the Amstrad font, 2000-2255 for the C64, 3000-3255 for the Speccy and so on.
The possibilities are *endless

.. Until I realise how sodding big the resulting font file is getting!!

-=-=-
''Load, Next List!''
Thu, 20 May 2021, 12:57
Jayenkai


Progress so far..
I've managed to get the font working in a lovely square monospaced size.
The 8x8 grid can clearly be seen.. Each character (0 to 255) has been given the exact same dotted pattern around the top and left, and the result is a screen full of perfectly sized dots in a perfectly sized pattern.

I'm fairly hopeful this might actually work out!

Note : No, I don't know why that y's there!!

-=-=-
''Load, Next List!''
Thu, 20 May 2021, 14:23
Dan
Hi,
i was trying to port the BrainF* code ...

Then i noticed that the dp variable is not increasing.
It gets added to 2 in the if statement (you can see it in the debug log) but
at the next debug line, it is back to 1.

here is the code:


Thu, 20 May 2021, 14:36
Jayenkai
Things go awry if you have an If halfway through a line.
For the time being, split and replace with if/endif sections.
This is one of those "A bit quirky" features of the language

Meanwhile...


Seems good to me

That's a ripped font..
Started as a .png, screen grabbed from an emulator, converted through PHP magic into a .SVG font, then an online app converts it to a .woff font. As a side-effect, I also now have a .ttf Amstrad font, too!!

The next task is to get a fleet of emulators up and running, and try to screen grab pixel-accurate 32-255 character lists from some other systems.
Current font file size, 10kb as a .woff2 online font, and 1Mb as a .ttf font. Although the .ttf *should* eventually be smaller, it currently contains 32 repetitions of the font, to simulate a giant font containing 32 different system fonts..
Once I'm done, I'll try making each font its own .ttf font, too.
*phew*

-=-=-
''Load, Next List!''
Thu, 20 May 2021, 15:09
Dan
Ok, thanks for the info.

Hmm, few years ago, i have drawn some fonts.
2021/20/oldfont (.zip)

There are 4 fonts available (all in one file), in the .fon format:

Amiga, Cpc, Pc-Dos and C64 font.
Thu, 20 May 2021, 15:16
Jayenkai
I'll have a poke in the morning.
I think I'm going to have to dig out the pc for a few of these screenshots.
I tried today on the Mac, but everything ends up with Retina-Scaled crud all over it.
Grrr!!!

-=-=-
''Load, Next List!''
Fri, 21 May 2021, 06:24
Jayenkai


Getting there..

Mmmmmm...

-=-=-
''Load, Next List!''
Fri, 21 May 2021, 07:42
Jayenkai


With apologies, you'll have to go through all your code and fix up font sizes and alignment. The new fonts are "slightly" bigger than the old default one was.

-=-=-
''Load, Next List!''
Fri, 21 May 2021, 08:05
Pakz
I would expect some news site to pick this up in the future. It is getting better every day!

oh, in the project screen, there are horizontal spaces in the font.
Fri, 21 May 2021, 09:04
Jayenkai
Depends on the browser.. Mostly Chrome is wonky. Safari and Firefox (even though Safari IS a chrome based browser) both aren't showing it.
This has been noted, and I'm trying my best to fix it.
Basically means I can't skimp out on the font methods, and need to trace letters better

Also, the C64 chr list is screwy.
Going to have to write a better method to extract the complete chart.

-=-=-
''Load, Next List!''
Fri, 21 May 2021, 10:32
Jayenkai
Rejigged. It looks a little better on some browsers.. .. I think..? And the C64 ascii layout is a teensy bit more sensible, but .. also not exact, so be aware of that.
I really no need to fix it from being "lots of squares" to being a better trace of the shape. Couldn't figure out how to cut out holes, though, that's the main issue. Grrr..
Paths and Vectors. Rawr!!!

-=-=-
''Load, Next List!''
Page : 1 2 3 4 Prev 5 6 Next 7 8 9 10 11 12 13 14