View unanswered posts | View active topics It is currently Fri Feb 28, 2020 6:02 am

 Page 1 of 1 [ 7 posts ]
 Print view Previous topic | Next topic
Making new Area's through Lua (Solved)
Author Message

Joined: Wed May 20, 2009 3:10 pm
Posts: 366
Location: Århus, Denmark
Making new Area's through Lua (Solved)
Would it be possible to make a new area trough lua? I need it because I want to change LZ dynamically

Edit:
Solved

Last edited by akblabla on Sun Sep 18, 2011 9:48 am, edited 1 time in total.

Sun Sep 11, 2011 9:39 am
Data Realms Elite

Joined: Fri Jan 07, 2011 8:01 am
Posts: 6211
Re: Making new Area's through Lua
Well, when you say dinamically you mean like the LZ that moves around the brainbot?
Maybe you should see that script, there might be something useful in there.

Sun Sep 11, 2011 7:03 pm

Joined: Wed May 20, 2009 3:10 pm
Posts: 366
Location: Århus, Denmark
Re: Making new Area's through Lua
Well, when you say dinamically you mean like the LZ that moves around the brainbot?
Maybe you should see that script, there might be something useful in there.

Unfortunately, the landing zone around the brain bot is hard coded. The brain bot lz is just the lz if no other was defined.

Does anyone actually have a list for all the LZ related function. The only ones I can find are

Code:
SetLZArea();

and
Code:
SetBrainLZWidth();

Help?

Edit:
Any area related function will also help

Only ones I know of are

Code:
GetArea

Code:
SetArea

Quote:
HasArea

Though I don't how SetArea actually works. Anybody?

Edit2:

Solved

Code:
local area = Area()
local box = Box()
box.Corner = Vector(TeamSpawnX2[team] , 500)
box.Height = 1000
box.Width = TeamSpawnX1[team] - TeamSpawnX2[team]
self:SetLZArea(team, area);
self:SetBrainLZWidth(team, 0);

Sat Sep 17, 2011 10:04 pm
DRL Developer

Joined: Thu Jun 11, 2009 2:34 pm
Posts: 965
Re: Making new Area's through Lua (Solved)
That's pure fun
Code:
print (self);
print (self.SetLZArea)
print (ActivityMan:GetActivity());
print (ActivityMan:GetActivity().SetLZArea);

Result:
Code:
Activity,GAScripted
Activity,GAScripted
nil

Sun Sep 18, 2011 9:10 pm

Joined: Tue Nov 17, 2009 7:38 pm
Posts: 909
Location: France
Re: Making new Area's through Lua (Solved)
Actually it's Scene:SetArea(), not Activity:SetArea().
You can get the scene using SceneMan.Scene

Fri Sep 23, 2011 6:12 pm

Joined: Sat Jun 19, 2010 5:02 pm
Posts: 331
Location: Mekkan
Re: Making new Area's through Lua (Solved)
What's the difference between scene and activity? Is the activity the Lua itself?

Sat Sep 24, 2011 4:04 am

Joined: Wed May 20, 2009 3:10 pm
Posts: 366
Location: Århus, Denmark
Re: Making new Area's through Lua (Solved)
Awesomeness wrote:
What's the difference between scene and activity? Is the activity the Lua itself?

The activity is the gamemode you play and the scene is what map you choose to play said gamemode on.

Sat Sep 24, 2011 6:37 am
Display posts from previous:  Sort by
 Page 1 of 1 [ 7 posts ]

#### Who is online

Users browsing this forum: No registered users

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

Search for:
 Jump to:  Select a forum ------------------ Cortex Command    Dev Log    Wiki    Game Discussion    Game and Licensing Support    Mod Making       Lua Scripting       Requests    Mod Releases       Older Mods    Scene Releases       Scene Making Planetoid Pioneers    Game Discussion    Pioneer Program Lounge Data Realms Off-Topic    Off Topic Chat       Gaming       Forum Games    Site Support & Feedback