jinger Posted January 7, 2006 Share Posted January 7, 2006 There's something wrong on Coruscant, after the ice accademy, you don't get your gear back after the holorecord i'm sure everyone knows about this - does anybody know how to fix it? [size=1]//from a_createpcsaber.nss void sub1(string stringParam1) { object object1 = CreateItemOnObject(stringParam1, GetFirstPC(), 1, 1); object object4 = CreateItemOnObject("a_robe_08", GetFirstPC(), 1, 1); AssignCommand(GetFirstPC(), ActionEquipItem(object1, 4, 0)); AssignCommand(GetFirstPC(), ActionEquipItem(object4, 1, 0)); } //from a_requipplayer.nss void main() { object oBodyItem = GetItemInSlot(1, GetFirstPC()); object oRWeapItem = GetItemInSlot(4, GetFirstPC()); AssignCommand(GetFirstPC(), GiveItem(oBodyItem, GetObjectByTag("HoldStuff", 0))); AssignCommand(GetFirstPC(), GiveItem(oRWeapItem, GetObjectByTag("HoldStuff", 0))); object oInvItem = GetFirstItemInInventory(GetObjectByTag("HoldArmor", 0)); object object14 = GetFirstItemInInventory(GetObjectByTag("HoldLeft", 0)); object object17 = GetFirstItemInInventory(GetObjectByTag("HoldRight", 0)); object object20 = GetFirstItemInInventory(GetObjectByTag("HoldBelt", 0)); object object23 = GetFirstItemInInventory(GetObjectByTag("HoldHead", 0)); GiveItem(oInvItem, GetFirstPC()); GiveItem(object14, GetFirstPC()); GiveItem(object17, GetFirstPC()); GiveItem(object20, GetFirstPC()); GiveItem(object23, GetFirstPC()); DelayCommand(1.0, AssignCommand(GetFirstPC(), ClearAllActions())); DelayCommand(1.0, AssignCommand(GetFirstPC(), ActionEquipItem(object17, 4, 0))); DelayCommand(1.1, AssignCommand(GetFirstPC(), ActionEquipItem(object14, 5, 0))); DelayCommand(1.3, AssignCommand(GetFirstPC(), ActionEquipItem(object20, 10, 0))); DelayCommand(1.4, AssignCommand(GetFirstPC(), ActionEquipItem(object23, 0, 0))); DelayCommand(1.8, AssignCommand(GetFirstPC(), ActionEquipItem(oInvItem, 1, 0))); }[/size] this is where the inventory operations are made, there must be something wrong right here Link to comment Share on other sites More sharing options...
jinger Posted January 7, 2006 Author Share Posted January 7, 2006 I wonder why they bothered with all that, they created containers to hold your current equipment while you're playing the holorecord, why not to use a fake-exile with the jedi robes on and the lightsaber? I'm gonna give it a try if this ain't taken care of yet, please stop me if that's the case Link to comment Share on other sites More sharing options...
Pavlos Posted January 7, 2006 Share Posted January 7, 2006 I never really norticed that, and the way they created containers to hold your gear is ridiculous! Link to comment Share on other sites More sharing options...
stoffe Posted January 7, 2006 Share Posted January 7, 2006 Strange. I've never noticed any problems with that script, or with any lost items after that cutscene. Does this happen even if you don't have any mods in your game? Be warned though that a_createpcsaber isn't a unique script name, it's used in both 950COR (Council Cutscene) and 262TEL (First conversation with Atris). Thus you'll have to merge the scripts if you want it to work in override. This is what I am using (with my custom additions removed for clarity): // a_createpcsaber.nss (950COR_s.rim & 262TEL_s.rim) void EquipAndDressPlayer(string sResref); void main() { int nHilt = 0; int nSaber = 0; string sResref; nHilt = GetGlobalNumber("003EBO_PC_Hilt"); nSaber = GetGlobalNumber("003EBO_PC_Lightsaber"); switch (nSaber) { case 0: switch (nHilt) { case 0: sResref = "g_w_lghtsbr10"; break; case 1: sResref = "g_w_shortsbr10"; break; case 2: sResref = "g_w_dblsbr010"; break; } break; case 1: switch (nHilt) { case 0: sResref = "g_w_lghtsbr02"; break; case 1: sResref = "g_w_shortsbr02"; break; case 2: sResref = "g_w_dblsbr002"; break; } break; case 2: switch (nHilt) { case 0: sResref = "g_w_lghtsbr03"; break; case 1: sResref = "g_w_shortsbr03"; break; case 2: sResref = "g_w_dblsbr003"; break; } break; case 3: switch (nHilt) { case 0: sResref = "g_w_lghtsbr01"; break; case 1: sResref = "g_w_shortsbr01"; break; case 2: sResref = "g_w_dblsbr001"; break; } break; case 4: switch (nHilt) { case 0: sResref = "g_w_lghtsbr04"; break; case 1: sResref = "g_w_shortsbr04"; break; case 2: sResref = "g_w_dblsbr004"; break; } break; case 5: switch (nHilt) { case 0: sResref = "g_w_lghtsbr05"; break; case 1: sResref = "g_w_shortsbr05"; break; case 2: sResref = "g_w_dblsbr005"; break; } break; case 6: switch (nHilt) { case 0: sResref = "g_w_lghtsbr08"; break; case 1: sResref = "g_w_shortsbr08"; break; case 2: sResref = "g_w_dblsbr008"; break; } break; case 7: switch (nHilt) { case 0: sResref = "g_w_lghtsbr09"; break; case 1: sResref = "g_w_shortsbr09"; break; case 2: sResref = "g_w_dblsbr009"; break; } break; case 8: switch (nHilt) { case 0: sResref = "g_w_lghtsbr07"; break; case 1: sResref = "g_w_shortsbr07"; break; case 2: sResref = "g_w_dblsbr007"; break; } break; case 9: switch (nHilt) { case 0: sResref = "g_w_lghtsbr11"; break; case 1: sResref = "g_w_shortsbr11"; break; case 2: sResref = "g_w_dblsbr011"; break; } break; } // -------------------------------------------------- // ST: Added to incorporate the script with the same name that Atris // uses in 262TEL (Telos Academy). if (GetModuleName() == "262TEL") { object oSaber = CreateItemOnObject(sResref, OBJECT_SELF); ActionEquipItem(oSaber, INVENTORY_SLOT_RIGHTWEAPON); ActionPlayAnimation(115, 1.0, 0.0); } // -------------------------------------------------- else { object oArmor = GetItemInSlot(INVENTORY_SLOT_BODY, GetFirstPC()); object oLefthand = GetItemInSlot(INVENTORY_SLOT_LEFTWEAPON, GetFirstPC()); object oRighthand = GetItemInSlot(INVENTORY_SLOT_RIGHTWEAPON, GetFirstPC()); object oBelt = GetItemInSlot(INVENTORY_SLOT_BELT, GetFirstPC()); object oHeadgear = GetItemInSlot(INVENTORY_SLOT_HEAD, GetFirstPC()); AssignCommand(GetFirstPC(), GiveItem(oArmor, GetObjectByTag("HoldArmor"))); AssignCommand(GetFirstPC(), GiveItem(oRighthand, GetObjectByTag("HoldRight"))); AssignCommand(GetFirstPC(), GiveItem(oLefthand, GetObjectByTag("HoldLeft"))); AssignCommand(GetFirstPC(), GiveItem(oBelt, GetObjectByTag("HoldBelt"))); AssignCommand(GetFirstPC(), GiveItem(oHeadgear, GetObjectByTag("HoldHead"))); DelayCommand(1.0, EquipAndDressPlayer(sResref)); DelayCommand(1.5, SetLightsaberPowered(GetFirstPC(), TRUE, FALSE)); } } void EquipAndDressPlayer(string sResref) { object oSaber = CreateItemOnObject(sResref, GetFirstPC(), 1, TRUE); object oRobe = CreateItemOnObject("a_robe_08", GetFirstPC(), 1, TRUE); AssignCommand(GetFirstPC(), ActionEquipItem(oSaber, INVENTORY_SLOT_RIGHTWEAPON)); AssignCommand(GetFirstPC(), ActionEquipItem(oRobe, INVENTORY_SLOT_BODY)); } ...and... // a_requipplayer.nss (950COR_s.rim) void main() { object oPC = GetFirstPC(); // Remove cutscene robe and lightsaber object oRobe = GetItemInSlot(INVENTORY_SLOT_BODY, oPC); object oSaber = GetItemInSlot(INVENTORY_SLOT_RIGHTWEAPON, oPC); AssignCommand(oPC, GiveItem(oRobe, GetObjectByTag("HoldStuff"))); AssignCommand(oPC, GiveItem(oSaber, GetObjectByTag("HoldStuff"))); // Give player back their worn equipment object oBody = GetFirstItemInInventory(GetObjectByTag("HoldArmor")); object oWeapL = GetFirstItemInInventory(GetObjectByTag("HoldLeft")); object oWeapR = GetFirstItemInInventory(GetObjectByTag("HoldRight")); object oBelt = GetFirstItemInInventory(GetObjectByTag("HoldBelt")); object oHead = GetFirstItemInInventory(GetObjectByTag("HoldHead")); GiveItem(oBody, oPC); GiveItem(oWeapL, oPC); GiveItem(oWeapR, oPC); GiveItem(oBelt, oPC); GiveItem(oHead, oPC); // Put things back in their proper item slots. DelayCommand(1.0, AssignCommand(oPC, ClearAllActions())); DelayCommand(1.0, AssignCommand(oPC, ActionEquipItem(oWeapR, INVENTORY_SLOT_RIGHTWEAPON))); DelayCommand(1.1, AssignCommand(oPC, ActionEquipItem(oWeapL, INVENTORY_SLOT_LEFTWEAPON))); DelayCommand(1.3, AssignCommand(oPC, ActionEquipItem(oBelt, INVENTORY_SLOT_BELT))); DelayCommand(1.4, AssignCommand(oPC, ActionEquipItem(oHead, INVENTORY_SLOT_HEAD))); DelayCommand(1.8, AssignCommand(oPC, ActionEquipItem(oBody, INVENTORY_SLOT_BODY))); } Link to comment Share on other sites More sharing options...
jinger Posted January 7, 2006 Author Share Posted January 7, 2006 Be warned though that a_createpcsaber isn't a unique script name, it's used in both 950COR (Council Cutscene) and 262TEL (First conversation with Atris). Thus you'll have to merge the scripts if you want it to work in override. I didn't override that script, it just happens when you get jedi robes from containers before that cutscene, or so it seems. Link to comment Share on other sites More sharing options...
rgdelta Posted January 7, 2006 Share Posted January 7, 2006 never had that issue when I got a jedi robe from peragus (random spawn) so not sure. Link to comment Share on other sites More sharing options...
jinger Posted January 7, 2006 Author Share Posted January 7, 2006 Actually it takes very little to fix this… [size=1] // a_requipplayer.nss void main() { object oPC = GetFirstPC(); DestroyObject(GetItemInSlot(1, oPC)); DestroyObject(GetItemInSlot(4, oPC)); object oBo = GetFirstItemInInventory(GetObjectByTag("HoldArmor", 0)); object oWL = GetFirstItemInInventory(GetObjectByTag("HoldLeft", 0)); object oWR = GetFirstItemInInventory(GetObjectByTag("HoldRight", 0)); object oBe = GetFirstItemInInventory(GetObjectByTag("HoldBelt", 0)); object oHe = GetFirstItemInInventory(GetObjectByTag("HoldHead", 0)); GiveItem(oBo, oPC); GiveItem(oWL, oPC); GiveItem(oWR, oPC); GiveItem(oBe, oPC); GiveItem(oHe, oPC); DelayCommand(1.0, AssignCommand(oPC, ClearAllActions())); DelayCommand(1.0, AssignCommand(oPC, ActionEquipItem(oWR, 4, 0))); DelayCommand(1.1, AssignCommand(oPC, ActionEquipItem(oWL, 5, 0))); DelayCommand(1.3, AssignCommand(oPC, ActionEquipItem(oBe, 10, 0))); DelayCommand(1.4, AssignCommand(oPC, ActionEquipItem(oHe, 0, 0))); DelayCommand(1.8, AssignCommand(oPC, ActionEquipItem(oBo, 1, 0))); }[/size] Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.