Jump to content

MIssion Scripting Tools (Mist)- enhancing mission scripting Lua


Recommended Posts

Anyone feature requests?

Since the following idea is not directly implemented in the existing trigger system, I was wondering if it was possible to implement in Mist:

 

I would like to see a script such that if someone using a specific callsign logs into a session (primarily MP, but could be SP as well), the aircraft skin is changed from the default skin to a skin specific to that callsign (and visually applied to all clients). For example, if a mission calls for the A-10C from the 104th FS, and I log in as "Home Fries", the script when activated will change the skin from the 104th FS to the "104th FS - Home Fries" skin (the same skin, but with a personalized pilot and canopy markings). It does not have to be a variant of the same skin (e.g. the script could load the 621st FS skin for any given callsign), though the utility of such a script makes sense from a virtual squadron standpoint (where everybody has personalized aircraft).


Edited by Home Fries
Link to comment
Share on other sites

At the very least a real basic retreat could be ordered with the groupToPoint function. It wouldn't always follow their original path, but it'd work.

 

Is it possible to implement such "retreat" function for groups that do not have any waypoints but the first (maybe with two variables: an heading of move and an offset in km or miles... basically it will add a waypoint and start move there)?

ChromiumDis.png

Author of DSMC, mod to enable scenario persistency and save updated miz file

Stable version & site: https://dsmcfordcs.wordpress.com/

Openbeta: https://github.com/Chromium18/DSMC

 

The thing is, helicopters are different from planes. An airplane by it's nature wants to fly, and if not interfered with too strongly by unusual events or by a deliberately incompetent pilot, it will fly. A helicopter does not want to fly. It is maintained in the air by a variety of forces in opposition to each other, and if there is any disturbance in this delicate balance the helicopter stops flying; immediately and disastrously.

Link to comment
Share on other sites

HomeFries, that is beyond the scope of what we can do with scripting.

 

Is it possible to implement such "retreat" function for groups that do not have any waypoints but the first (maybe with two variables: an heading of move and an offset in km or miles... basically it will add a waypoint and start move there)?

 

You mean create a route that is based on traveling bearing x for distance y from their current location?

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

yes :)

ChromiumDis.png

Author of DSMC, mod to enable scenario persistency and save updated miz file

Stable version & site: https://dsmcfordcs.wordpress.com/

Openbeta: https://github.com/Chromium18/DSMC

 

The thing is, helicopters are different from planes. An airplane by it's nature wants to fly, and if not interfered with too strongly by unusual events or by a deliberately incompetent pilot, it will fly. A helicopter does not want to fly. It is maintained in the air by a variety of forces in opposition to each other, and if there is any disturbance in this delicate balance the helicopter stops flying; immediately and disastrously.

Link to comment
Share on other sites

Its easy enough to build. I already use something similar in a group to random point in zone function I'm working on. The only possible problem is that I have not tested what happens if you create a waypoint that is say.... on the black sea. In the past its crashed the sim, but I've also seen vehicles become hover tanks, so results are not guaranteed.

 

I'd also like to add that Mist will likely have two other functions that the "user end" scripts rely on, but they can certainly be used for custom use. One is "buildWP" which takes a table (route part of mission task) and a vec 2/3 point with speed and formation as optional variables. It then creates the necessary entry for a valid ground group waypoint and it adds it to the route. When you are ready to set the task you send a group table and the waypoint table to "goRoute" and it will set the task for the desired group. I think its required as it makes things easier to create a path when the number of waypoints can easily vary depending on how the path is created.

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

Understanded, I will look forward this functions :).

 

Sorry but in the meantime I was thinking of another thing: It could be interesting to make a group under attack to change unit's position accordingly to a pre-defined template created in the ME.

 

I know that it's already possible by trigger system, but it would require to add a triggered action and a trigger to check conditions for any group. In my mind, instead, this action will be acting over a table of groups, in which anytime a group unit has been hit the group itself will activate this "emergency template" position.

 

The emergency template positions in my mind is simply a greater dispersal area, or an alternate units position setup in city area... something customized by ME build in templates creating function.

ChromiumDis.png

Author of DSMC, mod to enable scenario persistency and save updated miz file

