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

Pages: [1]
1
Scripting / [Help]Loading themes based on current filter
« on: December 02, 2015, 04:42:33 PM »
I'm trying to load specific .nut files based on the filter.

So If the current filter is "Capcom" it will load /themes/capcom.nut, if I change the filter it will then load the next one. (Lets say Konami) So then I load /themes/Konami.nut etc. Same for NES, SNES and other systems.

I'm not really sure how to get this working though! I've done some basic themes but they've all been a single theme for all systems/filters. 

Hoping for some direction on this, I'm pretty confused to be honest, ???.

Currently I have something like this
Code: [Select]
if (fe.Filter = "mame") {
print("Loading MAME.nut...\n");
fe.do_nut("themes/MAME.nut");
}
else if (fe.Filter = "mess") {
print("Loading MESS.nut...\n");
fe.do_nut("themes/MESS.nut");
}
etc. etc. *Above code is not updating layout correctly though!*

Where each theme is initializing its own variables and everything. Not sure if it would be possible to declare the objects and surfaces in the main layout file and just manipulate them in the filter/system themes.

So yeah, thanks for taking a look and thanks for any and all help!

Pages: [1]