RUNNING POLL - ScenEdit requests

Post new mods and scenarios here.

Moderator: MOD_Command

KnightHawk75
Posts: 1850
Joined: Thu Nov 15, 2018 7:24 pm

Re: RUNNING POLL - ScenEdit requests

Post by KnightHawk75 »

blu3s wrote: Thu Jan 26, 2023 3:32 pm Please, ScenEdit_GetReferencePoint() returns nil when trying to get a reference point that doesn't exist
pcall is your friend if you're trying to suppress errmsg and check for success.

Code: Select all

local retval1,refpt =  pcall(ScenEdit_GetReferencePoint,{side="red",name="someNonexistingRP"});
if (retval1) and refpt ~=nil then 
  -- call succeeded use refpt as refpt
else
  print(refpt); --call failed print error msg and handle case for unable to obtain refpt.
end
User avatar
blu3s
Posts: 816
Joined: Fri Jul 08, 2022 9:45 am

Re: RUNNING POLL - ScenEdit requests

Post by blu3s »

KnightHawk75 wrote: Fri Jan 27, 2023 4:23 am
blu3s wrote: Thu Jan 26, 2023 3:32 pm Please, ScenEdit_GetReferencePoint() returns nil when trying to get a reference point that doesn't exist
pcall is your friend if you're trying to suppress errmsg and check for success.

Code: Select all

local retval1,refpt =  pcall(ScenEdit_GetReferencePoint,{side="red",name="someNonexistingRP"});
if (retval1) and refpt ~=nil then 
  -- call succeeded use refpt as refpt
else
  print(refpt); --call failed print error msg and handle case for unable to obtain refpt.
end

Thank you so much!
vonotha
Posts: 60
Joined: Thu Jan 19, 2023 2:28 am

Re: RUNNING POLL - ScenEdit requests

Post by vonotha »

copied from Lua Legion; sorry for incorrect posting place, just recently started exploring forum:

VP_MuteSide / VP_UnmuteSide
vonotha wrote: Tue Jan 31, 2023 4:59 pm I'm developing a scenario with three sides. Two of them are computer controlled.

There is an intense clash between two automated sides in the first phase of the scenario. And it is quite loud ;)

Meanwhile, the only human-controlled side focuses on some preparatory work in places sometimes quite far away from the automated fighing.

Ocassionally, this automated clash may generate a non-actionable message for the human player, but he focuses on his own tasks for the time being.

Finally, when the automated clash is over (and that can take a few in-game hours), the human player becomes active in the clash area.


It would be great to be able to mute the automated combat sounds until the player focus shifts.

VP_MuteSide / VP_UnmuteSide( side ) function would be a great tool for scenarios like this.

Or maybe I'm missing some functionality already present in CMO :)

CMO v1.06 - Build 1328.18; Steam mode; Tacview and all modules except Falklands
User1984
Posts: 86
Joined: Sat Dec 15, 2012 11:48 pm

Re: RUNNING POLL - ScenEdit requests

Post by User1984 »

In the Mission Editor > Mission Settings > Assigned Cargo

Include Heliports in the Assigned Cargo list.

I have heliports included in my created Naval Bases in order to transport cargo from an Airport to a Naval Base.
After helicopters transport cargo from the Airport to the Naval Base, I would then like to be able to load cargo from the heliports onto ships docked at the Naval Base.
User avatar
blu3s
Posts: 816
Joined: Fri Jul 08, 2022 9:45 am

Re: RUNNING POLL - ScenEdit requests

Post by blu3s »

It would be great if there was a method that could extract information from an html "message", that is, like when the special actions window opens and the button executes a predefined action, to have the opportunity to create custom windows in html to display information to the user in a more enjoyable way than the special actions window, and that the user can choose between options, choose items from a list, etc. Each button would have an assigned function (as is already the case with the special actions) and the user could also choose items from a list (which is somehow implemented in the quick battle games). I guess the special actions menu is already created with html and links the buttons with actions, so I think that allowing a method to display this type of window would be trivial.

This would greatly improve the interaction between user and scenario, and it would give a lot of options to scenario designers to create more immersive, replayable and player-specific experiences.
Post Reply

Return to “Mods and Scenarios”