Jump to content

Scripting question and wondering about art assets


lithic01

Recommended Posts

I'm trying to run a script that kills any actor who walks into the trigger area. I set up a collision box and created a script attached to it. The script I have written is:

 

Scriptname KillonEnterScript extends ObjectReference

{Kills Actor when it enters the trigger.}

 

Event OnTriggerEnter(ObjectReference akActionRef)

 

If (akActionRef as Actor)

(akActionRef as Actor).Kill()

EndIf

EndEvent

 

This does not seem to work when I fall into the collision box, am I missing something? It compiles fine.

 

Furthermore, in the caves I am building, I want there to be a pit where, when the player looks down into it, all he/she sees is complete pitch black, hinting that the pit is incredibly deep. However, I can't seem to find any art assets that are just a layer/box of darkness. (My intent with both of these is to put the collision box where the darkness is, so that if the player falls down into the pit he/she is instantly killed.

 

Thanks in advance for any help.

Edited by lithic01
Link to comment
Share on other sites

  • Recently Browsing   0 members

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