Stable version & site: https://dsmcfordcs.wordpress.com/

Openbeta: https://github.com/Chromium18/DSMC

 

The thing is, helicopters are different from planes. An airplane by it's nature wants to fly, and if not interfered with too strongly by unusual events or by a deliberately incompetent pilot, it will fly. A helicopter does not want to fly. It is maintained in the air by a variety of forces in opposition to each other, and if there is any disturbance in this delicate balance the helicopter stops flying; immediately and disastrously.

Link to comment
Share on other sites

If you load mist up in an empty mission does it still produce this error?

Have you installed any mods or modified files in the scripts folder recently?

  • Like 1

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

If you load mist up in an empty mission does it still produce this error?

Have you installed any mods or modified files in the scripts folder recently?

 

I tried an empty mission and it still produced the error, tried script file and just copy&paste for do script.

 

I use JSGME for mods and uninstalled all, still get error. I really have no idea what happened, I haven't touched the MIST lua file, and it worked before on some missions I made.

 

Maybe I will reinstall DCS and see.

Link to comment
Share on other sites

Okay, did a fresh install of 1.2.2, updated to .7570 and it works just fine.

 

So even using JSME there may be a possibility that some files get a little messed up maybe, i'm not sure. I enable/disable all my mods when doing testing, so there is a possibility that something just went screwy. Thanks for fast reply grimes.

Link to comment
Share on other sites

I'm rather curious which mods you have installed/unistalled that might have caused the issue...

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

I'm rather curious which mods you have installed/unistalled that might have caused the issue...

 

Grimes, here is a list of the mods I have. When I was getting the error, all of them were disabled. I then enabled them, and still had the error. Really, I have no idea what happened, I do not recall ever manually editing a script file or anything, I probably did something without realizing it. I have disabled/enabled the mods in JSGME probably like 50x. I really think it's high chance I did something, forgot about it, and then errors happen :music_whistling:

 

Soldier LOD Fix

TACAN ILS

diveplane CA sound mod

smoke stack removal

Kuky's fire & smoke mod

ricardo ka50 bluepit

ka50 jtac

ka50 jtac pilot note

ka50 training missions

nvg mod

Link to comment
Share on other sites

Grimes, here is a list of the mods I have. When I was getting the error, all of them were disabled. I then enabled them, and still had the error. Really, I have no idea what happened, I do not recall ever manually editing a script file or anything, I probably did something without realizing it. I have disabled/enabled the mods in JSGME probably like 50x. I really think it's high chance I did something, forgot about it, and then errors happen :music_whistling:

 

Soldier LOD Fix

TACAN ILS

diveplane CA sound mod

smoke stack removal

Kuky's fire & smoke mod

ricardo ka50 bluepit

ka50 jtac

ka50 jtac pilot note

ka50 training missions

nvg mod

If it happens again, before you fix it, please upload dcs.log, and make note of the latest things you did.

Intelligent discourse can only begin with the honest admission of your own fallibility.

Member of the Virtual Tactical Air Group: http://vtacticalairgroup.com/

Lua scripts and mods:

MIssion Scripting Tools (Mist): http://forums.eagle.ru/showthread.php?t=98616

Slmod version 7.0 for DCS: World: http://forums.eagle.ru/showthread.php?t=80979

Now includes remote server administration tools for kicking, banning, loading missions, etc.

Link to comment
Share on other sites

Hi speed, I saved my old dcs folder (no longer using it but backed it up anyway..) and it still has the logs. You can download in attachment or view below. I made it .txt as it seems .log files are invalid for attachments.

 

 

DCS Log file (at the end it shows the error I had...)

