Have you ever tested yours?
I will test this this week or weekend.
I plan to place this into the first dlg conversation.
If this works then we will be able to have NPCs recognize the PC, fingers crossed:thmbup1:
thanks!:)
Logan
I haven't tested it yet, but this is what I've come up with:
// File name is SpeciesHideItem.nss
void main () {
object oPC = GetFirstPC();
int nAppearance = GetAppearanceType(oPC);
int nStack = 1;
if (nAppearance == 685) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 686) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 687) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 688) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 689) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 690) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 691) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 692) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 693) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 694) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 695) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 696) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 697) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 698) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 699) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 700) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 701) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ARK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 702) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ARK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 703) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ARK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 704) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_OFF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 705) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_OFF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 706) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_OFF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 707) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_CHS", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 708) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_CHS", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 709) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_CHS", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 710) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ECH", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 711) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ECH", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 712) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ECH", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 713) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KAZ", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 714) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KAZ", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 715) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KAZ", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 716) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KIF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 717) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KIF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 718) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KIF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 719) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 720) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 721) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 722) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 723) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 724) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 725) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 726) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 727) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 728) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 729) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 730) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 731) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 732) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 733) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 734) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 735) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ZEL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 736) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ZEL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 737) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ZEL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 738) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 739) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 740) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 741) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 742) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 743) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 744) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 745) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 746) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 747) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 748) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 749) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 750) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 751) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 752) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 753) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 754) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 755) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 756) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 757) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 758) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 759) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 760) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 761) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 762) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_DEV", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 763) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_DEV", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 764) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_DEV", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 765) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 766) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 767) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 768) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 769) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 770) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 771) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 772) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 773) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 774) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 775) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 776) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 777) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 778) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 779) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 780) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ARK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 781) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ARK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 782) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ARK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 783) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_OFF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 784) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_OFF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 785) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_OFF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 786) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_CHS", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 787) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_CHS", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 788) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_CHS", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 789) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ECH", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 790) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ECH", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 791) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ECH", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 792) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KAZ", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 793) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KAZ", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 794) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KAZ", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 795) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KIF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 796) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KIF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 797) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KIF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 798) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 799) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 800) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 801) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 802) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 803) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 804) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 805) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 806) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 807) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 808) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ZEL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 809) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ZEL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 810) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ZEL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 811) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 812) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 813) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 814) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 815) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 816) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 817) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 818) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 819) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 820) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 821) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 822) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 823) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 824) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 825) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 826) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 827) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 828) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 829) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 830) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 831) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 832) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 833) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 834) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
}
I was able to compile it with Kotor Tool. Question: should the last one say "else if (nAppear..." or should it just say "else (nAppear..."?
Looking at Redrob's script, I see you've got lot of "if" statements spawning the same item. Just a suggestion, it would be cleaner and probably easier to do that way:
Thanks, so , you mean something like this:
// File name is SpeciesHideItem.nss
void main () {
object oPC = GetFirstPC();
int nAppearance = GetAppearanceType(oPC);
int nStack = 1;
if (nAppearance == 685 || nAppearance == 686 || nAppearance == 687 || nAppearance == 688 || nAppearance == 689 || nAppearance == 690 || nAppearance == 691 || nAppearance == 692 || nAppearance == 693 || nAppearance == 694 || nAppearance == 695 || nAppearance == 696 || nAppearance == 697 || nAppearance == 698 || nAppearance == 699 || nAppearance == 700 || nAppearance == 765 || nAppearance == 766 || nAppearance == 767 || nAppearance == 768 || nAppearance == 769 || nAppearance == 770 || nAppearance == 771 || nAppearance == 772 || nAppearance == 773 || nAppearance == 774 || nAppearance == 775 || nAppearance == 776 || nAppearance == 777 || nAppearance == 778 || nAppearance == 779) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 701 || nAppearance == 702 || nAppearance == 703 || nAppearance == 780 || nAppearance == 781 || nAppearance == 782) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ARK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 704 || nAppearance == 705 || nAppearance == 706 || nAppearance == 783 || nAppearance == 784 || nAppearance == 785) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_OFF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 707 || nAppearance == 708 || nAppearance == 709 || nAppearance == 786 || nAppearance == 787 || nAppearance == 788) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_CHS", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 710 || nAppearance == 711 || nAppearance == 712 || nAppearance == 789 || nAppearance == 790 || nAppearance == 791) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ECH", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 713 || nAppearance == 714 || nAppearance == 715 || nAppearance == 792 || nAppearance == 793 || nAppearance == 794) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KAZ", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 716 || nAppearance == 717 || nAppearance == 718 || nAppearance == 795 || nAppearance == 796 || nAppearance == 797) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KIF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 719 || nAppearance == 720 || nAppearance == 721 || nAppearance == 798 || nAppearance == 799 || nAppearance == 800) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 722 || nAppearance == 723 || nAppearance == 724 || nAppearance == 801 || nAppearance == 802 || nAppearance == 803) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 725 || nAppearance == 726 || nAppearance == 727 || nAppearance == 728 || nAppearance == 729 || nAppearance == 730 || nAppearance == 731 || nAppearance == 732 || nAppearance == 733 || nAppearance == 734 || nAppearance == 804 || nAppearance == 805 || nAppearance == 806 || nAppearance == 807) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 735 || nAppearance == 736 || nAppearance == 737 || nAppearance == 808 || nAppearance == 809 || nAppearance == 810) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ZEL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 738 || nAppearance == 739 || nAppearance == 740 || nAppearance == 741 || nAppearance == 742 || nAppearance == 743 || nAppearance == 744 || nAppearance == 745 || nAppearance == 746 || nAppearance == 747 || nAppearance == 748 || nAppearance == 749 || nAppearance == 750 || nAppearance == 751 || nAppearance == 752 || nAppearance == 753 || nAppearance == 754 || nAppearance == 755 || nAppearance == 756 || nAppearance == 757 || nAppearance == 758 || nAppearance == 759 || nAppearance == 760 || nAppearance == 761 || nAppearance == 811 || nAppearance == 812 || nAppearance == 813 || nAppearance == 814 || nAppearance == 815 || nAppearance == 816 || nAppearance == 817 || nAppearance == 818 || nAppearance == 819 || nAppearance == 820 || nAppearance == 821 || nAppearance == 822 || nAppearance == 823 || nAppearance == 824 || nAppearance == 825 || nAppearance == 826 || nAppearance == 827 || nAppearance == 828 || nAppearance == 829 || nAppearance == 830 || nAppearance == 831 || nAppearance == 832 || nAppearance == 833 || nAppearance == 834) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 762 || nAppearance == 763 || nAppearance == 764) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_DEV", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
}
Or could I also do this? I only just learned that the two vertical pipes || is a "logical OR". I'm just not sure that if I put them on seperate lines, if I need to put the brackets around the "nAppearance == 685"? If that is how it should be done, it makes it easier to see if I've got all the row numbers correct.
// File name is SpeciesHideItem.nss
void main () {
object oPC = GetFirstPC();
int nAppearance = GetAppearanceType(oPC);
int nStack = 1;
if (nAppearance == 685)
|| (nAppearance == 686)
|| (nAppearance == 687)
|| (nAppearance == 688)
|| (nAppearance == 689)
|| (nAppearance == 690)
|| (nAppearance == 691)
|| (nAppearance == 692)
|| (nAppearance == 693)
|| (nAppearance == 694)
|| (nAppearance == 695)
|| (nAppearance == 696)
|| (nAppearance == 697)
|| (nAppearance == 698)
|| (nAppearance == 699)
|| (nAppearance == 700)
|| (nAppearance == 765)
|| (nAppearance == 766)
|| (nAppearance == 767)
|| (nAppearance == 768)
|| (nAppearance == 769)
|| (nAppearance == 770)
|| (nAppearance == 771)
|| (nAppearance == 772)
|| (nAppearance == 773)
|| (nAppearance == 774)
|| (nAppearance == 775)
|| (nAppearance == 776)
|| (nAppearance == 777)
|| (nAppearance == 778)
|| (nAppearance == 779) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_HUM", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 701)
|| (nAppearance == 702)
|| (nAppearance == 703)
|| (nAppearance == 780)
|| (nAppearance == 781)
|| (nAppearance == 782) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ARK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 704)
|| (nAppearance == 705)
|| (nAppearance == 706)
|| (nAppearance == 783)
|| (nAppearance == 784)
|| (nAppearance == 785) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_OFF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 707)
|| (nAppearance == 708)
|| (nAppearance == 709)
|| (nAppearance == 786)
|| (nAppearance == 787)
|| (nAppearance == 788) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_CHS", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 710)
|| (nAppearance == 711)
|| (nAppearance == 712)
|| (nAppearance == 789)
|| (nAppearance == 790)
|| (nAppearance == 791) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ECH", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 713)
|| (nAppearance == 714)
|| (nAppearance == 715)
|| (nAppearance == 792)
|| (nAppearance == 793)
|| (nAppearance == 794) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KAZ", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 716)
|| (nAppearance == 717)
|| (nAppearance == 718)
|| (nAppearance == 795)
|| (nAppearance == 796)
|| (nAppearance == 797) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_KIF", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 719)
|| (nAppearance == 720)
|| (nAppearance == 721)
|| (nAppearance == 798)
|| (nAppearance == 799)
|| (nAppearance == 800) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRK", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 722)
|| (nAppearance == 723)
|| (nAppearance == 724)
|| (nAppearance == 801)
|| (nAppearance == 802)
|| (nAppearance == 803) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_MRL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 725)
|| (nAppearance == 726)
|| (nAppearance == 727)
|| (nAppearance == 728)
|| (nAppearance == 729)
|| (nAppearance == 730)
|| (nAppearance == 731)
|| (nAppearance == 732)
|| (nAppearance == 733)
|| (nAppearance == 734)
|| (nAppearance == 804)
|| (nAppearance == 805)
|| (nAppearance == 806)
|| (nAppearance == 807) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_RAT", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 735)
|| (nAppearance == 736)
|| (nAppearance == 737)
|| (nAppearance == 808)
|| (nAppearance == 809)
|| (nAppearance == 810) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_ZEL", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 738)
|| (nAppearance == 739)
|| (nAppearance == 740)
|| (nAppearance == 741)
|| (nAppearance == 742)
|| (nAppearance == 743)
|| (nAppearance == 744)
|| (nAppearance == 745)
|| (nAppearance == 746)
|| (nAppearance == 747)
|| (nAppearance == 748)
|| (nAppearance == 749)
|| (nAppearance == 750)
|| (nAppearance == 751)
|| (nAppearance == 752)
|| (nAppearance == 753)
|| (nAppearance == 754)
|| (nAppearance == 755)
|| (nAppearance == 756)
|| (nAppearance == 757)
|| (nAppearance == 758)
|| (nAppearance == 759)
|| (nAppearance == 760)
|| (nAppearance == 761)
|| (nAppearance == 811)
|| (nAppearance == 812)
|| (nAppearance == 813)
|| (nAppearance == 814)
|| (nAppearance == 815)
|| (nAppearance == 816)
|| (nAppearance == 817)
|| (nAppearance == 818)
|| (nAppearance == 819)
|| (nAppearance == 820)
|| (nAppearance == 821)
|| (nAppearance == 822)
|| (nAppearance == 823)
|| (nAppearance == 824)
|| (nAppearance == 825)
|| (nAppearance == 826)
|| (nAppearance == 827)
|| (nAppearance == 828)
|| (nAppearance == 829)
|| (nAppearance == 830)
|| (nAppearance == 831)
|| (nAppearance == 832)
|| (nAppearance == 833)
|| (nAppearance == 834) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_TWI", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
else if (nAppearance == 762)
|| (nAppearance == 763)
|| (nAppearance == 764) {
AssignCommand(oPC, ActionEquipItem( CreateItemOnObject("PC_HIDE_RR41_DEV", oPC), INVENTORY_SLOT_CARMOUR, TRUE ));
}
}
For more debugging add a line like that and the end of each else if that describes what happened or something unique to it and then after the script fires check to see that it fired right through the feedback message.
Good Idea. I'll have to add in the strings of text for testing purposes later.