Jump to content

[LE] Simple outfit replacer script


Recommended Posts

Hello everyone!

 

I know there is plenty of this subject on the forum, but even after many investigations, I'm stuck with a simple script. I would like to create a script modifying outfit for the actor base, instead of modifying a ref in a cell; which is better for NPC such as Aela, Skjor and so on. Here is what I've written so far:

Scriptname OutfitReplacer extends Quest  

ActorBase Property SkyrimNPC  Auto
Outfit Property NewOutfit  Auto

Function SetOutfit(Outfit NewOutfit, bool abSleepOutfit = false) native
    SkyrimNPC.SetOutfit(NewOutfit)
EndFunction

But when I try to compile I get this error:

C:\Program Files (x86)\Steam\steamapps\common\skyrim\Data\Scripts\Source\temp\OutfitReplacer.psc(7,10): no viable alternative at input '.'

I don't understand what is wrong in my syntax. I'm used to create functions and macros in Excel but I'm lost with Papyrus script

 

Subsidary question: do I have to create a quest for each NPC I wanna change the outfit or can I put multiple times the same script (with different actor bases) in a single quest?

Link to comment
Share on other sites

So, the problem seemed to come from the flag "native". Once removed the script was able to compile. But my quest doesn't seem to start

 

I've ticked "Stard Game Enabled" and "Run Once". I even generated a .seq fil with CK and with TES5Edit but I got nothing. Anyone has an idea?

Link to comment
Share on other sites

  • Recently Browsing   0 members

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