OvertWizzard Posted June 24, 2015 Share Posted June 24, 2015 Hi All, I am relatively new to scripting for Oblivion, i am more akin to imperative languages such as c/c++/java etc. Anyway thats not the point of the post. In the script i am currently attempting to write i want to be able to change an NPCs disposition based on some + or - key press. I have no issue identifying that i am looking at an NPC i just cant perform functions on the npc such as getdisposition. Here is an example of what i am talking about: float Fquestdelaytimeref targetint typeint actorValue begin GameMode set Fquestdelaytime to 0.01 if(onkeydown 47) set target to GetCrosshairRef set type to target.GetObjectType target.GetDisposition <-- throws the error "missing parameter Actor"if(type == 35) messagebox"NPC"endifendif end Some help would be appreciated as i am sure this is a simple fix but as i am new to this i do not yet know what it is. Best,Overt Link to comment Share on other sites More sharing options...
DrakeTheDragon Posted June 24, 2015 Share Posted June 24, 2015 Hid your redundant duplicate topic. Hmm, I'm not sure, but this one looks like a rather simple problem for a change. There is no such thing as a global disposition of an actor. Disposition always requires a target towards which it's aimed, such as the NPC's disposition towards the player, which is what I think you're asking for in this case here.So the correct usage requires you to make it "target.GetDisposition player", for it to ever have any chance to work. Here's the relevant function reference: http://cs.elderscrolls.com/index.php?title=GetDisposition Link to comment Share on other sites More sharing options...
OvertWizzard Posted June 24, 2015 Author Share Posted June 24, 2015 (edited) Hi Drake, Thanks for the reply. Ive edited this post as i had my very favourite special hat on and wasn't saving the scripts before running the game <-- used to ides that compile everything not just tiny bits of code. that worked thankyou very much for your time :smile: Edited June 24, 2015 by OvertWizzard Link to comment Share on other sites More sharing options...
Recommended Posts