Jump to content

(Fix) Letter Box


Recommended Posts

Hey,

Im trying to make an effect like a letter box, so 2 black boxes one at the top, and one at the bottom of the screen.

I have this so far :

screenSize = { guiGetScreenSize( ) }; 
  
local stripHeight = .15 * (screenSize[ 2 ]*2); 
  
    stripHeight = screenSize[ 2 ] * .15, 
    stripAlpha = .93, -- 0-1 
    animLength = 01, -- seconds 
    animStartTick = 0, 
    animFinishTick = 0, 
    keepAnimating = true, 
     
    flyIn = function ( ) 
        letterBox.animStartTick = 0; 
        addEventHandler( "onClientRender", g_root, animateLetterBox_flyIn ); 
        setTempPedRotating( true ); 
    end 

But it aint working, can someone help me by correcting or making an example? :?:

Thanks

Link to comment
screenSize = { guiGetScreenSize( ) }; 

should be:

local sWidth, sHeight = guiGetScreenSize() 

idk Your code is messed up

    flyIn = function ( ) 
        letterBox.animStartTick = 0; 
        addEventHandler( "onClientRender", g_root, animateLetterBox_flyIn ); 
        setTempPedRotating( true ); 
    end 

You mean this?

function flyIn() 
        letterBox.animStartTick = 0; 
        addEventHandler( "onClientRender", g_root, animateLetterBox_flyIn ); 
        setTempPedRotating( true ); 
    end 

And where is the animateLetterBox_flyIn Function?

setTempPedRotating( true ); 

What is this function? did you make it up because this function doesn't exist.

Your code is really weird.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...