World Scripts
From PBnWModdingWIKI
This function will research all the standard buildings, and the water miracle, for the player. Have it run at map load. 00din
define script ResearchStandardBuildings begin script ResearchStandardBuildings start set research ABODE_NUMBER_C available to RESEARCH_AVAILABILITY_RESEARCHED set research ABODE_NUMBER_ALTAR available to RESEARCH_AVAILABILITY_RESEARCHED set research ABODE_NUMBER_STORAGE_PIT available to RESEARCH_AVAILABILITY_RESEARCHED set research ABODE_NUMBER_CREATURE_PEN available to RESEARCH_AVAILABILITY_RESEARCHED set research ABODE_NUMBER_FIELD available to RESEARCH_AVAILABILITY_RESEARCHED set research ABODE_NUMBER_WALLTOWER_TECH0 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_MAGIC_TYPE_WATER_RAIN available to RESEARCH_AVAILABILITY_RESEARCHED set research ABODE_NUMBER_MELEE_ARMOURY available to RESEARCH_AVAILABILITY_RESEARCHED set research ABODE_NUMBER_TEMPLE available to RESEARCH_AVAILABILITY_RESEARCHED end script ResearchStandardBuildings
Some Camera work, I set the default camera position somewhere on the water, and use this script to move the camera to the island and zoom in on the playertown. SHADOWCODE
begin script zoomInOnStart oDstCamPos = 0 oDstFocusPos = 0 start begin cinema //Pos: 301, 152, 1083 //Focus: 315, 35, 1159 oDstCamPos=marker at {301, 152, 1083} oDstFocusPos=marker at {315, 35, 1159} //Sets the camera to face move camera focus to {oDstCamPos} time 1 move camera position to {oDstCamPos} time 15 wait 7 seconds move camera focus to {oDstFocusPos} time 8 wait 8 seconds end cinema end script zoomInOnStart
To enable the default stuff: SHADOWCODE
//Enable stuff set interaction SCRIPT_INTERFACE_LEVEL_NORMAL enable game can be lost enable tribute visual enable toolbar
This one creates a volcano at the specified location. 00din
begin script PermaVolcano oVolcano = create volcano at {340.00, 1590.00} player 0 start invoke oVolcano EPIC_START_RISING invoke oVolcano EPIC_START_LAVA invoke oVolcano EPIC_START_ASH invoke oVolcano EPIC_START_SMOKE invoke oVolcano EPIC_START_BUBBLING_LAVA invoke oVolcano EPIC_START_ROCK_SHOWER invoke oVolcano EPIC_SPAWN_ROCKS end script PermaVolcano
This script set does the following:
- Gives the player infinite mana.
- Removes influence boundaries.
- Unlocks all Buildings.
- Unlocks all Miracles.
- Unlocks all Toys
- Unlocks all Creature Roles.
- Unlocks all God Powers.
- Unlocks all Tomes.
- Unlocks all Embellishments.
00din
define script UnlockBuildings define script UnlockMiracles define script UnlockToys define script UnlockCreatureRoles define script UnlockGodPowers define script UnlockTomes define script UnlockEmbellishments define script InfiniteMana define script GlobalInfluence begin script GlobalInfluence start enable global influence end script GlobalInfluence // This has an infinite loop and should be run as a background script. begin script InfiniteMana start begin loop set player 0 mana 50000 end loop end script InfiniteMana begin script UnlockBuildings start set research ARTEFACT_ABODE_NUMBER_A available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_B available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_C available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_D available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_E available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_SKYSCRAPER available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_ALTAR available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_STORAGE_PIT available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_CRECHE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_SHRINE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_TEMPLE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_PUB available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_CREATURE_PEN available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_FIELD available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_MELEE_ARMOURY available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_RANGED_ARMOURY available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_WORKSHOP available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_STUDY available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_UNIVERSITY available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_PRISON available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_SMELTER available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_GRANARY available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_LUMBERMILL available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_MARKET_POT available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_MARKET_STATUE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_MARKET_PLANT available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_AMPITHEATRE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_GRAVEYARD available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_OLD_PERSONS_HOME available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_BATHHOUSE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_WALLTOWER_TECH0 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_ABODE_NUMBER_WALLTOWER_TECH1 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EPIC_WONDER_NUMBER_HURRICANE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EPIC_WONDER_NUMBER_EARTHQUAKE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EPIC_WONDER_NUMBER_VOLCANO available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EPIC_WONDER_NUMBER_SIREN available to RESEARCH_AVAILABILITY_RESEARCHED end script UnlockBuildings begin script UnlockMiracles start set research ARTEFACT_MAGIC_TYPE_LIFE_HEAL available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_MAGIC_TYPE_FIRE_FIRE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_MAGIC_TYPE_EARTH_METEOR available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_MAGIC_TYPE_WATER_RAIN available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_MAGIC_TYPE_WATER_STORM available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_MAGIC_TYPE_AIR_TEMPEST available to RESEARCH_AVAILABILITY_RESEARCHED // Creature miracles. set research ARTEFACT_CREATURE_MAGIC_TYPE_HEAL available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_MAGIC_TYPE_WATER available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_MAGIC_TYPE_FIREBALL available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_MAGIC_TYPE_LIGHTNING available to RESEARCH_AVAILABILITY_RESEARCHED end script UnlockMiracles begin script UnlockToys start set research ARTEFACT_CREATURE_TOY_GOOD available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_TOY_NEUTRAL available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_TOY_EVIL available to RESEARCH_AVAILABILITY_RESEARCHED end script UnlockToys begin script UnlockCreatureRoles start set research ARTEFACT_CREATURE_ROLE_BUILDER_1 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_BUILDER_2 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_BUILDER_3 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_BUILDER_4 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_GATHERER_1 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_GATHERER_2 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_GATHERER_3 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_GATHERER_4 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_SOLDIER_1 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_SOLDIER_2 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_SOLDIER_3 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_SOLDIER_4 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_ENTERTAINER_1 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_ENTERTAINER_2 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_ENTERTAINER_3 available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_CREATURE_ROLE_ENTERTAINER_4 available to RESEARCH_AVAILABILITY_RESEARCHED end script UnlockCreatureRoles begin script UnlockGodPowers start set research ARTEFACT_HAND_MULTIPICKUP available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_HAND_FISTING available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_HAND_GESTURES available to RESEARCH_AVAILABILITY_RESEARCHED end script UnlockGodPowers begin script UnlockTomes start set research ARTEFACT_TOME_AGE_OF_GODS available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_BARREN_SEAS available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_FATE_OF_THE_EGYPTIANS available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_FRAGMENT available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_GODLESS_MIRACLES available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_IMMORTAL available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_MISSIONARIES available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_ORIGIN_OF_CREATURES available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_PARCHMENT available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_POWER_OF_THE_AZTECS available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_GREEKS available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_JAPANESE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_NORSE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_TOME_PROPHECY available to RESEARCH_AVAILABILITY_RESEARCHED end script UnlockTomes begin script UnlockEmbellishments start set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_FERTILITY_STATUE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_FOUNTAIN available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_STREETLAMP available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_TORTURE_PIT available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_COLUMN available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_GARDEN available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_WELL available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_SPIKE available to RESEARCH_AVAILABILITY_RESEARCHED set research ARTEFACT_EMBELLISHMENT_INFO_GREEK_MIRACLE_ENHANCER available to RESEARCH_AVAILABILITY_RESEARCHED end script UnlockEmbellishments
This one gives the specified town infinite resources. 00din
// Run this as a background script. begin script InfiniteResources(nTown) oTown = get town with id nTown oStore = get building ABODE_NUMBER_STORAGE_PIT in oTown min built 1.0 start begin loop set oStore resource RESOURCE_TYPE_FOOD to 19000 set oStore resource RESOURCE_TYPE_WOOD to 19000 set oStore resource RESOURCE_TYPE_ORE to 19000 end loop end script InfiniteResources