Jump to content

Cinematic mod


Wisam

Recommended Posts

I made this script becasuse im still learning step by step and im starting from the smallst script so dont laugh at me :P

So this should trigger the cinematic mod on/off and outputs a message on the chat.. i didn't test it yet because my mta is broken at the moment.. can you please tell me if it would work and the player will be able to turn on/off the cinematic mod with the messages appeared? with the same command

function cinema (source) 
    local showChat (false) 
    local showHud (false) 
   outputChatBox("Cinematic mod on!" 0,255,0) 
   elseif outputChatBox("Cinematic mod off!" 255,0,0) 
end 
addCommandHandler("cin" cinema ) 
  

Link to comment
  
addEventHandler("onPlayerCommand",root, 
    function (cmd) 
    if cmd == "cinoff" then  
    showChat (source, false ) -- hide the chat 
    showPlayerHudComponent(source, "all", false) --- hide hud 
    outputChatBox('Cinematic mod off !',source, 255, 0, 0 ) --- msg 
    else if cmd == "cinon" then --- if command = cinoff then 
    showChat (source, true ) -- show the chat 
    showPlayerHudComponent(source, "all", true)--- show hud 
    outputChatBox('Cinematic mod on !',source, 255, 0, 0 ) 
     end 
   end 
  end 
 ) 

It's ServerSide,

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