Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - zpaolo11x

Pages: [1] 2 3 4
1
General / Attract Mode on macos Big Sur
« on: December 16, 2020, 01:20:06 AM »
So, after a long wait (because Apple blocked Big Sur update on late 2013 MBP like mine due to... err... bricking!) yesterday I was able to install macos 11.1 on my everyday laptop.

This post is just to inform people that I saw no impact on attract mode whatsoever. As long as you've set up it correctly for Catalina, you won't see any difference, no new permissions to check, no issues related to OpenGL (deprecated but still working) and no performance hit.

Of course if you skipped Catalina you'll have to apply some tricks to make AM work properly, but there's another post for that :)

2
General / Additional import files
« on: October 20, 2020, 10:28:11 PM »
I was wondering... I always used "additional import files" field in emulator setup to point to catver.ini on MAME, so the romlist would be populated with category data. Is this the only thing one can do? Because I'm planning to include both bestgames.ini and series.ini data in my layout, and I'm wondering if I have to write a parser (like the one for history.dat or command.dat) or if there's a way to include this data in the romlist when the emulator is configured.

3
Scripting / Rom complete file name and path
« on: August 21, 2020, 07:15:15 AM »
Is there a way to get the complete name of a rom file? In the romlist it seems only the filename without extension is present, so I'm wondering how does Attract Mode pass the filename parameter to the emulator?
Also is it possible to get somewhere the rom containing folder? Or maybe the only option is to parse the emulator configuration file?

In the and why I ask this? I'm playing with GB roms lately and there's a lot of them I don't need. It would be great to have a "kill button" that can remove the rom from the drive, directly from Attract Mode interface (in a proper layout of course). Adding a "hidden" tag would be a nice workaround... but the joy of deleting files from the layout hmm that has no price!

4
Scripting / Squirrel sorting speed
« on: August 18, 2020, 01:03:54 AM »
I was playing with array sorting in squirrel, and I discovered some interesting things.

