Aller au contenu

Photo

Tracking player kills


  • Veuillez vous connecter pour répondre
5 réponses à ce sujet

#1
Shaun the Crazy One

Shaun the Crazy One
  • Members
  • 183 messages
I'm trying to come up with a way to keep a running total of how many creatures the player has killed.  Does anyone know a good way to do this?  The obvious solution whould be to make a modified version of the default OnDeath script that updates a local variable on the PC.  But that whould require creating modifed blueprints of all the default creaturs I've used, and updating all the placed encounter and creatures through out the module, which since I'm almost done whould be a hell of a lot of work.  Does anyone know of any alternatives?

#2
Lugaid of the Red Stripes

Lugaid of the Red Stripes
  • Members
  • 955 messages
You can edit the default on-death script directly, which will create a module-specific script that will override the OEI originals.

#3
Shaun the Crazy One

Shaun the Crazy One
  • Members
  • 183 messages
Thanks Lugaid I had no idea you could do that. Do I just modify the script or should I create a duplicate with the same name?

#4
M. Rieder

M. Rieder
  • Members
  • 2 530 messages
I think you have to create a duplicate because IIRC the toolset won't let you modify the original.

#5
Jezla

Jezla
  • Members
  • 173 messages
If you modify it, when you select save and compile, it will automatically create a copy within the module (it even warns you).

#6
The Fred

The Fred
  • Members
  • 2 516 messages
Yep, it's easiest to modify the existing one since then you've got all the code right there. The thing is that whilst the actual original is not being modified, the module will use whichever version it has (priority is campaign/override, module, default). All that's happening is that those creatures are calling the script with that name.

Just a note: Beware of doing this. Remember that any changes you make to such scripts will occur *every* time that script gets called. Obviously here that's what you want - just keep it in mind.