So this is the quick and dirty solution I built, based on my "gameletter" routine. Consider that my routine works for different sortings, but this layout only works if the sorting is not by category, manufacturer or year. If you want to expand it to work with all this sortings you should change the key array accordingly
function gameletter( offset ) {
if (fe.filters.len() > 0){
if (fe.filters[fe.list.filter_index].sort_by == Info.Year){
local s = fe.game_info( Info.Year, offset )
return s
}
else if (fe.filters[fe.list.filter_index].sort_by == Info.Manufacturer){
local s = fe.game_info( Info.Manufacturer, offset )
return s.slice(0,1)
}
else if (fe.filters[fe.list.filter_index].sort_by == Info.Category){
local s = fe.game_info( Info.Category, offset )
if (s == "") return "?"
s = split( s, "/" )
return strip(s[0])
}
else {
local s = fe.game_info( Info.Title, offset )
if (s.find("The ") == 0) s = s.slice(4,s.len())
local s2 = s.slice(0,1)
if ("1234567890".find (s2) != null ){
s2="#"
}
return s2
}
}
}
local flw = fe.layout.width
local flh = fe.layout.height
local gamename = fe.add_text("[Title]",0,0,flw,flh/10)
gamename.charsize = gamename.height*0.5
local accent = fe.add_text ("[!gameletter]",0,flh*0.5,flw,flh*0.25)
accent.charsize = flh*0.25
local keys = null
keys = {}
local i = 0
local key_names = [ "#", "A", "B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"]
foreach (key, val in key_names){
local key_obj = fe.add_text(val, i*flw/key_names.len(),flh*0.5,flw/key_names.len(),50)
key_obj.charsize = 50
key_obj.alpha = 128
i++
keys[val] <- key_obj
}
keys [gameletter(0)].alpha = 255
fe.add_transition_callback( this, "on_transition" )
function on_transition( ttype, var, ttime ) {
if (ttype == Transition.ToNewSelection){
local l1 = gameletter(0)
local l2 = gameletter(var)
if (l1 != l2){
keys [l1].alpha = 128
keys [l2].alpha = 255
}
}
}