Ferc Kast Posted March 14, 2008 Share Posted March 14, 2008 I was working on my recruit mod when the script to recruit my NPC didn't work; Can anyone tell me what I did wrong? (It did compile perfectly, it just didn't work in-game.) void main() { RemoveAvailableNPC(NPC_G0T0); AddAvailableNPCByTemplate(NPC_G0T0, "p_kast"); DelayCommand(1.5,ShowPartySelectionGUI()); } Link to comment Share on other sites More sharing options...
Miles Edgeworth Posted March 14, 2008 Share Posted March 14, 2008 The second time it says, "NPC_G0T0" it should have a number; G0-T0's number is 3. Link to comment Share on other sites More sharing options...
DarthJebus05 Posted March 14, 2008 Share Posted March 14, 2008 You did attach it to a dialog, right? Link to comment Share on other sites More sharing options...
Ferc Kast Posted March 15, 2008 Author Share Posted March 15, 2008 @Miles Edgeworth: I'll try it and see if that works. @DarthJebus05: Yes; That's how I knew that the script wasn't working. EDIT: I still can't get it to work. Link to comment Share on other sites More sharing options...
stoffe Posted March 15, 2008 Share Posted March 15, 2008 I was working on my recruit mod when the script to recruit my NPC didn't work; Can anyone tell me what I did wrong? (It did compile perfectly, it just didn't work in-game.) In what way doesn't it work? Does it not do anything at all, or does the party member selection screen show but your new party member isn't available to choose on it? The second time it says, "NPC_G0T0" it should have a number; G0-T0's number is 3. NPC_G0T0 is an integer constant, it will be replaced with the value 3 automatically when the script is compiled. Thus it is correctly used in the script. Link to comment Share on other sites More sharing options...
Ferc Kast Posted March 15, 2008 Author Share Posted March 15, 2008 In what way doesn't it work? Does it not do anything at all, or does the party member selection screen show but your new party member isn't available to choose on it? The party member selection screens shows, but my new party member isn't available to choose. Link to comment Share on other sites More sharing options...
Marius Fett Posted March 15, 2008 Share Posted March 15, 2008 Does it just appear and have a block of solid colour where the portrait should be and your mouse icon is invisible? This happened to me a while back, it was fixed after I made a portrait. Link to comment Share on other sites More sharing options...
Ferc Kast Posted March 15, 2008 Author Share Posted March 15, 2008 My original portraits are in-game (though not my most updated)...I'll check to see if I pointed my NPC to the right portrait line. EDIT: Nope, I didn't even point my NPC to a portrait line...let alone the correct one. Just for kicks: At the end of the script, I'm gonna add a ExecuteScript function to use a debug script that I found searching around the forum. That way, I can be sure that the script fired. Hopefully, one of these two things should help correct it. EDIT II: It didn't even fire the script for some reason. Link to comment Share on other sites More sharing options...
stoffe Posted March 15, 2008 Share Posted March 15, 2008 The party member selection screens shows, but my new party member isn't available to choose. Is the p_kast.utc file located in the module where the script is run, or in the game's override folder? Also try to spawn an NPC from this template to see that it isn't corrupted or something. I can't see anything directly wrong with that script, so the problem likely lies elsewhere. Link to comment Share on other sites More sharing options...
Ferc Kast Posted March 15, 2008 Author Share Posted March 15, 2008 The spawn script seemed to spawn my NPC correctly. Could it be that I originally added the NPC into the module via the GIT file? (Which too required the Tag and TemplateResRef field.) I think that may be what the problem is. EDIT: The recruit script works perfectly now; Though, I can't tell what the difference is from before...Now, I just have to eliminate the twin. EDIT II: I combined both scripts and it worked perfectly. So, that is all solved. To rejoice in said solution, here is my pic from the party selection screen (with the outdated portrait): EDIT III: I realized that the reason it didn't work before was that I didn't set the tag of my recruitable NPC to the NPC tag that I was going to replace. Link to comment Share on other sites More sharing options...
Ferc Kast Posted March 15, 2008 Author Share Posted March 15, 2008 I now need a script to check if G0-T0 is in the party. (Apparently, the game thought I had G0-T0 after I was done with the Red Eclipse fight; Therefore, it didn't let me continue the main quest.) EDIT: Never mind; I searched the forum and found exactly what I needed. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.