Mindtwistah Posted June 10, 2007 Share Posted June 10, 2007 What is the script to get credits? I was thinking this: Giveitem ("credits", "2000") But I don't think that would work. Link to comment Share on other sites More sharing options...
Gargoyle King Posted June 10, 2007 Share Posted June 10, 2007 What is the script to get credits? I was thinking this: Giveitem ("credits", "2000") But I don't think that would work. I'm quite a noob when it comes to modding, but i believe it is this: To get credits: GiveGoldToCreature( GetFirstPC(),nAmount); To take credits away: TakeGoldFromCreature( GetFirstPC(),nAmount); - i think after the n, instead of "Amount" you put in the value for the credits. Hope this helps! (if it's correct ) Link to comment Share on other sites More sharing options...
Master Zionosis Posted June 10, 2007 Share Posted June 10, 2007 A script like this would work, obviously "gold" is credits, lol: void main() { int nGoldPieces = (500); object oNPC=GetObjectByTag("your_npc_tag"); GiveGoldToCreature(oNPC, nGoldPieces); } Replace 500 with the number of credits you want to be given to you, and replace "your_npc_tag" with the tag of the NPC thats giving you the credits. Link to comment Share on other sites More sharing options...
Mindtwistah Posted June 10, 2007 Author Share Posted June 10, 2007 If I put it in a dialog file where for example Bastila is giving me credits, do I have to put in this? object oNPC=GetObjectByTag("your_npc_tag"); Link to comment Share on other sites More sharing options...
stoffe Posted June 10, 2007 Share Posted June 10, 2007 If I put it in a dialog file where for example Bastila is giving me credits, do I have to put in this? object oNPC=GetObjectByTag("your_npc_tag"); No, if you give the credits to GetFirstPC() they will be added to the player/party credit account. This should be enough: void main() { GiveGoldToCreature(GetFirstPC(), [color=Yellow]1000[/color]); } ...where you replace 1000 with how many credits you want to give. Link to comment Share on other sites More sharing options...
Mindtwistah Posted June 10, 2007 Author Share Posted June 10, 2007 Thanks to all of you for your help. I will probably use Stoffes scripts since it is the smallest one. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.