View unanswered posts | View active topics It is currently Thu Dec 26, 2024 3:20 pm



Reply to topic  [ 3 posts ] 
 Single Level Activities 
Author Message
User avatar

Joined: Mon Apr 28, 2008 1:35 am
Posts: 383
Reply with quote
Post Single Level Activities
There must be a way to have a custom activity for a single map using Lua. I just don't know how to do it.
I want to use a special activity for just one map and them all come down at a single area.
I looked at the Maginot mission lua, but it doesn't tell me how to use multiple types of spawns.
I looked at the Fort Maligar mission lua but it still only gives dummies, though it does give random weapons. I don't know how it gives random weapons though, so I can't apply that to the actor spawns.
Can someone help me out?

If you wanted to be really helpful you would make it so it spawned one of the 2 robots with a random weapon in a rocket.


Tue Oct 28, 2008 11:41 pm
Profile
User avatar

Joined: Fri Apr 27, 2007 4:55 pm
Posts: 1178
Location: America!
Reply with quote
Post Re: Single Level Activities
I'm not sure exactly what you're asking. Were you looking for something like this:

Code:
AddActivity = GAScripted
   PresetName = Maginot
   SceneName = Maginot
   ScriptFile = Base.rte/Scenes/Scripts/Maginot.lua
   InCampaignStage = 1
   LuaClassName = MaginotMission


And Maginot does the location specific spawns by using

Code:
local attackLZ = SceneMan.Scene:GetArea("Attacker LZ");
        if attackLZ then
            ship.Pos = Vector(attackLZ:GetRandomPoint().X, 0);
        end


Wed Oct 29, 2008 1:37 am
Profile
User avatar

Joined: Mon Apr 28, 2008 1:35 am
Posts: 383
Reply with quote
Post Re: Single Level Activities
I think so. I'll get back to you...


Wed Oct 29, 2008 2:59 am
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 3 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.032s | 13 Queries | GZIP : Off ]