LarannKiar Posted May 6, 2021 Share Posted May 6, 2021 (edited) Your script should look like this. (Of course, you can choose another scriptname). Exit the editor window, then click on "Properties". Fill the script properties (Minuteman01, Minuteman02, Minuteman03) with their Ref IDs. You should see their Ref IDs instead of "None" under "Value". If the script property's name and the Editor ID match, you can use Auto Fill. If not, click on Edit Value and then select your reference in the Render Window. Then click OK to save your script. Edited May 6, 2021 by LarannKiar Link to comment Share on other sites More sharing options...
Andrewupkins Posted May 6, 2021 Author Share Posted May 6, 2021 Your script should look like this. (Of course, you can choose another scriptname). Exit the editor window, then click on "Properties". Fill the script properties (Minuteman01, Minuteman02, Minuteman03) with their Ref IDs. You should see their Ref IDs instead of "None" under "Value". If the script property's name and the Editor ID match, you can use Auto Fill. If not, click on Edit Value and then select your reference in the Render Window. Then click OK to save your script.Thanks for the screenshot I must be dumb but even with them I can't get to add anything in the properties window whatever I write in the addproperty or form button i make script error and don't add anything, I also don't have the ObjectReference Const don't know if it's normal Link to comment Share on other sites More sharing options...
LarannKiar Posted May 6, 2021 Share Posted May 6, 2021 Follow these steps: 1. Place your three minutemen in game world in the Render Window. 2. Name their references (Cell Window) to "Minuteman_01_ref", "Minuteman_02_ref", "Minuteman_03_ref". 3. Right click on your DefaultEmptyTrigger, then click on the Scripts tab. Click on Add: add a new script. Name it: "MyMod_Minutemen_Script". 4. Copy paste this to the script: Scriptname MyMod_Minutemen_Script extends ObjectReference Const Actor Property PlayerRef Auto Const Group MinutemenRefs ObjectReference Property Minuteman_01_Ref Auto Const ObjectReference Property Minuteman_02_Ref Auto Const ObjectReference Property Minuteman_03_Ref Auto Const endGroup Event OnTriggerEnter (ObjectReference akActionRef) If akActionRef == PlayerRef (Minuteman_01_Ref as actor).SetProtected(false) (Minuteman_02_Ref as actor).SetProtected(false) (Minuteman_03_Ref as actor).SetProtected(false) Self.Disable() EndIf EndEvent 5. Press Ctrl+S to compile. 6. Open your script's properties and click on Auto Fill, then click OK. Link to comment Share on other sites More sharing options...
Andrewupkins Posted May 7, 2021 Author Share Posted May 7, 2021 Follow these steps: 1. Place your three minutemen in game world in the Render Window. 2. Name their references (Cell Window) to "Minuteman_01_ref", "Minuteman_02_ref", "Minuteman_03_ref". 3. Right click on your DefaultEmptyTrigger, then click on the Scripts tab. Click on Add: add a new script. Name it: "MyMod_Minutemen_Script". 4. Copy paste this to the script: Scriptname MyMod_Minutemen_Script extends ObjectReference Const Actor Property PlayerRef Auto Const Group MinutemenRefs ObjectReference Property Minuteman_01_Ref Auto Const ObjectReference Property Minuteman_02_Ref Auto Const ObjectReference Property Minuteman_03_Ref Auto Const endGroup Event OnTriggerEnter (ObjectReference akActionRef) If akActionRef == PlayerRef (Minuteman_01_Ref as actor).SetProtected(false) (Minuteman_02_Ref as actor).SetProtected(false) (Minuteman_03_Ref as actor).SetProtected(false) Self.Disable() EndIf EndEvent 5. Press Ctrl+S to compile. 6. Open your script's properties and click on Auto Fill, then click OK.I tried that but on the last step when you tell me to autofill after having click on the properties of my script autofill all is in gray can't click on it Link to comment Share on other sites More sharing options...
Recommended Posts