2DA Override

Hello again all,

I’m doing some experimenting to see what’s possible for a request from a PW owner. The overall desire is to be able to control the PC’s speed. I understand that the PC’s standard speed is referenced in the creaturespeed.2da file, which is referenced in the MOVERATE column in appearance.2da.

So, my question is can I create a custom appearance in appearance.2da that references a new row in creaturespeed.2da, which in turn modifies the PC’s movement speed?

I’ve tried to create a new row in appearance.2da by copying the human row (id 6) to the bottom of the file, modifying the ID to the next number, adding a new row to creaturespeed.2da and referencing the new row via the MOVERATE column in appearance.2da. With this done, I entered my test module and changed the appearance via the SetCreatureAppearance() function to the new row id. When this function fired, the PC disappeared completely and I was no longer able to control the game’s camera, although I could still control the invisible PC.

Any idea if what I’m trying to do is possible? If so, can you point me at a detailed tutorial for 2da editing as I wasn’t able to find one that explained what I might be doing wrong. Also, any idea why the PC disappeared when I attempted to change the appearance? When I removed the new custom row completely and attempted to change the appearance to an ID that didn’t exist in appearance.2da, I got the same result, so is it possible that the rows I’m attempting to add into the 2da somehow aren’t being accepted even though they’re visible?


As a further experiment, I copied the original appearance.2da into the override folder, changed the human (id 6) line to a DFAST movement rate and saved the file. Upon entering the module, there was no change to the PC’s rate of movement. This make me suspicious that I’m somehow not committing the changes in the file to the system somehow or that the system isn’t using the appearance.2da file that’s in the override folder.

I’m pretty sure the player usually walks/runs with PLAYER speed (1st row in creaturespeed.2da). So to change the player’s speed you would have to edit that file.

However changing appearance seems to affect your speed (my char changed to a bat was definitely faster than my char changed into a table).

You may want to take a look at appearances 482-495. These appearances are used for riding and they use moverate FAST. Perhaps you can start from there.

For a working example, see my Witch’s Broomstick:


What you’re trying to do is definitely possible. In my Dark Energy module, I have a new row in creaturespeed.2da which is referenced by appearance.2da. In that module, this is only used for NPCs.

As far as I can remember, it works for PCs, too, as long as you set the correct appearance. I haven’t had time to review the above example in detail, but it definitely does what you want.

As it happens, the broomstick uses a mounted appearance, which requires a phenotype change, too, but it should work for the regular PC phenotype as well.


Thanks again. I won’t have time to look at this for another 6 hours or so, but I imagine it works great. I’ll let you know if there are any issues or if I’m too dense to figure it out from your work.

Thanks again!

Thanks I’ll definitely look at those when I get a chance in a few hours and report back.

That happens when you pass an invalid appearance ID (row number - the first “column”) to SetCreatureAppearanceType. In vanilla 1.69 the first new row in appearance.2da (the one you add) has number 871.

Ok, thanks, I’ll fix that soon and report back.

The rows in my appearance.2da go all the way to 870. Do I just add at 871? That’s what I tried previously to no avail. Haven’t looked at your examples yes, I’ll get into that in the near future.

Sorry, my mistake. Yes, add row 871. You can use TlkEdit2 (in NWN1 mode) to edit the tables too (it has copy & paste capabilities).

Hey, we’re finally getting somewhere. For some reason, it won’t work when I add it as row 871. But it worked fine (sort of) when I added into the first available unused (user) row in the file (307). Not sure why. Also, the speed adjustments/restrictions worked. However, when I did a test that used a slower speed, the PC still used the run animation, even though he was moving extremely slow. I understand this was a side effect form a previous post I read (can’t find the post now). Are there any options on how to set which animation to use for a specific appearance and/or creature speed?

What slower speed? 5, 10, 1? I’ve set runspeed to 1 and the PC “walked”. Looked alright. As you can see, movement speed is tightly coupled with the running animation. Faster movement = faster animation and vice versa.

You could try to modify the mdl files to replace running animation for a custom phenotype with walking animation. It might work, it might not, but you are better off simply using ItemPropertySpecialWalk. It forces the target to walk. In vanilla NWN it is a silly zombie shuffle, but LRA changes that to normal walk (actual zombies are unaffected).

As an experiment, I set the run speed to 2 (normal PC walk speed), and the PC traveled at that speed, but using the run animation, kind of a running man dance, slowly moving forward. When I used shift-click to set the target location, the PC walked at 2 m/s with the walk animation. When I clicked to set the target location (default = run), the PC ran to the target location, but at 2 m/s. There might be a value I’m missing or messed up in the 2da editing. I’ll do some experimentation there.

Not sure if I’ll be able to sell the LRA to the module owners. I’ll give it a shot.

2 seems to still trigger the running animation, 1 does not. Special walk is probably the easiest way to restrict running anyway.

It is of course possible to use vanilla models with no zombie walk - all you have to do is copy&paste walk animation over walkdead animation in a_ba.mdl and a_fa.mdl. In theory, because there are issues in practice. Which is why LRA exists.

Ok, thanks, I’ll take a closer look at the numbers and see what I can come up with. Thanks for all the help with this.