Matrix Games Forums

Forums  Register  Login  Photo Gallery  Member List  Search  Calendars  FAQ 

My Profile  Inbox  Address Book  My Subscription  My Forums  Log Out

Lua Adding Mounts

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [New Releases from Matrix Games] >> Command: Modern Operations series >> Mods and Scenarios >> Lua Legion >> Lua Adding Mounts Page: [1]
Login
Message << Older Topic   Newer Topic >>
Lua Adding Mounts - 11/26/2020 5:57:48 AM   
Kushan04


Posts: 683
Joined: 6/29/2005
Status: offline
I'm trying to add mounts to units via Lua. In this test I was trying to add another M1A2 SEP Abrams mount to an existing armored unit.

>> ScenEdit_UpdateUnit({guid='P40YQP-0HM4HQ52CI28L',mode='add_mount',dbid=2883})

BUT Its kicking back an error:

ScenEdit_UpdateUnit 0 : ,No targeting arcs supplied for mount M1A2 SEP Abrams Main Battle Tank

I've tried all the arc settings from ScenEdit_UpdateUnit. Anyone have an idea what I'm doing wrong? I'm sure its something simple and right in front of my face.

_____________________________

Post #: 1
RE: Lua Adding Mounts - 11/26/2020 7:01:11 AM   
michaelm75au


Posts: 13500
Joined: 5/5/2001
From: Melbourne, Australia
Status: offline
A mount requires an arc; same as if you added thru the editor.

local arc360 = {'360'}
local ok = ScenEdit_UpdateUnit({guid='P40YQP-0HM4HQ52CI28L',mode='add_mount',dbid=2883,arc_mount=arc360})
print(ok)


_____________________________

Michael

(in reply to Kushan04)
Post #: 2
Page:   [1]
All Forums >> [New Releases from Matrix Games] >> Command: Modern Operations series >> Mods and Scenarios >> Lua Legion >> Lua Adding Mounts Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

0.875