Riddick543 Posted April 19, 2011 Share Posted April 19, 2011 (edited) I am having trouble with the scripting in Heart of the Dead. The end trigger, 0HOD04TriggerFinalEnd, is intended to grant the player AT MOST one companion...Wintermoon, Dublin, or Kat. I played through to get Kat, and am now reconfiguring it so if I reactivate the last trigger, I am granted Wintermoon as well. I got as far as making Wintermoon and Kat appearing at the end of the mod (essential and compainions), but after the final conversation with either one of them, Wintermoon disappears. Wintermoon is not transported to the alternate companion spot, I checked ingame using the TCL console command. Any ideas? In a normal game (with Kat as the resulting companion), the player activates a door and returns to a room. Kat is transformed and talks to you. A message box pops up, and she's your companion. Same for Wintermoon, but not together. Kats companion quest script (Stage 230 of HOD04 quest script) Set HOD04.LastStage to 0StartQuest cmPartnersQuest2Set cmPartnersQuest2.nInParty to 1HODKatFinalRef.RemoveScriptPackageHODKatFinalRef.AddScriptPackage "cmFollowPlayer"HODKatFinalRef.ModFactionRank PartHOD, 10HODKatFinalRef.SetFactionRank NPCParty, 1set HODKatFinalRef.join to 1HODKatFinalRef.moddisposition player 100 HODRavensChestRef.removeallitems HODKatFinalRefHODKatFinalRef.AddItem cmTorch02 1HODKatFinalRef.EquipItem cmTorch02HODKatFinalRef.RemoveItem cmTorch02 1HODKatFinalRef.RemoveScriptPackage "cmInventory"HODKatFinalRef.AddScriptPackage "cmFollowPlayer" ;Player.AddItem cmPartnershipRing2 1 ;Player.AddItem cmPartnerWarpRing2 1player.addSpell HODSummonKatMessagebox "So the Heart has been destroyed. I came out of this a little bit wiser, a little bit braver, but not with the Heart. Oh well. Sometimes treasure is more than ancient trinkets. With Kat and Wintermoon at my side, I'm ready to take on the world." Wintermoons companion quest script (Stage 250 of HOD04 quest script) ;SetStage HODWinterCompanion 10Set HOD04.LastStage to 0StartQuest cmPartnersQuest2Set cmPartnersQuest2.nInParty to 1 HODWinterFinalRef.RemoveScriptPackageHODWinterFinalRef.AddScriptPackage "cmFollowPlayer"HODWinterFinalRef.ModFactionRank PartHOD, 10HODWinterFinalRef.SetFactionRank NPCParty, 1;set HODDublinFinalRef.join to 1HODWinterFinalRef.moddisposition player 100 HODWinterFinalRef.AddItem cmTorch02 1HODWinterFinalRef.EquipItem cmTorch02HODWinterFinalRef.RemoveItem cmTorch02 1HODWinterFinalRef.RemoveScriptPackage "cmInventory"HODWinterFinalRef.AddScriptPackage "cmFollowPlayer" ;Player.AddItem cmPartnershipRing2 1 ;Player.AddItem cmPartnerWarpRing2 1player.addspell HODSummonWinterMessagebox "So the Heart has been destroyed. I came out of this a little bit wiser, a little bit braver, but not with the Heart. Oh well. Sometimes treasure is more than ancient trinkets. But now, with Wintermoon at my side, I'm ready to take on the world." Edited Kat companion quest script (Stage 230 of HOD04 Quest Script) (uses the working trigger of Kat liking me)Set HOD04.LastStage to 0StartQuest cmPartnersQuest2Set cmPartnersQuest2.nInParty to 1HODKatFinalRef.RemoveScriptPackageHODKatFinalRef.AddScriptPackage "cmFollowPlayer"HODKatFinalRef.ModFactionRank PartHOD, 10HODKatFinalRef.SetFactionRank NPCParty, 1set HODKatFinalRef.join to 1HODKatFinalRef.moddisposition player 100HODWinterFinalRef.RemoveScriptPackageHODWinterFinalRef.AddScriptPackage "cmFollowPlayer"HODWinterFinalRef.ModFactionRank PartHOD, 10HODWinterFinalRef.SetFactionRank NPCParty, 1HODWinterFinalRef.moddisposition player 100HODKatFinalRef.RemoveScriptPackage "cmInventory"HODKatFinalRef.AddScriptPackage "cmFollowPlayer"HODWinterFinalRef.RemoveScriptPackage "cmInventory"HODWinterFinalRef.AddScriptPackage "cmFollowPlayer"player.addSpell HODSummonKatplayer.addspell HODSummonWinterMessagebox "So the Heart has been destroyed. I came out of this a little bit wiser, a little bit braver, but without the Heart. Oh well. Sometimes treasure is more than ancient trinkets. With Kat and Wintermoon at my side, I'm ready to take on the world." Final trigger quest scriptOrange=Guessed trouble spot scn 0HOD04TriggerFinalEnd short initshort TempAggressionshort TempAggression2 begin onTrigger player if init == 0 set init to 1 ; Clean up everything player.removespell HODSummonDublin player.removespell HODSummonKat player.removespell HODSummonWinter setessential HODDublinBW 0 setessential HODRavenBW 0 HODKatDeadRef.disable HODDublinDead2Ref.disable HODDublinDead2Ref.kill HODKatDeadRef.kill HOD4WinterRef.disable HOD3Winter3Ref.disable setessential HODWintermoon 0 HOD4WinterRef.kill HOD3Winter3Ref.kill H3RavenRef.disable HODKatLoveRef.disable setessential HODRaven2a 0 H3RavenRef.kill; HODKatLoveRef.kill Dublin1Ref.disable HODDublinLoveRef.disable setessential HODDublin 0 Dublin1Ref.kill HODDublinLoveRef.kill Raven1REFa.disable setessential HODRaven1 0 Raven1REFa.kill HODRootDoor1Ref.disable HODRootDoor2Ref.enable HODDoorToWK2Ref.disable player.removespell HODTranslationSpell player.removespell HODOpenLock HODDublinFinalRef.RemoveScriptPackage HODKatFinalRef.RemoveScriptPackage HODWinterFinalRef.RemoveScriptPackage Set TempAggression to HODDublinFinalRef.getAV Aggression Set TempAggression2 to 5 - TempAggression HODDublinFinalRef.modav Aggression TempAggression2 Set TempAggression to HODKatFinalRef.getAV Aggression Set TempAggression2 to 5 - TempAggression HODKatFinalRef.modav Aggression TempAggression2 Set TempAggression to HODWinterFinalRef.getAV Aggression Set TempAggression2 to 5 - TempAggression HODWinterFinalRef.modav Aggression TempAggression2 Message " " Message " " player.Removeitem HODWKDeadFinalCuirassLt, 1 player.Removeitem HODWKDeadFinalCuirassHV, 1 player.Removeitem HODWKDeadFinalBootsLt, 1 player.Removeitem HODWKDeadFinalBootsHV, 1 player.Removeitem HODWKDeadFinalGlovesLt, 1 player.Removeitem HODWKDeadFinalGlovesHv, 1 player.Removeitem HODWKDeadFinalGreavesLt, 1 player.Removeitem HODWKDeadFinalGreavesHV, 1 player.Removeitem HODWKDeadFinalHelmetLt, 1 player.Removeitem HODWKDeadFinalHelmetHv, 1; HODPlayerChestRef.removeallitems player, 1 ; Get rid of all notes player.removeitem HODHeart1, 1 player.removeitem HODDepthsKey, 1 player.removeitem HOD2ndQuestPoint, 1 player.removeitem HOD2ndQuestPointNon, 1 player.removeitem HODYurnsPas2, 1 player.removeitem HODYurnsPas2Non, 1 player.removeitem HODYurnsPassage1, 2 player.removeitem HODYurnsPassage3, 1 if player.getBaseActorValue HeavyArmor < player.getBaseActorValue LightArmor HODHouseBedChest1Ref.additem HODWKEndCuirassLt, 1 HODHouseBedChest1Ref.additem HODWKEndHelmetLt, 1 HODHouseBedChest1Ref.additem HODWKEndBootsLt, 1 HODHouseBedChest1Ref.additem HODWKEndGlovesLt, 1 HODHouseBedChest1Ref.additem HODWKEndGreavesLt, 1 Else HODHouseBedChest1Ref.additem HODWKEndCuirassHV, 1 HODHouseBedChest1Ref.additem HODWKEndBootsHV, 1 HODHouseBedChest1Ref.additem HODWKEndGlovesHv, 1 HODHouseBedChest1Ref.additem HODWKEndGreavesHV, 1 HODHouseBedChest1Ref.additem HODWKEndHelmetHv, 1 endif message " " message " " Player.additem MiddlePants06, 1 player.equipitem MiddlePants06 if player.getissex female == 1 Player.additem MiddleShirt06, 1 player.equipitem MiddleShirt06 endif HODKatFinalRef.removeallitems HODRavensChestRef HODKatFinalRef.additem LowerPants02, 1 HODKatFinalRef.equipitem LowerPants02 HODKatFinalRef.additem LowerShirt02, 1 HODKatFinalRef.equipitem LowerShirt02 ; HODDublinFinalRef.removeallitems HODDublinsChestRef; HODDublinFinalRef.additem LowerPants04, 1 HODDublinFinalRef.equipitem LowerPants02 HODDublinFinalRef.moveto HODAltCompanionMarker HODKatFinalRef.moveto HODAltCompanion2Marker HODWinterFinalRef.moveto HODAltCompanion2Marker If HODRavenAttitude == 1000 HODDublinFinalRef.moveto HODAltCompanionMarker HODWinterFinalRef.moveto HOD04GoodCompanionMarker HODKatFinalRef.moveto HOD04GoodCompanionMarker HODKatFinalRef.modav fatigue 1000 HODKatFinalRef.pme MYTH HODWinterFinalRef.pme MYTH SetQuestObject cmHODDublin 0 setessential cmHODDublin 0 HODDublinFinalRef.modfactionrank partHOD -10 HODDublinFinalRef.kill elseif HODDublinAttitude == 1000 ; This variable is to set the alternate dialogs for Dublin and Wintermoon. Because of Kat. set cmPartnersQuest2.HODKatDialogSwitch to 1 HODKatFinalRef.moveto HODAltCompanionMarker HODWinterFinalRef.moveto HOD04GoodCompanionMarker HODDublinFinalRef.moveto HOD04GoodCompanionMarker HODDublinFinalRef.modav fatigue 1000 HODDublinFinalRef.pme MYTH SetQuestObject cmHODKat 0 SetQuestObject HODWintermoonFinal 0 setessential cmHODKat 0 HODKatFinalRef.modfactionrank partHOD -10 HODKatFinalRef.kill setessential HODWintermoonFinal 0 HODWinterFinalRef.modfactionrank partHOD -10 HODWinterFinalRef.kill elseif HODWinterAttitude >= 150; This variable is to set the alternate dialogs for Dublin and Wintermoon. Because of Kat. set cmPartnersQuest2.HODKatDialogSwitch to 1 HODDublinFinalRef.moveto HODAltCompanionMarker HODKatFinalRef.moveto HODAltCompanion2Marker HODWinterFinalRef.moveto HOD04GoodCompanionMarker HODWinterFinalRef.pme MYTH SetQuestObject cmHODKat 0 SetQuestObject cmHODDublin 0 setessential cmHODDublin 0 HODDublinFinalRef.modfactionrank partHOD -10 HODDublinFinalRef.kill setessential cmHODKat 0 HODKatFinalRef.modfactionrank partHOD -10 HODKatFinalRef.kill endif If HODRavenAttitude == 1000 || HODDublinAttitude == 1000 || HODWinterAttitude < 150 HODWinterLetterRef.enable endif if HODRavenAttitude < 1000 && HODDublinAttitude < 1000 && HODWinterAttitude < 150; Messagebox "Debug: No one loves you" SetStage HOD04 255; messagebox "So the Heart has been destroyed. I came out of this a little bit wiser, a little bit braver, but not with the treasure. Oh well. Sometimes treasure is more than ancient trinkets. But now I'm ready to take on the world. Let's just hope the world is ready..." endif ; if HODDublinAttitude == 1000; messagebox "Debug: Moving them"; HODKatFinalRef.moveto HODAltCompanion2Marker; HODWinterFinalRef.moveto HODAltCompanion2Marker; elseif HODRavenAttitude == 1000 ; HODDublinFinalRef.moveto HODAltCompanionMarker; HODWinterFinalRef.moveto HODAltCompanion2Marker; elseif HODWinterAttitude >= 150; HODDublinFinalRef.moveto HODAltCompanionMarker; HODKatFinalRef.moveto HODAltCompanion2Marker; else; HODDublinFinalRef.moveto HODAltCompanionMarker; HODKatFinalRef.moveto HODAltCompanion2Marker; HODWinterFinalRef.moveto HODAltCompanion2Marker; endif Set HOD04.LastStage to 10 if HODDublinAttitude == 1000 HODDublinFinalRef.startconversation player GREETING elseif HODRavenAttitude == 1000 HODKatFinalRef.startconversation player GREETING HODWinterFinalRef.startconversation player GREETING endif player.moveto HODEndMarker endif end Edited April 19, 2011 by Riddick543 Link to comment Share on other sites More sharing options...
fg109 Posted April 19, 2011 Share Posted April 19, 2011 I've never tried this mod, so I'm not sure what might be wrong... First thing though, is that you should post all these scripts inside spoiler tags (["spoiler"]["/spoiler"] without the quotation marks). As for the scripts themselves, keeping in mind that I've never played this mod before, I see nothing wrong with them. The problem with getting what you want to happen is probably the result scripts in the dialogues. Check and see the code that's supposed to run after the final conversation in the dialogue topics. Link to comment Share on other sites More sharing options...
LexterU Posted June 23, 2011 Share Posted June 23, 2011 (edited) I wanted to do exactly the same thing, though I'm not a modder and don't know much about scripting. I've just enabled Wintermoon via console and resurrected her.. she was acting like a companion, but was mute and non-essential. So I was thinking about adding another "WintermoonFinal" into testinghall using TES CS and editing her script ... I've seen the script (HODPartner) briefly and think that it checks the "disposition" parameter the same way as the HOD-ending script does.. I thought that deleting this condition would do the trick. But I've had no time to try it or learn how exactly the script works.. As I read your post I do not think that your problem could be caused by the HOD-ending script (in orange).. it enables both Kat and Wintermoon and you said that it works and Wintermoon only disappears after being talked to. Logically the problem should be in the HODPartner script or something else that checks the quest-stage and/or disposition parameters resulting in disabling her. The way would be to change (brute force) the "responsible" parameter or to disable the checking script. But as I said, I'm no expert, so it's just an idea. If you manage to do the trick, it would be nice of you to post the result. :] Good luck. Lex Edited June 23, 2011 by LexterU Link to comment Share on other sites More sharing options...
LexterU Posted June 24, 2011 Share Posted June 24, 2011 I am having trouble with the scripting in Heart of the Dead. The end trigger, 0HOD04TriggerFinalEnd, is intended to grant the player AT MOST one companion...Wintermoon, Dublin, or Kat. I played through to get Kat, and am now reconfiguring it so if I reactivate the last trigger, I am granted Wintermoon as well. I got as far as making Wintermoon and Kat appearing at the end of the mod (essential and compainions), but after the final conversation with either one of them, Wintermoon disappears. Wintermoon is not transported to the alternate companion spot, I checked ingame using the TCL console command. Any ideas? In a normal game (with Kat as the resulting companion), the player activates a door and returns to a room. Kat is transformed and talks to you. A message box pops up, and she's your companion. Same for Wintermoon, but not together. I have finally tried to do this your way and the scripts are okay. It works. Thanks btw. You just forgot to edit also the "cmPartnersQuest2" and "HODKatCompanion" quest scripts. All companions are based on the first one and Kat Companion also on the second one. Both of these scripts contain "safeguards" which will disable the other NPCs because Kat likes you. That's why Wintermoon disappears. So you should just delete/disable these safeguards. Lex Link to comment Share on other sites More sharing options...
Recommended Posts