Jump to content

Script / Item question


Chemist18

Recommended Posts

I wanted to see how the Cave Fungus worked so I started exploring in the GECK.

 

I found:

 

CaveFungus, with a form type of ALCH, this establishes it as a consumable...

CaveFungusPlant, with for type of ACTI (activator), which triggers a script, oddly enough called "CaveFungusScript"

 

 

BEGIN OnActivate

I can see in that script where the "state" of the activator is set to "SetDestroyed 1" when the player picks it and the animation of the item is moved back.

 

BEGIN OnLoad

essentially toggles the animation based on the state of the activator

 

 

BEGIN onReset

If SetDestroyed==1 then

Play the animation forward

set the state to 0 (it grew back)

SetDestroyed 0 (it grew back)

 

 

There's no description in the GECK wiki about the OnReset blocktype. It's clear that the OnReset block causes the cave fungus to respawn. But how/where is the OnReset triggered?

 

Link to comment
Share on other sites

OnReset is run when a cell where the object is placed is reset. If a cell is in an encounter zone with the "Never Resets" box checked, the script will never run on objects in that cell. Otherwise it will run at the frequency specified in the game setting IHoursToRespawnCell.

Link to comment
Share on other sites

OnReset is run when a cell where the object is placed is reset. If a cell is in an encounter zone with the "Never Resets" box checked, the script will never run on objects in that cell. Otherwise it will run at the frequency specified in the game setting IHoursToRespawnCell.

THANKS :)

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...