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 - Luke_Nukem

Pages: [1]
1
Themes / Theme to demonstrate CRT shaders
« on: September 19, 2018, 11:26:58 PM »
UPDATED: Split shaders in to own themes for easier viewing.

I ended up finally finishing off some other stuff I started years ago - namely, a small theme just to show videos using a few different types of CRT shaders.

Gitlab link

You'll need to play around with things to get nice settings for yourself.

Link to high quality photos of running on an 4:3 LCD machine

2
General / A bootable Linux ISO/USB that auto-loads from a 2nd USB
« on: September 18, 2018, 07:38:56 PM »
Hi all.

This is something I had been working on for a long while, and only just got around to completing - a USB bootable Linux install that boots directly to Attract Mode, and loads/saves configs, roms, art etc from a second USB drive.

The short of it is:
- write iso to USB drive,
- format another USB drive with a partition named 'arcade_usb'
- copy your complete setup to the above drive partition (see example)
    - Attract Mode setup is expected to be in the attractmode directory
- insert both sticks and boot

NOTE: You can yank the arcade_usb stick out (which stops Attract Mode), tinker with stuff on it on another computer, then stick it back in (Attract Mode will start again with new settings etc).

NOTE: Linux Is CaSe SeNsiTiVe!!!

---
Hardware:

CPU must be 64bit!

It *should* work with almost anything provided it supports decent OpenGL levels required by the SFML lib AM uses. I provide two ISO's; one with previous gen of Nvidia support, and one for current gen - both ISO's should support Intel and AMD/ATi without issue.

The hardware I run this on at the moment with great success is:
- AMD Athlon 64,
- 512Mb of RAM,
- Nvidia 8600GT
and shaders work very well in AM and in Mame using bgfx. I do get some slow-down on this hardware with more complex themes or ones that try to display a whole lot of video snaps at once.

---
Installing:

If you are experienced with Linux, you can install this ISO to the local HDD of the machine you want it on, there are two scripts to help get you through; installer, and install-arcade. install-arcade (WIP!) will nuke the HDD and install the ISO unguided, whereas installer will do it with your help.

NOTE: The ISO's don't include EFI boot as of yet, so booting and installing will be old-fashioned BIOS style for now.

NOTE: Feedback is welcomed. For issues though, please create them on Gitlab, or if you don't have an account on there PM me and I'll add the issue.

---
Links:

Gitlab project

Pre-built ISO's

Main README.md

arcade_usb setup example

Theme in photo and in examples is the excellent flat_blue

3
General / Showing off GLSL Mame.
« on: June 09, 2015, 03:33:12 PM »
Hi all. Been a while since I've been on here.
I have a couple of videos to show off;

GLSL Mame;
https://youtu.be/AJD8qB1nofU
Running under Linux. Front end is AttractMode of course. Runs very slick.

Booting from USB to AttractMode;
https://youtu.be/E6s3h3q8o5A
This is running a custom build of Arch, basically an ISO built around a very stripped down version of Arch, and booting straight into X with AttractMode running once loaded.
Takes around 35 seconds. Slightly less once installed to HDD.
The source to the build will be available on GitHub soon, and you require an Arch system to build it.  ;D

And a quick play test;
https://youtu.be/8furOI4b4DM
At the end, it takes about 2 seconds to shutdown  :D

The AM theme is one I built a while ago, called swapper. I plan to update it soon.

4
General / My projects.
« on: July 30, 2014, 03:22:54 PM »
Hi guys, i thought you might all be interested in what I'm doing.
Currently I've been investing a lot of time and effort into starting my small business in New Zealand, building custom and replica arcade cabs.

You can see my WordPress site here
And also my FaceBook page.
Also, twitter @garagearcades and tumblr, garagearcades

I've got a lot going on, and not showing it all yet :) Which, with fulltime work, and studying, has unfortunately impacted on my ability to contribute to AttractMode at the moment.

With the above sites, I'm still regularly chopping and changing things a bit, trying to get the nitty-gritty sorted out.

5
Scripting / Passing a "global name" to a function?
« on: June 07, 2014, 08:39:59 PM »
I've got a tricky one...

Lets say I'm trying to pass a global variable name to a function, not the value of that variable itself.

Code: [Select]
testName <- 0;
function test (x,y,varName){
      local x = x;
      local y = y;
      varName = 1;
    return x+y;
}
local testFun = test(3,5,testName);
print ("testFun = "+testFun+"\n");
print ("testName = "+testName+"\n");

I would expect this to print
Code: [Select]
8
1

Except varName is local to the function, and gets passed a 0.
It then changes the 0 to a 1 in the function, but because it was done locally to that function, testName remains as 0.