Sorting an array using just ARRAY.sort() is much faster (an order of magnitude) than sorting using ARRAY.sort(@(a,b) a <=> b), and this is clearly visible for very large arrays (10'000 items or more). I don't know why this happens.

If you have an array of table items, like an array where every element is {name ="blablabla", val="120"} and you want to sort this array by the "val" table field using ARRAY.sort(@(a,b) a.val <=> b.val) this is even slower, more or less takes twice the time of a normal array sort ARRAY.sort(@(a,b) a <=> b).

I implemented my own TimSORT algorithm and sometimes it gets better results than the standard squirrel sorting using custom sort functions, but overall the improvement is marginal, it seems the overhead of using custom functions is very high.

Anyone has a suggestion on how to avoid this issue? The difference between simple sort() and all the other is striking, I need to find a way to leverage this speed in some way :O

5
General / CHUWI LarkBox mini PC
« on: July 14, 2020, 08:32:19 AM »
I was looking at this thing:

https://www.indiegogo.com/projects/chuwi-larkbox-world-s-smallest-4k-mini-pc#/

It sounds interesting to me because it's small, inexpensive, seems quite powerful and, most of all, it's not a Pi or other ARM/Android box, but a fully fledged x86 "PC". I'm wondering if anyone has experience with mame and the CPU/GPU in this box: Celeron J4115 with HD600 graphics. Would this run mame with glsl CRT filters? Would it run Attract Mode with OpenGL heavy layouts?

6
General / macOS Catalina key repeat issues [FIXED]
« on: July 02, 2020, 12:39:46 AM »
I know, it was a bad idea to update from Mojave to Catalina, but I needed to, and I was really surprised to see that Attract Mode seemed to work perfectly from the start! But... after further checking here it comes the hideous issue: key repeat is basically non-existent, and when I look at the attract log I see

"We got a keyboard without any keys (1)"

on the console output. Anyone with catalina can give me an hand? Also, when I add Attract Mode app to the accessibility preferences so it can access full disk etc, it's shown as AttradeMode. Weird :O

7
Scripting / Squirrel language: how to create a directory?
« on: May 28, 2020, 07:44:30 AM »
Is it even possible? I need to create a subdirectory to manage tags my way, I can open a file for writing using the file.nut module or directly using squirrel libraries, and the file will be created from scratch if it's not there already, but if the folder is not there, then an error is thrown.
Is there some way from a layout to create a folder?

8
Scripting / Help with fe.get_input_state and number keys
« on: May 21, 2020, 01:08:40 AM »
It seems that fe.get_input_state works fine with letter keys, like "A", "B" ecc, but has some issues with numbers like "1", "2" etc. When the string to check is a number the input states turns to true at the layout load even when no key is pressed.

I've put together a simple layout to test this: there's a string where you can add the letters/numbers you want to check, and the result state is shown on the display.

Code: [Select]
local displaybutton = fe.add_text("TEST",0,0,fe.layout.width,fe.layout.height*0.1)

fe.add_ticks_callback( this, "tick" )

local stringkeys = "12AB"

local keys = {}
foreach(letter in stringkeys){
   keys[letter.tochar()] <- false
}

function tick( tick_time ) {
   displaybutton.msg = ""
   foreach (key, value in keys) {
      keys[key] = fe.get_input_state(key)
      displaybutton.msg = displaybutton.msg + key + ":" + value + " "
   }
}

Has anyone had the same issue? Is there a different way to pass a check on number keys?

9
Scripting / Change the favourite state using a function
« on: April 12, 2020, 12:57:35 AM »
Is there a way to change the favourite state of the current game (or any game) using a function, or the only way is through the "add_favourite" signal (and consequent menu)?

10
Scripting / Ligature fonts
« on: March 27, 2020, 06:49:35 AM »
Does AM support ligature fonts? Or is it something that can be added?

Ligature fonts are mostly used with "font icons": you have a ttf font with all the icons inside, and each icon is bound to one or more ligature text, so if you apply the font to the word "folder" you obtain the folder icon instead of the text. This could open endless possibilities not only for icons and glyphs. Imagine a systems logos font with ligatures, just create a text box with the word Game Boy and the game boy logo is used, super neat! Or your text is "2 players" and it get substituted by the 2 players logo... etc

11
Scripting / "invert" shader
« on: March 19, 2020, 04:41:55 AM »
Is there a default shader to get the negative of the area behind a picture? Or is there a way to write a glsl shader that can "negate" what is under it?

12
Scripting / Content of an overlay listbox list
« on: March 17, 2020, 06:51:22 AM »
In a layout you can define a listbox, and use that listbox as overlay control, so that menu entries are shown in that listbox. There's a parameter to get the length of the list shown in the listbox, but is there a way to get the actual _content_ of the list in the listbox? I don't mean the displayed content, which is limited to the listbox rows, but the list content itself.

Example: you have a 3 rows listbox and when you enter the tags menu you get the "Add tag" voice for each of the tags in the games list, let's say you have 6 entries at all to show in this listbox. I'd love to be able to get those entries.

13
Themes / Translators needed for Arcadeflow layout
« on: February 03, 2020, 12:10:29 AM »
Hi all! I've implemented multi-language support into my Arcadeflow layout for Attract Mode, but I only speak Italian and English, so right now the choice is somewhat limited. It would be great to have an help in translating it to other languages like Spanish, French or German or any other language you can speak.

It's not very demanding, I can share a file with the english and italian phrases, if anyone is interested please answer here or send me a PM. To anyone who'd like to contribute, my special thanks! :D

14
Scripting / Multi-language options page...
« on: January 30, 2020, 07:31:11 AM »
I want my options page in my layout to adapt to different languages. Is there an easy way to do it? I've already coded my translating framework which, based on a layout variabl, gets the translation of the strings from an external file. This works fine if I declare the variable at the beginning of the layout, and I can also see changes in the options page this way.

So I thought, I'll save the value of the variable in the fe.nv file and get it before the options table is built. But this doesn't work: at layout launch the variable is loaded and the layout reflects the translation, but if I enter the layout options I see in the log the layout is somewhat reloaded, and the read routin is re-executed, but gives an error.

Any help?

15
General / Attract Mode FPS in 2.5 and 2.6
« on: January 10, 2020, 05:20:42 AM »
When using Attract Mode 2.5 the fps of the layout were capping at 60, I mean that the redraw of the layout was never going over 60 hz. Now with Attract Mode 2.6 with a powerful PC I get refresh rates up to 200 and my themes get crazy fast when timers are related to ticks. Is there something different in AM or is it maybe monitor related?

Pages: [1] 2 3 4