Jump to content

Scripting help?


AceDillinger

Recommended Posts

I'm working on a mod that adds a couple of quests, and I've run into some trouble getting a script command to work. I'm an amateur at this, and I've been referring to the existing scripts to teach myself all the commands.

 

Basically, I need to make it so that, after speaking with a character, an NPC (who is at first not in the game world) moves to a certain location.

 

I put a marker at the spot where I need him to appear. Talking to the previously mentioned character moves the Quest Stage up, so in the Result Script for that stage I need to put the command to place the character at the marker. Looking at other scripts for similar situations, they all have it listed as:

 

[ActorID]Ref.moveto [marker]

 

I tried this for the character and it didn't work. I've also tried using the BaseID and RefID instead. What exactly is the command I need?

Link to comment
Share on other sites

I'm no scripter but I found this tidbit in the CS Wiki Common Bugs - Moveto Oddities:

MoveTo for Actors may require pathrid

In some situations, using MoveTo on an Actor may appear to not work right unless the destination has a valid pathgrid to guide them. The symptom of this problem is that the MoveTo appears to work normally, but the Actor remains at the target only for a few seconds, then is moved to a nearby pathgrid in the same cell. The solution is to make sure the target area for a MoveTo on an Actor has a valid pathgrid, using World...Edit Cell Grid Path in the Construction Set. This isn't really a problem with MoveTo, but it can seem to be such until you realize the underlying cause.

Link to comment
Share on other sites

When you put the actor into the game via the render window, did you name the reference [actorid]ref?

 

I didn't put him into the game at all. He's a hostile character, so I wanted him to be unreachable until the time actually comes to kill him, so that the player can't accidentally kill him and upset the stage order. I did pull up some characters in the render window and now I see that they are tagged as [name]Ref, so that explains that, but I still don't know how to move my character without placing him in the render window.

Link to comment
Share on other sites

  • Recently Browsing   0 members

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