I could of course use testName in the function itself, but I'm trying to pass the name of that var to the function. A bit like a pointer.

Anybody have any ideas?

6
Scripting / Colour cycling script.
« on: June 06, 2014, 06:58:27 PM »
Hi guys. Thought you might like to have a nosey at my script for cycling through colours for an item.
Pretty simple I guess, uses a tick timer and a counter. Set up as 3 individual elements for each colour.

Code: [Select]
fe.add_ticks_callback( "tick" );
//
local swR = 0;
local swG = 0;
local swB = 0;
local romListRed = 0;
local romListGreen = 0;
local romListBlue = 0;
local redTime = 0;
local greenTime = 0;
local blueTime = 0;

function tick( ttime ) {

if (redTime == 0)
redTime = ttime;
if (greenTime == 0)
greenTime = ttime;
if (blueTime == 0)
blueTime = ttime;
/////////////////////////////////////////////////////////
if (ttime - redTime > 0.15){
if (swR==0){
if (romListRed < 254)
romListRed += 3;
if (romListRed >= 254){
swR = 1;
}
}
else
if (swR==1){
if (romListRed > 100)
romListRed  -= 3;
if (romListRed <= 100){
swR = 0;
}
}
redTime = 0;
}
/////////////////////////////////////////////////////////
if (ttime - greenTime > 0.1){
if (swG==0){
if (romListGreen < 254)
romListGreen += 1;
if (romListGreen >= 254){
swG = 1;
}
}
else
if (swR==1){
if (romListGreen > 100)
romListGreen  -= 1;
if (romListGreen <= 100){
swG = 0;
}
}
greenTime = 0;
}
/////////////////////////////////////////////////////////
if (ttime - blueTime > 0.05){
if (swR==0){
if (romListBlue < 254)
romListBlue += 1;
if (romListBlue >= 254){
swR = 1;
}
}
else
if (swR==1){
if (romListBlue > 100)
romListBlue  -= 1;
if (romListBlue <= 100){
swR = 0;
}
}
blueTime = 0;
}
set_bright( romListRed, romListGreen, romListBlue, romList );
}

The set_bright function is from one of the other scripts available, though i did modify it to set each r,g,b colour.

To change how long each colour takes to cycle up and down, edit;
Code: [Select]
if (ttime - redTime > 0.15){
This could be adapted to all sorts of applications i bet..

Cheers!

7
Scripting / Dynamic change res
« on: June 05, 2014, 01:24:42 PM »
G'day guys.
Thought I'd share this little block with you all.

I wasn't very happy with how AttractMode was handling screen res and rotation, so I ended up brewing up what is just a large if-else block and some options.
This combined with positions/sizes that are divided from the layout width and height, actually becomes quite robust. The only hardcoded positions I tend to have now are a few text strings in corners, everything else is relative to width/height.

Maybe I missed it, but does AttractMode have an actual return global for when it is rotated?
It would be excellent to have this check the global and select the width/height accordingly.

Code: [Select]
class UserConfig {
</ label="Screen Size", help="Select the screen size",
options="1360x768,1280x1024,1280x768,1280x720" />
screenSize="1360x768";

</ label="Screen Rotate", help="Swap X/Y dimensions for rotated screens",
options="Yes,No" />
rotated="No";
}
local layoutSettings = fe.get_config();

if ( layoutSettings["screenSize"] == "1360x768" ){
if ( layoutSettings["rotated"] == "Yes") {
fe.layout.width=768;
fe.layout.height=1360;
}
else if ( layoutSettings["rotated"] == "No") {
fe.layout.width=1360;
fe.layout.height=768;
}
}
else if ( layoutSettings["screenSize"] == "1280x1024" ){
if ( layoutSettings["rotated"] == "Yes"){
fe.layout.width=1024;
fe.layout.height=1280;
}
else if ( layoutSettings["rotated"] == "No") {
fe.layout.width=1280;
fe.layout.height=1024;
}
}
else if ( layoutSettings["screenSize"] == "1280x768" ){
if ( layoutSettings["rotated"] == "Yes") {
fe.layout.width=768;
fe.layout.height=1280;
}
else if ( layoutSettings["rotated"] == "No") {
fe.layout.width=1280;
fe.layout.height=768;
}
}
else if ( layoutSettings["screenSize"] == "1280x720" ){
if ( layoutSettings["rotated"] == "Yes") {
fe.layout.width=720;
fe.layout.height=1280;
}
else if ( layoutSettings["rotated"] == "No") {
fe.layout.width=1280;
fe.layout.height=720;
}
}

Pages: [1]