00000.000 INFO    EDCORE: createSerialQueue IOQueue
00000.102 INFO    VFS: Using 'Saved Games': "C:\Users\Tyson\Saved Games"
00000.102 INFO    DCS: DCS/1.2.2.7570 (x86_64; Windows/6.1.7601)
00000.113 INFO    Dispatcher: 2013/2/13 03:23 V1107131420
00000.132 INFO    NET: events.lua loaded
00000.133 WARNING LOG: 1 duplicate message(s) skipped.
00000.133 INFO    NET: loading ./Scripts/net/default.cfg : OK
00000.133 INFO    NET: loading C:\Users\Tyson\Saved Games\DCS\Config/network.cfg : OK
00000.133 INFO    NET: loading ./Scripts/net/net_types.lua : OK
00000.133 INFO    NET: default_conn is 3
00000.159 INFO    SOUND: loaded 494 sdefs from "sounds\sdef"
00000.163 INFO    SOUND: XAudio2: Using device ID:'{0.0.0.00000000}.{ec1c4f84-6a49-47c2-a7db-70ec91d7377d}' Name:'Headphones (ASUS Xonar Essence STX Audio Device)', channels: 2
00000.163 INFO    SOUND: XAudio2: channel layout: Headphones/Stereo
00000.170 INFO    SOUND: Using SSE FTZ mode.
00000.174 INFO    WorldPlugIns: Loaded plugin module CockpitBase.dll
00000.278 UNKNOWN WinMain: MOD loading:	./mods/aircrafts/A-10C/entry.lua
00000.278 UNKNOWN WinMain: MOD loading:	./mods/aircrafts/Ka-50/entry.lua
00000.279 UNKNOWN WinMain: MOD loading:	./mods/aircrafts/P-51D/entry.lua
00000.279 UNKNOWN WinMain: MOD loading:	./mods/aircrafts/Su-25T/entry.lua
00000.279 UNKNOWN WinMain: MOD loading:	./DemoMods/tech/CombinedArms/entry.lua
00000.279 ERROR   EDCORE: can't open MO-file D:\DCS World\DemoMods\tech\CombinedArms\l10n\en\LC_MESSAGES\messages.mo
00000.279 UNKNOWN WinMain: MOD loading:	./DemoMods/aircrafts/A-10C/entry.lua
00000.279 UNKNOWN WinMain: MOD loading:	./DemoMods/aircrafts/Flaming Cliffs/entry.lua
00000.279 ERROR   EDCORE: can't open MO-file D:\DCS World\DemoMods\aircrafts\Flaming Cliffs\l10n\en\LC_MESSAGES\messages.mo
00000.279 UNKNOWN WinMain: MOD loading:	./DemoMods/aircrafts/Ka-50/entry.lua
00000.279 UNKNOWN WinMain: MOD loading:	./DemoMods/aircrafts/P-51D/entry.lua
00000.279 UNKNOWN WinMain: PLUGINS START-------------------------------------------------
00000.279 UNKNOWN WinMain: plugin: A-10C Warthog by Eagle Dynamics applied
00000.279 UNKNOWN WinMain: plugin: Ka-50 Black Shark by Eagle Dynamics applied
00000.279 UNKNOWN WinMain: plugin: P-51D Mustang by Eagle Dynamics applied
00000.279 UNKNOWN WinMain: plugin: Su-25T by Eagle Dynamics applied
00000.280 UNKNOWN WinMain: plugin: Combined Arms by Eagle Dynamics applied
00000.280 UNKNOWN WinMain: plugin: Flaming Cliffs by Eagle Dynamics applied
00000.280 UNKNOWN WinMain: PLUGINS DONE--------------------------------------------------
00000.287 UNKNOWN WinMain: ./MissionEditor/data/scripts/unitsclasses.lua	loaded
00000.288 UNKNOWN WinMain: ./MissionEditor/data/NewMap/classifier.lua	loaded
00016.219 INFO    SOUND: loaded 0 sdefs from "c:\users\tyson\saved games\dcs\sounds"
00016.220 INFO    DXRENDERER: Creating Resource "Unicode" of type 5
00016.804 WARNING LOG: 8 duplicate message(s) skipped.
00016.804 INFO    DCS: srRes = 422860543, srGoodValue  = 422860543 skip
00016.804 UNKNOWN WinMain: DCS started
00016.807 UNKNOWN WinMain: Speech.phrase module loaded
00016.812 UNKNOWN WinMain: "Allied Flight" role
00016.812 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.812 UNKNOWN WinMain: 		"GERMANY" accent found
00016.812 UNKNOWN WinMain: 		"FRANCE" accent found
00016.812 UNKNOWN WinMain: 		"RUSSIA" accent found
00016.812 UNKNOWN WinMain: 		"USA" accent found
00016.812 UNKNOWN WinMain: 			voice 1 found
00016.812 UNKNOWN WinMain: 			voice 2 found
00016.812 UNKNOWN WinMain: 			voice 3 found
00016.812 UNKNOWN WinMain: 		"SPAIN" accent found
00016.812 UNKNOWN WinMain: 		"UK" accent found
00016.812 UNKNOWN WinMain: "A-10 VMU" role
00016.812 UNKNOWN WinMain: 	"A-10C" - "ENG" found
00016.812 UNKNOWN WinMain: "ATC" role
00016.812 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.813 UNKNOWN WinMain: "AWACS" role
00016.813 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.813 UNKNOWN WinMain: "PLAYER" role
00016.813 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.813 UNKNOWN WinMain: 	"Ka-50" - "ENG" found
00016.813 UNKNOWN WinMain: "ALMAZ" role
00016.813 UNKNOWN WinMain: 	"Ka-50" - "ENG" found
00016.813 UNKNOWN WinMain: "BETTY" role
00016.813 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.814 UNKNOWN WinMain: "Ground Crew" role
00016.814 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.814 UNKNOWN WinMain: "JTAC" role
00016.814 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.814 UNKNOWN WinMain: "WINGMAN" role
00016.814 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.814 UNKNOWN WinMain: 			voice 1 found
00016.814 UNKNOWN WinMain: 			voice 2 found
00016.814 UNKNOWN WinMain: 			voice 3 found
00016.814 UNKNOWN WinMain: 	"Ka-50" - "ENG" found
00016.814 UNKNOWN WinMain: 			voice 1 found
00016.814 UNKNOWN WinMain: 			voice 2 found
00016.814 UNKNOWN WinMain: 			voice 3 found
00016.814 UNKNOWN WinMain: "CCC" role
00016.815 UNKNOWN WinMain: "TANKER" role
00016.815 UNKNOWN WinMain: 	"Common" - "ENG" found
00016.815 UNKNOWN WinMain: Speech.common modules loaded
00016.816 UNKNOWN WinMain: Speech.NATO module loaded
00016.817 UNKNOWN WinMain: Speech.USSR module loaded
00016.817 UNKNOWN WinMain: Speech module loaded
00016.879 ERROR   DXGUI_EDGE_RENDER: Cannot load texture ''
00016.936 INFO    Dispatcher: loading mission file: "C:\Users\Tyson\AppData\Local\Temp\DCS\tempMission.miz"
00017.045 ERROR   EDOBJECTS: Object LAU-68 + HYDRA-70 MK1 with id=105 already declared in table ContainerTable
00017.045 ERROR   EDOBJECTS: Object LAU-68 + HYDRA-70 MK5 with id=106 already declared in table ContainerTable
00017.073 INFO    TERRAIN: lSystem::lSystem
00017.074 INFO    TERRAIN: lSystem::Init Bazar/Terrain/terrain.cfg.lua
00017.074 INFO    EDTERRAINGRAPHICS3: lma: .///Bazar/Graphics/lma/edge_infrared.lua
00017.075 INFO    EDTERRAINGRAPHICS3: lma: .///Bazar/Graphics/lma/edge_land.lua
00017.075 INFO    EDTERRAINGRAPHICS3: lma: .///Bazar/Graphics/lma/edge_landheight.lua
00017.076 INFO    EDTERRAINGRAPHICS3: lma: .///Bazar/Graphics/lma/edge_lights.lua
00017.076 INFO    EDTERRAINGRAPHICS3: lma: .///Bazar/Graphics/lma/edge_map.lua
00017.077 INFO    EDTERRAINGRAPHICS3: lma: .///Bazar/Graphics/lma/edge_mfd.lua
00017.077 INFO    EDTERRAINGRAPHICS3: lma: .///Bazar/Graphics/lma/land3.1.lua
00017.077 INFO    EDTERRAINGRAPHICS3: lma: .///Bazar/Graphics/lma/edge_shelf.lua
00017.128 INFO    WEAPONSBASE: srRes = 959731252, srGoodValue  = 959731252 skip
00017.426 INFO    VISUALIZER: envlevelel 0
00018.151 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: scripts/input/CommandMenuItems.lua
00018.151 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: scripts/input/TrainingWaitForUser.lua
00018.151 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: scripts/input/JFT.lua
00018.151 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: C:\Users\Tyson\Saved Games\DCS\Config/Input//default/mouse/Mouse.lua
00018.152 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: C:\Users\Tyson\Saved Games\DCS\Config/Input//default/keyboard/Keyboard.lua
00018.152 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: C:\Users\Tyson\Saved Games\DCS\Config/Input//default/joystick/Joystick - HOTAS Warthog {AC004290-D6AD-11e1-8001-444553540000}.lua
00018.152 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: C:\Users\Tyson\Saved Games\DCS\Config/Input//default/joystick/Throttle - HOTAS Warthog {AC004290-D6AD-11e1-8002-444553540000}.lua
00018.152 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: C:\Users\Tyson\Saved Games\DCS\Config/Input//default/joystick/Controller (XBOX 360 For Windows) {32305530-D71C-11e1-8001-444553540000}.lua
00018.153 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: C:\Users\Tyson\Saved Games\DCS\Config/Input//default/joystick/Saitek Pro Flight Rudder Pedals {AC0069A0-D6AD-11e1-8003-444553540000}.lua
00018.153 UNKNOWN NewInputLuaBinder::NewInputLuaBinder: C:\Users\Tyson\Saved Games\DCS\Config/Input//default/trackir/TrackIR.lua
00018.156 INFO    DCS: Dispatcher: initial random seed = 7448359
00018.156 INFO    DCS: Dispatcher: apply random seed = 7448359
00018.159 INFO    TERRAIN: lSystem::Load()
00018.881 INFO    EDOBJECTS: shape trees_1_blk not found in shapetables
00018.881 INFO    EDOBJECTS: shape trees_3_blk not found in shapetables
00018.881 INFO    EDOBJECTS: shape trees_5_blk not found in shapetables
00018.881 INFO    EDOBJECTS: shape trees_6_blk not found in shapetables
00018.881 INFO    EDOBJECTS: shape trees_7_blk not found in shapetables
00018.881 INFO    EDOBJECTS: shape trees_8_blk not found in shapetables
00018.881 INFO    EDOBJECTS: shape trees_9_blk not found in shapetables
00018.881 INFO    EDOBJECTS: shape trees_2_blk not found in shapetables
00018.881 INFO    EDOBJECTS: shape trees_4_blk not found in shapetables
00018.885 INFO    TERRAIN: lSystem::InitSurface()
00018.958 INFO    TERRAIN: lSystem::InitScenes()
00018.999 INFO    WORLDGENERAL: loaded from mission Scripts/World/GPS_GNSS.lua
00019.010 INFO    EDCORE: LexicalAnalyser: Cannot open .\Bazar\Effects\SmokeTail\High\smokeBigRocket.cfg
00019.010 INFO    EDCORE: LexicalAnalyser: Cannot open .\Bazar\Effects\SmokeTail\High\smokeNoSharpen.cfg
00019.011 INFO    EDCORE: LexicalAnalyser: Cannot open .\Bazar\Effects\SmokeTail\High\traceBigRocket.cfg
00019.011 INFO    EDCORE: LexicalAnalyser: Cannot open .\Bazar\Effects\SmokeTail\High\traceNoSharpen.cfg
00019.338 INFO    EDCORE: LexicalAnalyser: Cannot open .\Bazar\Effects\Damage/Fire\High\fire.cfg
00019.571 ERROR   DXRENDERER: JSmokeMaterial: failed to create VB, D3DERR_INVALIDCALL
00019.576 INFO    WORLDGENERAL: loaded from mission Config/View/SnapViewsDefault.lua
00019.577 INFO    WORLDGENERAL: loaded from mission Config/View/View.lua
00019.578 INFO    WORLDGENERAL: loaded from mission Config/View/Server.lua
00019.584 INFO    Config: netview started
00019.626 WARNING NGMODEL: Model 'trees_1_blk' has invalid bounding box.
00019.627 WARNING NGMODEL: Model 'trees_3_blk' has invalid bounding box.
00019.627 WARNING NGMODEL: Model 'trees_5_blk' has invalid bounding box.
00019.627 WARNING NGMODEL: Model 'trees_6_blk' has invalid bounding box.
00019.627 WARNING NGMODEL: Model 'trees_7_blk' has invalid bounding box.
00019.636 WARNING NGMODEL: Model 'trees_8_blk' has invalid bounding box.
00019.636 WARNING NGMODEL: Model 'trees_9_blk' has invalid bounding box.
00019.745 WARNING NGMODEL: Model 'trees_2_blk' has invalid bounding box.
00019.746 WARNING NGMODEL: Model 'trees_4_blk' has invalid bounding box.
00020.330 INFO    DCS: ComplexTask::open_state(). Precached tasks data loading.
00020.330 INFO    DCS: ComplexTask::load_task_data(). "Follow_Line" task data loaded.
00020.330 INFO    DCS: ComplexTask::load_task_data(). "Follow_Vector" task data loaded.
00020.330 INFO    DCS: ComplexTask::load_task_data(). "Follow_Vector_Old" task data loaded.
00020.330 INFO    DCS: ComplexTask::load_task_data(). "Approach" task data loaded.
00020.330 INFO    DCS: ComplexTask::load_task_data(). "Cannon_Ground_Attack" task data loaded.
00020.331 INFO    DCS: ComplexTask::load_task_data(). "Rocket_Attack" task data loaded.
00020.331 INFO    DCS: ComplexTask::load_task_data(). "Level_Bombing" task data loaded.
00020.331 INFO    DCS: ComplexTask::load_task_data(). "Dive_Bombing" task data loaded.
00020.332 INFO    DCS: ComplexTask::load_task_data(). "Missile_Ground_Target_Attack" task data loaded.
00020.332 INFO    DCS: ComplexTask::load_task_data(). "Missile_Ground_Target_Level_Attack" task data loaded.
00022.692 ERROR   Lua::Config: load error Scripts/MissionScripting.lua:can't open 'Scripts/MissionScripting.lua'.
00023.493 UNKNOWN ExitDialog::ExitDialog: Cannot load skin[windowHeaderTheme] from file [nil]
00023.496 INFO    EDTERRAINGRAPHICS3: Force loading pipeline 'lockon'. Radius 150000.000000. Pos=-328294.593750,14.956457,631220.000000!
00024.737 INFO    EDTERRAINGRAPHICS3: force loading finished!
00024.737 INFO    EDTERRAINGRAPHICS3: Force loading pipeline 'map'. Radius 30000.000000. Pos=-328294.593750,14.956457,631220.000000!
00024.810 INFO    EDTERRAINGRAPHICS3: force loading finished!
00025.285 ERROR   DXRENDERER: DXDefTexture: failed to open file land_l2_-25_28.png
00025.287 ERROR   DXRENDERER: DXDefTexture: failed to open file land_l2_-25_29.png
00025.316 ERROR   DXRENDERER: DXDefTexture: failed to open file land_l2_-25_30.png
00025.335 ERROR   DXRENDERER: DXDefTexture: failed to open file land_l2_-25_31.png
00025.338 ERROR   DXRENDERER: DXDefTexture: failed to open file land_l2_-25_32.png
00025.350 ERROR   DXRENDERER: DXDefTexture: failed to open file land_l2_-25_33.png
00025.360 ERROR   DXRENDERER: DXDefTexture: failed to open file land_l2_-25_34.png
00025.368 ERROR   DXRENDERER: DXDefTexture: failed to open file land_l2_-25_35.png
00025.887 INFO    DXRENDERER: Creating Resource "Unicode" of type 5
00038.787 ERROR   Trigger: [string "--[[..."]:351: attempt to call field 'addEventHandler' (a nil value)
00038.808 UNKNOWN ?: got command 57
00048.920 INFO    Config: netview stopped
00049.011 INFO    SOUND: detaching sdef path "c:\users\tyson\saved games\dcs\sounds\"
00049.011 INFO    SOUND: detaching sdef path "sounds\sdef\"

