@jtff/miztemplate-lib 3.6.0 → 3.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -257,6 +257,18 @@ function QRATrigger(params)
257
257
  QRAFinex,
258
258
  QRAIndex
259
259
  )
260
+ if (type(dcsbot) ~= 'nil') then
261
+ local title = string.format('QRA triggered !')
262
+ local description = string.format("[%s] triggered a QRA scenario : All QRA pilots, startup and scramble following the procedure",triggerPlayerName)
263
+ local img = 'https://www.defense.gouv.fr/sites/default/files/styles/16_9_sm/public/air/22_09_2023_13.jpeg?itok=n_MPmvZc'
264
+ local fields = {
265
+ ['Trigger'] = triggerPlayerName,
266
+ ['Type'] = QRAArray[QRAIndex].customconfig.type,
267
+ ['Coalition'] = UTILS.GetCoalitionName(QRAArray[QRAIndex].customconfig.benefit_coalition),
268
+ }
269
+ local footer = 'Scramble scramble scramble...'
270
+ dcsbot.sendEmbed(title, description, img, fields, footer)
271
+ end
260
272
  end
261
273
 
262
274
  function QRAFinex(objQRAIndex)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jtff/miztemplate-lib",
3
- "version": "3.6.0",
3
+ "version": "3.6.2",
4
4
  "description": "JTFF mission template library",
5
5
  "main": "index.js",
6
6
  "files": [
@@ -223,14 +223,14 @@ async function doInject(ciObject, sourceMizFileName, workspacePath,destinationMi
223
223
  folder: 'lib',
224
224
  scriptTitle: 'FunkMan',
225
225
  scripts: ['funkman.lua'],
226
- timing: 17,
226
+ timing: 15,
227
227
  color: '0xffff00ff'
228
228
  });
229
229
  libsArray.push({
230
230
  folder: 'src',
231
231
  scriptTitle: 'JTFF Libraries',
232
232
  scripts: ['010-root_menus.lua', '020-mission_functions.lua'],
233
- timing: 18,
233
+ timing: 15,
234
234
  color: '0xffff00ff'
235
235
  });
236
236
  // traitement de la file d'attente des librairies (injection des triggers et des fichiers lua)
@@ -395,6 +395,10 @@ async function doInject(ciObject, sourceMizFileName, workspacePath,destinationMi
395
395
  file: "settings-intercept.lua",
396
396
  objectName: "InterceptConfig"
397
397
  },
398
+ {
399
+ file: "settings-qra.lua",
400
+ objectName: "QRAConfig"
401
+ },
398
402
  );
399
403
  scriptsArray.push({
400
404
  folder: 'src',
@@ -525,7 +529,7 @@ async function doInject(ciObject, sourceMizFileName, workspacePath,destinationMi
525
529
  settingsArray.map(a => a.file),
526
530
  'Mission Settings',
527
531
  mizObject,
528
- 15,
532
+ 17,
529
533
  '0xffff00ff',
530
534
  false
531
535
  );