Firewall


Basic Information

  • Difficulty adjusts how many blocks need to be broken to succeed


Exports (client side only)

Default Settings

exports['envi-hack-minigames']:StartFirewallHack('medium', function(success)
    if success then
        print('Firewall hack completed successfully!')
    else
        print('Firewall hack failed!')
    end
end)

Custom Settings

exports['envi-hack-minigames']:StartFirewallHack({
    timeLimit = 120,
    difficulty = 3
}, function(success)
    if success then
        print('Firewall hack completed successfully!')
    else
        print('Firewall hack failed!')
    end
end)

Getting Defaults

-- Get default settings for difficulty
local hackType = 'firewall'
local difficultyPreset = 'medium'
local defaults = exports['envi-hack-minigames']:GetHackDefaults(hackType, difficultyPreset)

-- Adjust difficulty
-- Can be adjusted however you wish based on whatever parameters you decide
defaults.difficuly = defaults.difficuly - 1

-- Start the hack with the adjusted default settings
exports['envi-hack-minigames']:StartFirewallHack(defaults, function(success)
    if success then
        print('Hack Success!')
    else
        print('Hack Failed!')
    end
end)

Last updated