dcs.txt


Edited by Quirkitized
Link to comment
Share on other sites

Here was the problem:

 

00022.692 ERROR Lua::Config: load error Scripts/MissionScripting.lua:can't open 'Scripts/MissionScripting.lua'.

 

Now its a question of why that file got messed up.


Edited by Grimes

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

Ahem...

00022.692 ERROR   Lua::Config: load error Scripts/MissionScripting.lua:can't open 'Scripts/MissionScripting.lua'.

 

Your MissionScripting.lua file did not exist. Did you install Slmod, uninstall Slmod, and then forget to restore the old MissionScripting.lua file?

Intelligent discourse can only begin with the honest admission of your own fallibility.

Member of the Virtual Tactical Air Group: http://vtacticalairgroup.com/

Lua scripts and mods:

MIssion Scripting Tools (Mist): http://forums.eagle.ru/showthread.php?t=98616

Slmod version 7.0 for DCS: World: http://forums.eagle.ru/showthread.php?t=80979

Now includes remote server administration tools for kicking, banning, loading missions, etc.

Link to comment
Share on other sites

That's the thing, I do not remember. Based on both your knowledge, I am going to assume that was the case.

 

The problem is, I was using MIST just a few days before and really can't remember what I did, so it obviously had something to do with that file.

 

