s2cfgtojson 3.7.0 → 3.7.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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/types.mts +177 -69
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "s2cfgtojson",
3
- "version": "3.7.0",
3
+ "version": "3.7.2",
4
4
  "description": "Converts Stalker 2 Cfg file into POJOs",
5
5
  "keywords": [
6
6
  "stalker",
package/types.mts CHANGED
@@ -76,6 +76,14 @@ import {
76
76
  EFastUseGroupType,
77
77
  EDetectorType,
78
78
  ESpawnType,
79
+ EJournalEntity,
80
+ EJournalState,
81
+ EQuestNodeState,
82
+ ERelationLevel,
83
+ EThreatAwareness,
84
+ EMainHandEquipmentType,
85
+ EBrokenGameDataFilter,
86
+ EDialogAnimationType,
79
87
  } from "./enums.mts";
80
88
 
81
89
  import { Struct } from "./Struct.mjs";
@@ -375,7 +383,7 @@ export type ALifeDirectorScenarioPrototype = GetStructType<{
375
383
  };
376
384
  }>;
377
385
 
378
- export type DialogPrototype = GetStructType<{
386
+ interface IDialogPrototype {
379
387
  SID: string;
380
388
  DialogChainPrototypeSID: string;
381
389
  DialogMemberIndex: number;
@@ -383,90 +391,183 @@ export type DialogPrototype = GetStructType<{
383
391
  DialogMembersAnimations: {
384
392
  EmotionalState: EEmotionalFaceMasks;
385
393
  LookAtTarget: number;
386
- DialogAnimations: string;
394
+ DialogAnimations: {
395
+ GestureTiming: number[];
396
+ DialogAnimationType: EDialogAnimationType;
397
+ }[];
387
398
  }[];
388
399
  AKEventName: string;
389
400
  AKEventSubPath: string;
401
+ FaceAnimationSubPath: string;
402
+ FaceAnimationAssetName: string;
390
403
  NextDialogOptions: {
391
- [key: number]: {
392
- NextDialogSID: string;
393
- Terminate: boolean;
394
- AvailableFromStart: boolean;
395
- VisibleOnFailedCondition: boolean;
396
- MainReply: boolean;
397
- AnswerTo: string;
398
- IncludeBy: string;
399
- ExcludeBy: string;
400
- Conditions: {
401
- ConditionType: EQuestConditionType;
402
- ConditionComparance: EConditionComparance;
403
- LinkedNodePrototypeSID: string;
404
- CompletedNodeLauncherNames: never[];
405
- }[][];
406
- };
407
- True: {
408
- Conditions: {
409
- ConditionType: EQuestConditionType;
410
- ConditionComparance: EConditionComparance;
411
- GlobalVariablePrototypeSID: string;
412
- ChangeValueMode: EChangeValueMode;
413
- VariableValue: number;
414
- LinkedNodePrototypeSID: string;
415
- CompletedNodeLauncherNames: never[];
416
- }[][];
417
- NextDialogSID: string;
418
- Terminate: boolean;
419
- };
420
- False: { NextDialogSID: string; Terminate: boolean };
421
- };
404
+ NextDialogSID: string;
405
+ Terminate: boolean;
406
+ AvailableFromStart: boolean;
407
+ VisibleOnFailedCondition: boolean;
408
+ MainReply: boolean;
409
+ AnswerTo: number;
410
+ IncludeBy: string[];
411
+ ExcludeBy: string[];
412
+ Conditions: {
413
+ ConditionType: EQuestConditionType;
414
+ ConditionComparance: EConditionComparance;
415
+ JournalEntity: EJournalEntity;
416
+ JournalState: EJournalState;
417
+ JournalQuestSID: string;
418
+ JournalQuestStageSID: string;
419
+ TargetCharacter: string;
420
+ ItemPrototypeSID:
421
+ | string
422
+ | { VariableType: EGlobalVariableType; VariableValue: string };
423
+ ItemsCount:
424
+ | number
425
+ | { VariableType: EGlobalVariableType; VariableValue: number };
426
+ WithEquipped: boolean;
427
+ WithInventory: boolean;
428
+ RandomProbability: number;
429
+ Money:
430
+ | number
431
+ | { VariableType: EGlobalVariableType; VariableValue: number };
432
+ LinkedNodePrototypeSID: string;
433
+ CompletedNodeLauncherNames: string[];
434
+ TargetNode: string;
435
+ NodeState: EQuestNodeState;
436
+ GlobalVariablePrototypeSID: string;
437
+ ChangeValueMode: EChangeValueMode;
438
+ VariableValue: number;
439
+ Rank: ERank;
440
+ Faction: string;
441
+ Relationships: ERelationLevel;
442
+ Equipment: EMainHandEquipmentType;
443
+ }[][];
444
+ }[];
422
445
  HasVOInSequence: boolean;
423
- DialogActions: {
424
- DialogAction: EDialogAction;
425
- DialogActionParam:
426
- | {
427
- VariableType: EGlobalVariableType;
428
- VariableValue: number | string | boolean;
429
- }
430
- | number;
431
- ItemsCount: {
446
+ VisibleOnFailedCondition: boolean;
447
+ MainReply: boolean;
448
+ DialogActions: { DialogAction: EDialogAction }[];
449
+ NodePrototypeVersion: number;
450
+ Text: string;
451
+ AnswerText: string;
452
+ CanBeInterrupted: boolean;
453
+ TopicAvailabilityConditions: ({
454
+ ConditionType: EQuestConditionType;
455
+ TargetNPC: string;
456
+ TargetContextualActionPlaceholder: string;
457
+ ConditionComparance: EConditionComparance;
458
+ Money: {
432
459
  VariableType: EGlobalVariableType;
433
- VariableValue: number | string | boolean;
460
+ VariableValue: number;
434
461
  };
462
+ TargetCharacter: string;
463
+ IncludePartialOverload: boolean;
464
+ ItemPrototypeSID:
465
+ | string
466
+ | { VariableType: EGlobalVariableType; VariableValue: string };
467
+ ItemsCount:
468
+ | number
469
+ | { VariableType: EGlobalVariableType; VariableValue: number };
435
470
  WithEquipped: boolean;
436
- }[];
437
- DialogAnswerActions: {
438
- DialogAction: EDialogAction;
439
- DialogActionParam:
440
- | {
441
- VariableType: EGlobalVariableType;
442
- VariableValue: number | string | boolean;
443
- }
444
- | number;
445
- ItemsCount: {
446
- VariableType: EGlobalVariableType;
447
- VariableValue: number | string | boolean;
471
+ WithInventory: boolean;
472
+ ThreatAwareness: EThreatAwareness;
473
+ RequiredSquadMembers: ERequiredSquadMembers;
474
+ EmissionPrototypeSID: string;
475
+ NumericValue: number;
476
+ TargetPoint: {
477
+ X: number;
478
+ Y: number;
479
+ Z: number;
448
480
  };
449
- WithEquipped: boolean;
450
- }[];
451
- NodePrototypeVersion: number;
452
- FaceAnimationSubPath: string;
453
- FaceAnimationAssetName: string;
454
- LocalizedSequences: never[];
481
+ Rank: ERank;
482
+ Faction: string;
483
+ Relationships: ERelationLevel;
484
+ Trigger: string;
485
+ bTriggersByAnybody: boolean;
486
+ ReactType: ETriggerReact;
487
+ }[] & {
488
+ ConditionType: EQuestConditionType;
489
+ ConditionComparance: EConditionComparance;
490
+ EmissionPrototypeSID: string;
491
+ })[];
492
+ LocalizedSequences: string[];
455
493
  LoopSequence: boolean;
456
494
  PreblendSequence: boolean;
457
495
  PreblendTime: number;
458
496
  BlendExpForEaseInOut: number;
459
497
  SpeechDuration: number;
460
498
  ShowNextDialogOptionsAsAnswers: boolean;
499
+ WaitForSequenceToFinish: boolean;
461
500
  Conditions: {
462
501
  ConditionType: EQuestConditionType;
463
502
  ConditionComparance: EConditionComparance;
503
+ NumericValue: number;
504
+ TargetCharacter: string;
505
+ ItemPrototypeSID:
506
+ | string
507
+ | {
508
+ VariableType: EGlobalVariableType;
509
+ VariableValue: string;
510
+ };
511
+ WithEquipped: boolean;
512
+ WithInventory: boolean;
513
+ DialogMemberIndex: number;
514
+ ItemsCount: {
515
+ VariableType: EGlobalVariableType;
516
+ VariableValue: number;
517
+ };
518
+ TargetNode: string;
519
+ NodeState: EQuestNodeState;
520
+ TargetNPC: string;
521
+ TargetContextualActionPlaceholder: string;
522
+ GlobalVariablePrototypeSID: string;
523
+ ChangeValueMode: EChangeValueMode;
524
+ VariableValue: number;
525
+ JournalEntity: EJournalEntity;
526
+ JournalState: EJournalState;
527
+ JournalQuestSID: string;
528
+ Rank: ERank;
529
+ Faction: string;
530
+ Relationships: ERelationLevel;
464
531
  LinkedNodePrototypeSID: string;
465
- CompletedNodeLauncherNames: never[];
532
+ CompletedNodeLauncherNames: string[];
533
+ RequiredSquadMembers: ERequiredSquadMembers;
466
534
  }[][];
467
- VisibleOnFailedCondition: boolean;
468
- MainReply: boolean;
469
- }>;
535
+ DialogAnswerActions: {
536
+ DialogAction: EDialogAction;
537
+ DialogActionParam: {
538
+ VariableType: EGlobalVariableType;
539
+ VariableValue: string | number;
540
+ };
541
+ ItemsCount: {
542
+ VariableType: EGlobalVariableType;
543
+ VariableValue: number;
544
+ };
545
+ WithEquipped: boolean;
546
+ GlobalVariablePrototypeSID: string;
547
+ ChangeValueMode: EChangeValueMode;
548
+ VariableValue: number;
549
+ ConsumablePrototypeSID: {
550
+ VariableType: EGlobalVariableType;
551
+ VariableValue: string;
552
+ };
553
+ }[];
554
+ DialogMemberName: string;
555
+ AssetsSubPath: string;
556
+ VoiceModulatorPrototypeID: string;
557
+ BrokenGameDataFilter: EBrokenGameDataFilter;
558
+ TargetLocation: string;
559
+ SelfLocation: string;
560
+ RotationTime: number;
561
+ Actions: {
562
+ DialogAction: EDialogAction;
563
+ DialogActionParam: {
564
+ VariableType: EGlobalVariableType;
565
+ VariableValue: string | number;
566
+ };
567
+ }[];
568
+ }
569
+
570
+ export type DialogPrototype = GetStructType<IDialogPrototype>;
470
571
 
471
572
  export type DifficultyPrototype = GetStructType<{
472
573
  SID: string;
@@ -1761,6 +1862,8 @@ type IItemPrototype = {
1761
1862
  FittingWeaponsSIDs: string[];
1762
1863
  };
1763
1864
 
1865
+ export type ItemPrototype = GetStructType<IItemPrototype>;
1866
+
1764
1867
  interface IAmmoPrototype extends IItemPrototype {
1765
1868
  Caliber: EAmmoCaliber;
1766
1869
  FractionCount: number;
@@ -2061,9 +2164,9 @@ interface IGrenadePrototype extends IItemPrototype {
2061
2164
  Blueprint: string;
2062
2165
  TimeToExplode: number;
2063
2166
  SafeTimeAfterThrow: number;
2064
- GrenadeExplosionLethalThreshold: "50%";
2065
- GrenadeExplosionHandNonlethal: "90%";
2066
- GrenadeExplosionHandLethal: "100%";
2167
+ GrenadeExplosionLethalThreshold: `${number}%`;
2168
+ GrenadeExplosionHandNonlethal: `${number}%`;
2169
+ GrenadeExplosionHandLethal: `${number}%`;
2067
2170
  BaseComfort: number;
2068
2171
  StaticMeshPrototypeSID: string;
2069
2172
  GrenadeAnimBlueprint: string;
@@ -2192,7 +2295,12 @@ export type SpawnActorPrototype = GetStructType<{
2192
2295
  bForceCodePhysicsDisabled: boolean;
2193
2296
  bWakeUpOnStart: boolean;
2194
2297
  StashPrototypeSID: string;
2195
- ItemGeneratorSettings: string;
2298
+ ItemGeneratorSettings: {
2299
+ PlayerRank: ERank;
2300
+ ItemGenerators: {
2301
+ PrototypeSID: string;
2302
+ }[];
2303
+ }[];
2196
2304
  TileOffsetIndex: number;
2197
2305
  ItemSID: string;
2198
2306
  Durability: number;