Jump to content

getisrace not working for custom races?


nautilusfossil

Recommended Posts

I was trying to make a quest that initiates only when the player character is Ainmhi (the one with cat ears and a tail by Nequam). The quest script (start game enabled) was like:

 

 

scn AinmhiQuestScript

 

begin gamemode

 

if (player.getisrace Ainmhi == 1)

setstage AinmhiQuest 10

endif

end

 

It didn't work when I loaded my ainmhi save, but it did when I changed 'Ainmhi' to 'Imperial' and loaded up an imperial character.

I've got some guesses:

1. This function simply doesn't work for custom races, period. In this case I'll try player.getisrace ## == 0 for all vanilla races, or simply not set a race limit. The rewards would be less useful for non-ainmhi characters, though.

2. I didn't include the actual race in the esp, rather relied on loading a mod containing the race before my mod (in this case, Beautiful People). Maybe this is wrong somehow.

3. The second time I made a "dummy" race named ainmhi and with no modifications other than clicking "new" in the race menu and then giving the name. Since if the mod doesn't include ainmhi, CS would pop up all kinds of warnings. Hoping that any ainmhi mods loaded after my mod would rewrite the data for the race. Still not working though.

 

Any suggestions....? Thx :wacko:

 

(Meanwhile I'll just work on the quest itself rather than the beginning part. I intended to put in only 1-2 player race checks anyway. :P)

Link to comment
Share on other sites

the only reason i could think of that would make that mess up would be a spelling error with the race. Are you sure that ainmhi is the actual raceID and not just the name? Thats the only thing would make it not work, and since you tried it with imperial, i can see that the script itself works.

 

Or you may have to merge the 2 mods (the one with the script and the one with the custom race) into 1 mod.

Link to comment
Share on other sites

It probably is a matter of not being able to check for races not defined in the mod. However, I have a feeling that using a 'dummy race' wouldn't work either.

 

You could probably set it up so that it checks whether the player is one of the default races, and if they aren't, starts the quest.

Link to comment
Share on other sites

It probably is a matter of not being able to check for races not defined in the mod. However, I have a feeling that using a 'dummy race' wouldn't work either.

 

You could probably set it up so that it checks whether the player is one of the default races, and if they aren't, starts the quest.

Pretty much what Abramul said. The race being used by the player doesn't exist within the mod that is supposed to check for that race, even if they have the same name, their ID is different. Mods only check against itself and what .esm it is parented with. Anything outside that, even things which have the same name, globals for instance, don't work properly. If anything, having two things named the same will create conflicts that will break one of them.

 

In order for this to work, you would either need to have a .esm version of the mod containing the race (don't know why they didn't just do this and save alot of problems for everyone) which is parented by the mod (also requires anyone using that mod to have the same, exact .esm (again, why didn't the authors do this?) that the mod was made with), or that the mod is merged with the one containing the race in its entirety.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

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