Chalk this up to user error. If anything, somebody might make same mistake in future and can learn from this.

Link to comment
Share on other sites

  • 2 weeks later...

I've been working on porting a message system I made in an unreleased mission to be a little more robust for usage within Mist. Basically you send the text, time to display, and "who sees it" to a function and it will automatically display the message to the relevant groups. You can send messages to very specific groups, for example you can easily send a message to all Su-25T pilots on Red. However the most useful feature of this function is that the messages are appended to the same message box instead of over-writing a previous message.

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

Hi all, since I can't understand lua much well (and I do not have much time to do that :( ), I'm going to ask you if, with the new added function, there is a way to:

 

1. turn on IA of groups when they are at a certain range of any enemy units.

2. turn on IA of groups that are under attack.

3. turn off IA of groups that are far more than a certain range of enemy units.

 

whitout the use of the trigger system (or at least use it to run few scripts).

ChromiumDis.png

Author of DSMC, mod to enable scenario persistency and save updated miz file

Stable version & site: https://dsmcfordcs.wordpress.com/

Openbeta: https://github.com/Chromium18/DSMC

 

The thing is, helicopters are different from planes. An airplane by it's nature wants to fly, and if not interfered with too strongly by unusual events or by a deliberately incompetent pilot, it will fly. A helicopter does not want to fly. It is maintained in the air by a variety of forces in opposition to each other, and if there is any disturbance in this delicate balance the helicopter stops flying; immediately and disastrously.

