Tgx42 Posted October 11, 2017 Share Posted October 11, 2017 Hi, I'm starting now in the mod-building world and wanted help in a one-button script. This topic is being translated by google translate because I am Brazilian and I do not speak English. The idea was for the person to push the button and all his iventario weapons would be reloaded as if he had used soul stones, only without them. I found this script in the site of the creation kit but at the time of saving of this error: Starting 1 compile threads for 1 files...Compiling "FullchargeWeapon"...D:\..................\Data\Scripts\Source\temp\FullchargeWeapon.psc(1,28): required (...)+ loop did not match anything at input 'Function'No output generated for FullchargeWeapon, compilation failed. Batch compile of 1 files finished. 0 succeeded, 1 failed.Failed on FullchargeWeapon The script is this: Scriptname FullchargeWeapon Function GetItemMaxCharge() native ObjectReference Property weaponRef AutoString nameFloat maxcharge Function weaponmaxcharge()maxcharge = weaponRef.GetItemMaxCharge()name = weaponRef.GetBaseObject().GetName()Debug.Trace(name + "'s maximum charge is " + maxcharge)EndFunction Link to comment Share on other sites More sharing options...
Kapteyn Posted October 11, 2017 Share Posted October 11, 2017 Use the code tags to enclose your script, like this... Scriptname FullchargeWeapon Extends ObjectReference ObjectReference Property weaponRef Auto Function weaponmaxcharge() Float maxcharge = weaponRef.GetItemMaxCharge() String name = weaponRef.GetBaseObject().GetName() Debug.Trace(name + "'s maximum charge is " + maxcharge) EndFunction So yeah, you messed up the first line. :wink: Link to comment Share on other sites More sharing options...
Recommended Posts