Fortress Forever

Go Back   Fortress Forever > Editing > Mapping > Lua

Reply
 
Thread Tools Display Modes
Old 05-09-2008, 03:29 AM   #1
GeoKill----->
Community Member
Server Owner
Beta Tester
Forum Moderator
 
GeoKill----->'s Avatar
 
Join Date: Mar 2007
Location: Hawthorne, California
Class/Position: Soldier/Spy/Scout
Gametype: AvD
Affiliations: :e0:Eternal Order Leader
Posts Rated Helpful 12 Times
Avanti LUA

Got it off the ff_dev_avanti in the beta file for anyone who needs it
Code:
-- ff_dev_avanti.lua

-----------------------------------------------------------------------------
-- includes
-----------------------------------------------------------------------------
IncludeScript("base_id");

-----------------------------------------------------------------------------
-- global overrides
-----------------------------------------------------------------------------
POINTS_PER_CAPTURE = 10;
POINTS_PER_PERIOD = 1;
PERIOD_TIME = 10;
NUM_PHASES = 4;
INITIAL_ROUND_DELAY = 20;
ROUND_DELAY = 15;

detpack_wall_open = nil
function onroundreset()
    -- close the door
    if detpack_wall_open then
        -- there's no "close".. wtf
        OutputEvent("detpack_wall", "Toggle")
        detpack_wall_open = nil
    end
end

detpack_trigger = info_ff_script:new({})
function detpack_trigger:onexplode(player)
    -- open the door when detpacked
    if not detpack_wall_open and player:GetTeamId() == attackers then
        ConsoleToAll("The door has been blown open!")
        OutputEvent("detpack_wall", "Toggle")
        detpack_wall_open = true
    end
end
It works from the last time I checked it
__________________

:e0: Will live on Forever
Support FF:
GeoKill-----> is offline   Reply With Quote


Old 05-09-2008, 11:02 PM   #2
Crazycarl
D&A Member
Wiki Team
Fortress Forever Staff
 
Crazycarl's Avatar
 
Join Date: Apr 2007
Posts Rated Helpful 31 Times
Or you can just copy from palermo's lua. It has all that and it also switches teams on the respawn turrets when the map resets.
__________________
Support FF:
Crazycarl is offline   Reply With Quote


Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 05:27 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.