Link to comment
Share on other sites

The scripting could be used to determine those 3 situations, however the only thing lacking is a way to enable/disable AI via scripting.

The right man in the wrong place makes all the difference in the world.

Current Projects:  Grayflag ServerScripting Wiki

Useful Links: Mission Scripting Tools MIST-(GitHub) MIST-(Thread)

 SLMOD, Wiki wishlist, Mission Editing Wiki!, Mission Building Forum

Link to comment
Share on other sites

The scripting could be used to determine those 3 situations, however the only thing lacking is a way to enable/disable AI via scripting.

 

ok... so... it could be possible to set the ROE and/or the ALARM STATE instead of IA? if I set alarm state green and ROE as return fire, I believe that the AI impact on performances could be still reduced :)

ChromiumDis.png

Author of DSMC, mod to enable scenario persistency and save updated miz file

Stable version & site: https://dsmcfordcs.wordpress.com/

Openbeta: https://github.com/Chromium18/DSMC

 

The thing is, helicopters are different from planes. An airplane by it's nature wants to fly, and if not interfered with too strongly by unusual events or by a deliberately incompetent pilot, it will fly. A helicopter does not want to fly. It is maintained in the air by a variety of forces in opposition to each other, and if there is any disturbance in this delicate balance the helicopter stops flying; immediately and disastrously.

