Jump to content

Race Nos2


gokalpfirat

Recommended Posts

Hi i added race_nos2 c_settings file

function consoleSetNosFiringStyle() 
if (g_Settings.ControlStyle = "normal") then 
g_Settings.ControlStyle = "nfs" 
elseif (g_Settings.ControlStyle = "nfs") then 
g_Settings.ControlStyle = "hybrid" 
elseif (g_Settings.ControlStyle = "hybrid") then 
g_Settings.ControlStyle = "normal" 
        if saveSettingsToFile() then 
            outputGuiPopup("Your NOS control style has been set to '" .. tostring(settingName) .. "'") 
        end 
    end 
end 
addCommandHandler("noscontrol", consoleSetNosFiringStyle) 
addCommandHandler("nos", consoleSetNosFiringStyle) 
  

But it doesnt works. It must do when i say /nos change my nos to another nos style.

Ps: I get error at line 80 ')' expected near '='

Link to comment

I Don't even know what you are doing, but when we are using if we use "==" not just one "=", but im not sure if this will work, try, elseif not, post /debugscript 3

function consoleSetNosFiringStyle() 
if (g_Settings.ControlStyle == "normal") then 
        g_Settings.ControlStyle = "nfs" 
  
elseif (g_Settings.ControlStyle == "nfs") then 
        g_Settings.ControlStyle = "hybrid" 
  
elseif (g_Settings.ControlStyle == "hybrid") then 
        g_Settings.ControlStyle = "normal" 
         
if saveSettingsToFile() then 
            outputGuiPopup("Your NOS control style has been set to " ..tostring(settingName)) 
        end 
    end 
end 
addCommandHandler("noscontrol", consoleSetNosFiringStyle) 
addCommandHandler("nos", consoleSetNosFiringStyle) 

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