Talk:Useful Scripts
Revision as of 16:04, 24 February 2009 by imported>Cipscis (→FOSE Scripts)
FOSE Scripts
Should we include FOSE scripts? --Illyism 14:23, 24 February 2009 (UTC)
- So long as it's made clear that the script requires FOSE, I don't see any problem with using them here. Looking at the script below, I think that changing the GMSTs while in MenuMode 1057 could potentially cause problems. Specifically, if a scripted terminal is placed near enough to a regular terminal that its script will be running while the regular terminal is Activated, the GMSTs will still be changed.
Perhaps a triggerbox could be used instead, so that the GMSTs are changed to and from their default values in OnTriggerEnter and OnTriggerLeave blocks.
Once FOSE makes string variables available, this script should be updated to store the original values and restore them, otherwise it will overwrite any other changes that have been made to the relevant GMSTs.
-- Cipscis 21:04, 24 February 2009 (UTC)
Example
Script requires FOSE.
To be placed on a terminal, it changes the usual "Robco" headers to your liking.
ScriptName TerminalChange Short toggle Float minitimer Begin OnActivate Activate ;For people without FOSE. con_setgamesetting sComputersHeader1 "GREAT ACADEMY OF VALHALLA" con_setgamesetting sComputersHeader2 "Republic of Valhalla" con_setgamesetting sHackingHeader "VALHALLA REPUBLIC TERMLINK PROTOCOL" con_setgamesetting shackingintro01 "WELCOME TO VALHALLA REPUBLIC TERMLINK" con_setgamesetting shackingintro06 "Initializing Valhalla Republic MF Boot Agent v2.1.9" con_setgamesetting shackingintro09 "Copyright 2156-2234 Academy of Valhalla" end begin gamemode ;On shutting down the terminal. Makes sure it doesn't show up on others. con_setgamesetting sComputersHeader1 "ROBCO INDUSTRIES UNIFIED OPERATING SYSTEM" con_setgamesetting sComputersHeader2 "COPYRIGHT 2075-2077 ROBCO INDUSTRIES " con_setgamesetting sHackingHeader "ROBCO INDUSTRIES (TM) TERMLINK PROTOCOL" con_setgamesetting shackingintro01 "WELCOME TO ROBCO INDUSTRIES (TM) TERMLINK" con_setgamesetting shackingintro06 "Initializing Robco Industries(TM) MF Boot Agent v2.3.0" con_setgamesetting shackingintro09 "Copyright 2201-2203 Robco Ind." end ;Double-check begin menumode 1057 ;1057 = Terminal Con_SetGameSetting sComputersHeader1 "GREAT ACADEMY OF VALHALLA OPERATING SYSTEM" con_SetGameSetting sComputersHeader2 "Republic of Valhalla" con_SetGameSetting sHackingHeader "VALHALLA REPUBLIC TERMLINK PROTOCOL" con_SetGameSetting sHackingIntro01 "WELCOME TO VALHALLA REPUBLIC TERMLINK" con_SetGameSetting sHackingIntro06 "Initializing Valhalla Republic MF Boot Agent v2.1.9" Con_SetGameSetting SHackingIntro09 "Copyright 2156-2234 Academy of Valhalla" end