Link to comment
Share on other sites

i have a little problem, with define a table

 

i use to define the unit tables:

Blue_Fighter = {
'Eagle 1-1', 'Eagle 1-2', 'Eagle 2-1', 'Eagle 2-2'}

Blue_Bomber = {
'Toad 1-1', 'Toad 1-2', 'Toad 2-1', 'Toad 2-2'}

 

and try to check, if any of this units are in the zone: Sector0, Sector1 and Sector2

mist.flagFunc.units_in_zones{
 units = {Blue_Fighter, Blue_Bomber},
 zones = {'Sector0', 'Sector1', 'Sector2'},
 flag = 50,
 zone_type = 'cylinder',
 interval = 30,
}

 

but i got the FLAG 50 not true - i got it only true, if i put every single aircraft ('Eagle 1-1', 'Eagle 1-1' ...) into the units = {} table.

 

so i think it is the define of the table, which give me trouble! What must i change?

Playing: F-16C

Intel i7-13700KF, 64GB DDR5 @5600MHz, RTX 4080 ZOTAC Trinity, WIN 11 64Bit Prof.

Squadron "Serious Uglies" / Discord-Server: https://discord.gg/2WccwBh

Ghost0815

Link to comment
Share on other sites

i have a little problem, with define a table

 

i use to define the unit tables:

