Author Topic: Boxart or flyer delay  (Read 3260 times)

clockman

  • Sr. Member
  • ****
  • Posts: 109
    • View Profile
Boxart or flyer delay
« on: December 12, 2023, 12:44:06 PM »
I was wondering how to have the boxart or flyer's delay? I found this online for video snap's as wondering how i would change it for boxart and flyer's.

local settings = {
   delay_timer = 0,
   play_delay = 3000
}

local artwork = fe.add_artwork("snap", 0, 0, 480, 360)

function on_transition(ttype, var, transition_time) {
    if ( ttype == Transition.StartLayout || ttype == Transition.ToNewList || ttype == Transition.FromOldSelection ) {
        artwork.video_flags = Vid.NoAutoStart
        settings.delay_timer = fe.layout.time
    }
    return false
}

function on_tick(tick_time) {
   if ( !artwork.video_playing && tick_time - settings.delay_timer >= settings.play_delay ) artwork.video_playing = true
}

fe.add_ticks_callback(this, "on_tick")
fe.add_transition_callback(this, "on_transition")

jedione

  • Hero Member
  • *****
  • Posts: 1135
  • punktoe
    • View Profile
Re: Boxart or flyer delay
« Reply #1 on: December 21, 2023, 03:49:40 AM »
local artwork = fe.add_artwork("boxart", 0, 0, 480, 360)
asuming you have boxart set up in your emulator.cfg
help a friend....

clockman

  • Sr. Member
  • ****
  • Posts: 109
    • View Profile
Re: Boxart or flyer delay
« Reply #2 on: January 03, 2024, 01:58:18 AM »
Sorry haven't posted in a while I've been sick. It's not working, what else in the code do I need to change? I put that line in you gave me. The boxart will show but it won't delay. IThe video delay works but not the flyers on boxart. I even tried to change artwork.video to .boxart and nothing.
« Last Edit: January 03, 2024, 04:31:21 AM by clockman »