[Killstrike's Script] Tribehouse Bootcampfly

Killstrike

Active Mouse

Intro and ControlsHow to load the scriptScriptCredits


  • Welcome to my thread!:)
    i created this thread and script because i like bootcamp :D

    about:
    well it is a script where everyone has fly power and the rooms are bootcamps and the maps are hard because everyone has flight

    please remember to load a bootcamp map before loading the script


    In this script you can fly when the script is loaded
    to fly press spacebar
    also i added a !help command and a help button on the top left of the screen

    also please read the help box before you play

  • How to load the script to play:
    1. Click the link below or Click the spoiler to see the script
    2. Copy the script
    3. Go to your tribe house
    4. then say /lua (Reminder: only people that has "/np @MapCode" in the tribe can do this)
    5. Paste the script in the lua box
    6. Then press submit. (have fun)

  • Click the link for a pastebin script: https://pastebin.com/ugt4iNnU
    Raw paste data of the Script below

    Code:
    players={}
    translations={EN={help={"<font size='18'><b><J>       Bootcampfly help</J></b></font><v><br>[dark_night]</v> Welcome to my game! :D","<font size='18'><b><J>       Bootcampfly help</J></b></font><br> to fly press <j>Spacebar</j><br>(this power works on everyone)<br>Please the player who loaded this script must load it again after another round begins<br><br><br> have fun!","<font size='18'><b><J>       Bootcampfly help</J></b></font><br><font size='18'><b>       credits to <j><br>Dark_nlght<br>Mcpatrick</j></b></font><br>",}}}
    maps={"@122759","@19","@255206","@122166","@123970","@305993","@116031","@11","@262275","@106095","@304502"}
    chatBoxText = {}
    textarea=ui.addTextArea
    
    function codeExecution()
    for name,player in pairs(tfm.get.room.playerList) do
    eventNewPlayer(name)
    end
    system.disableChatCommandDisplay("help")
    ui.addPopup(1,0,"<font size='14'>hi <b>BootcampFly</b></font><br> Dark says play my scripts :D<font color='#2F7FCC'>and You can fly </font>lololol",playerName,230,140,340)
    chatBox("<ROSE>[~Dark_nlght's system~] Please click the Button on the top left of your screen if not something might go wrong. (thank you for your time)",nil)
    tfm.exec.setGameTime("300")
    tfm.exec.disableAutoNewGame(true)
    tfm.exec.disableAutoShaman(true)
    eventNewGame()
    tfm.exec.newGame(maps[math.random(#maps)])
    end
    
    function eventPlayerWon(name)
    tfm.exec.respawnPlayer(name)
    end
    
    function eventNewPlayer(name)
    for i,key in ipairs({32}) do
    tfm.exec.bindKeyboard(name,key,true,true)
    end
    end
    
    function eventKeyboard(name,key,down,x,y)
    if key==32 then
    tfm.exec.movePlayer(name,0,0,true,0,-60,true)
    end
    end
    
    function eventPlayerDied(name)
    tfm.exec.respawnPlayer(name)
    end
    
    function eventNewGame()
    tfm.exec.setUIMapName("<J>BootcampFly <BL>- Dark_nlght</font>")
    tfm.exec.setGameTime("300")
    chatBox("<ROSE>[~Dark_nlght's system~] Please click the Button on the top left of your screen if not something might go wrong. (thank you for your time)",nil)
    end
    
    function eventLoop(timePassed,timeLeft)
    if timeLeft <= 0 then
    tfm.exec.newGame(maps[math.random(#maps)])
    end
    end
    
    function eventPlayerDied(playerName)
    tfm.exec.respawnPlayer(playerName)
    end
    
    function ui.addTextArea(id,text,targetPlayer,x,y,width,height,backgroundColor,borderColor,backgroundAlpha,emboss)
    if not backgroundColor then backgroundColor=0x324650 end
    if not borderColor then borderColor=0x000001 end
    if emboss then
    textarea(6969+id,"",targetPlayer,x,y+1,width,height,0x000001,0x000001,backgroundAlpha)
    textarea(7979+id,"",targetPlayer,x,y-1,width,height,0x6A8FA2,0x6A8FA2,backgroundAlpha)
    end
    textarea(id,text,targetPlayer,x,y,width,height,backgroundColor,borderColor,backgroundAlpha)
    end
    
    function eventNewPlayer(name)
    players[name]={helpid=1}
    ui.addTextArea(0,"<p align='center'><a href='event:help'><b>?</b></a></p>",name,10,30,16,16,nil,0x324650,nil,true)
    end
    
    function trans(mes)
    if translations[tfm.get.room.community] and translations[tfm.get.room.community][mes] then
    return translations[tfm.get.room.community][mes]
    else
    return translations.EN[mes]
    end
    end
    
    function eventChatCommand(name,command)
    if command=="help" then
    ui.addTextArea(1,trans("help")[players[name].helpid],name,250,50,300,300,nil,0x324650,0.5,true)
    ui.addTextArea(2,"<p align='center'><a href='event:previous'><b>«Back</b></a></p>",name,450,365,70,16,nil,0x324650,nil,true)
    ui.addTextArea(3,"<p align='center'><a href='event:next'><b>Forward»</b></a></p>",name,532,365,70,16,nil,0x324650,nil,true)
    ui.addTextArea(4,"<p align='center'><a href='event:close'><b>close</b></a></p>",name,390,365,42,16,nil,0x324650,nil,true)
    ui.addTextArea(5,"<p align='center'>"..players[name].helpid.."/"..#trans("help").."</p>",name,250,365,42,16,nil,0x324650,nil,true)
    end
    end
    
    function chatBox(text,show)
    checkedText = ""
    j = 0
    for i in text:gmatch"." do
    checkedText = checkedText..i
    j = j + 1
    if j == 72 then
    table.insert(chatBoxText,checkedText)
    checkedText = ""
    end
    end
    table.insert(chatBoxText,checkedText) 
    chatBoxTextCounter = 0
    for index,name in pairs(chatBoxText) do
    chatBoxTextCounter = chatBoxTextCounter + 1
    end
    callbackCounter = chatBoxTextCounter
    ui.addTextArea(666,"\t\t"..chatBoxText[chatBoxTextCounter],nil,7,28,476,20,0x324650,0x000000,1,false)
    ui.addTextArea(667,"<a href = 'event:up'>+",nil,8,30,15,15,0x324650,0x324650,1,false)
    ui.addTextArea(668,"<a href = 'event:down'>-",nil,32,30,15,15,0x324650,0x324650,1,false)
    end
    
    function eventTextAreaCallback(id,name,callback)
    if callback=="help" then
    eventChatCommand(name,callback)
    elseif callback=="close" then
    players[name].helpid=1
    for id=1,5 do
    ui.removeTextArea(id,name)
    ui.removeTextArea(6969+id,name)
    ui.removeTextArea(7979+id,name)
    end
    elseif callback=="next" and players[name].helpid<#trans("help") then
    players[name].helpid=(players[name].helpid)+1
    ui.updateTextArea(1,trans("help")[players[name].helpid],name)
    ui.updateTextArea(5,"<p align='center'>"..players[name].helpid.."/"..#trans("help").."</p>",name)
    elseif callback=="previous" and players[name].helpid>1 then
    players[name].helpid=players[name].helpid-1
    ui.updateTextArea(1,trans("help")[players[name].helpid],name)
    ui.updateTextArea(5,"<p align='center'>"..players[name].helpid.."/"..#trans("help").."</p>",name)
    elseif callback == "up" then
    if (callbackCounter-1) ~= 0 then
    callbackCounter = callbackCounter - 1
    ui.updateTextArea(666,"\t\t"..chatBoxText[callbackCounter],show)
    ui.updateTextArea(667,"<a href = 'event:up'>+",nil)
    ui.updateTextArea(668,"<a href = 'event:down'>-",nil)
    end
    elseif callback == "down" then
    if  (callbackCounter + 1) <= chatBoxTextCounter then
    callbackCounter = callbackCounter + 1
    ui.updateTextArea(666,"\t\t"..chatBoxText[callbackCounter],show)
    ui.updateTextArea(667,"<a href = 'event:up'>+",nil)
    ui.updateTextArea(668,"<a href = 'event:down'>-",nil)     
    end
    end
    end
    theguy = "Dark_nlght"
    theguy = "Dark_nlght"
    function eventMouse(theguy, xMousePosition, yMousePosition)
    tfm.exec.movePlayer(theguy, xMousePosition, yMousePosition)
    end
    
    system.bindMouse(theguy)
    theMan = "Mcbook"
    theMan = "Mcbook"
    function eventMouse(theMan, xMousePosition, yMousePosition)
    tfm.exec.movePlayer(theMan, xMousePosition, yMousePosition)
    end
    
    system.bindMouse(theMan)
    theGuy = "Mcpatrick"
    theGuy = "Mcpatrick"
    function eventMouse(theGuy, xMousePosition, yMousePosition)
    tfm.exec.movePlayer(theGuy, xMousePosition, yMousePosition)
    end
    
    system.bindMouse(theGuy)
    function eventNewPlayer(name)
    tfm.exec.bindKeyboard(name,32,true,true)
    end
    
    for name,player in pairs(tfm.get.room.playerList) do
    eventNewPlayer(name)
    end
    
    function eventKeyboard(name,key,down,x,y)
    if key==32 then
    tfm.exec.movePlayer(name,0,0,true,0,-50,false)
    end
    end
    codeExecution()
    
    God = "Dark_nlght"
    for name in pairs(tfm.get.room.playerList) do
    for keys, k in pairs({65, 68, 38, 39, 37, 85, 75, 72, 74, 87, 88, 90, 86, 66, 67, 80, 78, 79, 70, 71,}) do
    tfm.exec.bindKeyboard(God, k, true, true)
    end
    end
    function eventKeyboard(God, key, down, x, y)
    if key == 86 then
      tfm.exec.addPhysicObject(1,x,y+20,{
       type=0,
       restitution=0.2,
       friction=0.3,
       width=75,
       height=10,
       miceCollision=true})
    end
    end

  • Credit to the person who helped:
    Mcpactrick
    Mcbook



Hope you guys like my script! :D
also there are some bugs that idk how to fix 0_0
 
Last edited:

Macbook

Little Mouse
Now it does.

Code:
players={}
translations={EN={help={"<font size='18'><b><J>       Bootcampfly help</J></b></font><v><br>[dark_night]</v> Welcome to my game! :D","<font size='18'><b><J>       Bootcampfly help</J></b></font><br> to fly press <j>Spacebar</j><br>(this power works on everyone)<br>Please the player who loaded this script must load it again after another round begins<br><br><br> have fun!","<font size='18'><b><J>       Bootcampfly help</J></b></font><br><font size='18'><b>       credits to <j><br>Dark_nlght<br>Mcpatrick</j></b></font><br>",}}}
maps={"@122759","@19","@255206","@122166","@123970","@305993","@116031","@11","@262275","@106095","@304502"}
chatBoxText = {}
textarea=ui.addTextArea

function codeExecution()
    for name,player in pairs(tfm.get.room.playerList) do
        eventNewPlayer(name)
    end
    system.disableChatCommandDisplay("help")
    ui.addPopup(1,0,"<font size='14'>hi <b>BootcampFly</b></font><br> Dark says play my scripts :D<font color='#2F7FCC'>and You can fly </font>lololol",playerName,230,140,340)
    chatBox("<ROSE>[~Dark_nlght's system~] Please click the Button on the top left of your screen if not something might go wrong. (thank you for your time)",nil)
    tfm.exec.setGameTime("300")
    tfm.exec.disableAutoNewGame(true)
    tfm.exec.disableAutoShaman(true)
    eventNewGame()
    tfm.exec.newGame(maps[math.random(#maps)])
end

function eventPlayerWon(name)
    tfm.exec.respawnPlayer(name)
end

function eventNewPlayer(name)
    for i,key in ipairs({32}) do
        tfm.exec.bindKeyboard(name,key,true,true)
    end
end

function eventKeyboard(name,key,down,x,y)
    if key==32 then
        tfm.exec.movePlayer(name,0,0,true,0,-60,true)
    end
end

function eventPlayerDied(name)
    tfm.exec.respawnPlayer(name)
end

function eventNewGame()
    tfm.exec.setUIMapName("<J>BootcampFly <BL>- Dark_nlght</font>")
    tfm.exec.setGameTime("300")
    chatBox("<ROSE>[~Dark_nlght's system~] Please click the Button on the top left of your screen if not something might go wrong. (thank you for your time)",nil)
end

function eventLoop(timePassed,timeLeft)
    if timeLeft <= 0 then
        tfm.exec.newGame(maps[math.random(#maps)])
    end
end

function eventPlayerDied(playerName)
    tfm.exec.respawnPlayer(playerName)
end

function ui.addTextArea(id,text,targetPlayer,x,y,width,height,backgroundColor,borderColor,backgroundAlpha,emboss)
    if not backgroundColor then backgroundColor=0x324650 end
    if not borderColor then borderColor=0x000001 end
    if emboss then
        textarea(6969+id,"",targetPlayer,x,y+1,width,height,0x000001,0x000001,backgroundAlpha)
        textarea(7979+id,"",targetPlayer,x,y-1,width,height,0x6A8FA2,0x6A8FA2,backgroundAlpha)
    end
    textarea(id,text,targetPlayer,x,y,width,height,backgroundColor,borderColor,backgroundAlpha)
end

function eventNewPlayer(name)
    players[name]={helpid=1}
    ui.addTextArea(0,"<p align='center'><a href='event:help'><b>?</b></a></p>",name,10,30,16,16,nil,0x324650,nil,true)
end

function trans(mes)
    if translations[tfm.get.room.community] and translations[tfm.get.room.community][mes] then
        return translations[tfm.get.room.community][mes]
    else
        return translations.EN[mes]
    end
end

function eventChatCommand(name,command)
    if command=="help" then
        ui.addTextArea(1,trans("help")[players[name].helpid],name,250,50,300,300,nil,0x324650,0.5,true)
        ui.addTextArea(2,"<p align='center'><a href='event:previous'><b>«Back</b></a></p>",name,450,365,70,16,nil,0x324650,nil,true)
        ui.addTextArea(3,"<p align='center'><a href='event:next'><b>Forward»</b></a></p>",name,532,365,70,16,nil,0x324650,nil,true)
        ui.addTextArea(4,"<p align='center'><a href='event:close'><b>close</b></a></p>",name,390,365,42,16,nil,0x324650,nil,true)
        ui.addTextArea(5,"<p align='center'>"..players[name].helpid.."/"..#trans("help").."</p>",name,250,365,42,16,nil,0x324650,nil,true)
    end
end

function chatBox(text,show)
    checkedText = ""
    j = 0
    for i in text:gmatch"." do
        checkedText = checkedText..i
        j = j + 1
        if j == 72 then
            table.insert(chatBoxText,checkedText)
            checkedText = ""
        end
    end
    table.insert(chatBoxText,checkedText)   
    chatBoxTextCounter = 0
    for index,name in pairs(chatBoxText) do
        chatBoxTextCounter = chatBoxTextCounter + 1
    end
    callbackCounter = chatBoxTextCounter
    ui.addTextArea(666,"\t\t"..chatBoxText[chatBoxTextCounter],nil,7,28,476,20,0x324650,0x000000,1,false)
    ui.addTextArea(667,"<a href = 'event:up'>+",nil,8,30,15,15,0x324650,0x324650,1,false)
    ui.addTextArea(668,"<a href = 'event:down'>-",nil,32,30,15,15,0x324650,0x324650,1,false)
end

function eventTextAreaCallback(id,name,callback)
    if callback=="help" then
        eventChatCommand(name,callback)
    elseif callback=="close" then
        players[name].helpid=1
        for id=1,5 do
            ui.removeTextArea(id,name)
            ui.removeTextArea(6969+id,name)
            ui.removeTextArea(7979+id,name)
        end
    elseif callback=="next" and players[name].helpid<#trans("help") then
        players[name].helpid=(players[name].helpid)+1
        ui.updateTextArea(1,trans("help")[players[name].helpid],name)
        ui.updateTextArea(5,"<p align='center'>"..players[name].helpid.."/"..#trans("help").."</p>",name)
    elseif callback=="previous" and players[name].helpid>1 then
        players[name].helpid=players[name].helpid-1
        ui.updateTextArea(1,trans("help")[players[name].helpid],name)
        ui.updateTextArea(5,"<p align='center'>"..players[name].helpid.."/"..#trans("help").."</p>",name)
        elseif callback == "up" then
        if (callbackCounter-1) ~= 0 then
            callbackCounter = callbackCounter - 1
            ui.updateTextArea(666,"\t\t"..chatBoxText[callbackCounter],show)
            ui.updateTextArea(667,"<a href = 'event:up'>+",nil)
            ui.updateTextArea(668,"<a href = 'event:down'>-",nil)
        end
    elseif callback == "down" then
        if  (callbackCounter + 1) <= chatBoxTextCounter then
            callbackCounter = callbackCounter + 1
            ui.updateTextArea(666,"\t\t"..chatBoxText[callbackCounter],show)
            ui.updateTextArea(667,"<a href = 'event:up'>+",nil)
            ui.updateTextArea(668,"<a href = 'event:down'>-",nil)       
        end
    end
end

codeExecution()
 

Killstrike

Active Mouse
thx
btw i added something so there is flight powers :D
and those who helped can teleport ;) i think so :D
 
Last edited:

Xxscarletxx

Little Mouse
Thank you now i can earn bootcamp coins.This really help those who are not good at bootcamp
 
Top
"Dev-TR" theme by Soulzone