Blue_Fighter = {
'Eagle 1-1', 'Eagle 1-2', 'Eagle 2-1', 'Eagle 2-2'}

Blue_Bomber = {
'Toad 1-1', 'Toad 1-2', 'Toad 2-1', 'Toad 2-2'}

 

and try to check, if any of this units are in the zone: Sector0, Sector1 and Sector2

mist.flagFunc.units_in_zones{
 units = {Blue_Fighter, Blue_Bomber},
 zones = {'Sector0', 'Sector1', 'Sector2'},
 flag = 50,
 zone_type = 'cylinder',
 interval = 30,
}

 

but i got the FLAG 50 not true - i got it only true, if i put every single aircraft ('Eagle 1-1', 'Eagle 1-1' ...) into the units = {} table.

 

so i think it is the define of the table, which give me trouble! What must i change?

 

When you write a table in Lua like this:

 

{ 
'Unit #1', 
'Unit #2', 
'Unit #3', 
'Unit #4'
}

what you are really writing is this:

{
[1] = 'Unit #1',
[2] = 'Unit #2',
[3] = 'Unit #3',
[4] = 'Unit #4'
}

Lua just lets you skip the process of specifying what table index to add each piece of data to- if you do not specify a table index to put your data at, it will just puts it at the first empty integer index (starting at 1).

 

So basically, what this does in your code:

{Blue_Fighter, Blue_Bomber},

 

is make a table that looks like this:

{
[1] = {
	[1] = 'Eagle 1-1', 
	[2] = 'Eagle 1-2', 
	[3] = 'Eagle 2-1', 
	[4] = 'Eagle 2-2'
},
[2] = {
	[1] = 'Toad 1-1', 
	[2] = 'Toad 1-2', 
	[3] = 'Toad 2-1', 
	[4] = 'Toad 2-2'
},
}

 

Obviously, this is the wrong format for Mist- you made a table of tables, Mist requires a table of unit names.

 

So you either need to merge the two tables, or make a single table that has all unit names from the start.

 

HOWEVER, you might also be going about this all wrong. Mist uses the same unit able short cuts that Slmod does. So, let's say you want to make a table of unit names that includes all blue aircraft accept those named "Hawg11", "Hawg12", "Hawg13", and "Hawg14":

{ '[blue][plane]', '[-u]Hawg11', '[-u]Hawg12', '[-u]Hawg13', '[-u]Hawg14' }

 

Please see the UnitNameTables section of the Mist guide for more info and examples.

Intelligent discourse can only begin with the honest admission of your own fallibility.

Member of the Virtual Tactical Air Group: http://vtacticalairgroup.com/

Lua scripts and mods:

MIssion Scripting Tools (Mist): http://forums.eagle.ru/showthread.php?t=98616

Slmod version 7.0 for DCS: World: http://forums.eagle.ru/showthread.php?t=80979

Now includes remote server administration tools for kicking, banning, loading missions, etc.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...