Jump to content

DOWNLOAD MODS

Are you looking for something shiny for your load order? We have many exclusive mods and resources you won't find anywhere else. Start your search now...

LEARN MODDING

Ready to try your hand at making your own mod creations? Visit the Enclave, the original ES/FO modding school, and learn the tricks of the trade from veteran modders...

JOIN THE ALLIANCE

Membership is free and registering unlocks image galleries, project hosting, live chat, unlimited downloads, & more...

RenKaos

Allies
  • Posts

    3
  • Joined

  • Last visited

RenKaos's Achievements

Layman

Layman (1/11)

0

Reputation

  1. Hey this is my first attempt at a script. I know that a lot of it is probably wrong but I would like for someone to fix it and then tell me what I did wrong. I've read several tutorials and understand loosely how scrips work but I only can guess how to write them. I have 26 buttons and 4 doors, I want the doors to be open by certain labeled buttons, essentially by the player typing "open." So the "O" button needs a script that says "Check all doors, if they are all closed open Door01 else close all doors." "P" would need to read "Check all doors if Door01 is open and the rest are closed open Door02 else close all doors." etc. Will I be able to do each door in one script or will I need a script for each door? I'm sure that what I have is pretty bad but thanks a lot for helping. Scriptname OpenPuzzle01 extends ObjectReference {A script to check if four doors are closed and then open one} ObjectReference property Door01 auto {First door to be opened} ObjectReference property Door02 auto {Second door to be opened} ObjectReference property Door03 auto {Third door to be opened} ObjectReference property Door04 auto {Fourth door to be opened} Function SetDefaultState() if (Door01.GetOpenState() != 0) (Door01.GetOpenState(false) if (Door02.GetOpenState() != 0) (Door02.GetOpenState(false) if (Door03.GetOpenState() != 0) (Door03.GetOpenState(false) if (Door04.GetOpenState() != 0) (Door04.GetOpenstate(false) EndFuntion Function DisableDoors() Door01.BlockActivation() Door02.BlockActivation() Door03.BlockActivation() Door04.BlockActivation() EndFunction Function CloseDoors() if (Door01.GetOpenState() != 3) Door01.SetOpen(false) endif if (Door02.GetOpenState() != 3) Door02.SetOpen(false) endif if (Door03.GetOpenState() != 3) Door03.SetOpen(false) endif if (Door04.GetOpenState() != 3) Door04.SetOpen(false) endif EndFunction Function OpenDoor() if (Door01.GetOpenState() != 3) if (Door02.GetOpenState() != 3) if (Door03.GetOpenState() != 3) if (Door04.GetOpenState() != 3) Door01.SetOpen() endif EndFunction Event OnReset() SetDefaultState() DisableDoors() EndEvent Event OnLoad() SetDefaultState() DisableDoors() EndEvent Auto State Inactive Event OnActivate(ObjectReference akActivateRef) GoToState("Active") OpenDoor() elseif (CloseDoors()) endif Utility.Wait(1) GoToState("Inactive") EndEvent EndState
  2. Thanks but like I said I'm new to this I just went over several scripting tutorials so I understand what you are saying but I don't quite grasp how to do it. I'm using the dunArcherPressurePlate activator and I looked at the properties in it's script but I don't know which one to use or if I'll need to create my own new script. Also I'm not certain on how to "disable()" the collision marker unless I do need to write my own script. Thanks again.
  3. I'm brand new to modding and wouldn't you know it I've already run into a problem that I can't find the answer to with Google. I was wondering how to turn off a collision marker by using an activator? I'm making a puzzle dungeon and I'm using the Marker as a force field between puzzle rooms but I can't seem to figure this out. Thanks a lot for the help.
×
×
  • Create New...