View Single Post
Old 05-03-2012, 07:25 PM   #186
Fallen Guardian
Wandering the Galaxy...
 
Fallen Guardian's Avatar
 
Join Date: Aug 2010
Location: Unknown Regions
Posts: 1,286
Current Game: Knights of the Old Republic
Veteran Modder Helpful! 
Quote:
Originally Posted by JCarter426 View Post
I found something:
Code:
// 397: Get the base item type (BASE_ITEM_*) of oItem.
// * Returns BASE_ITEM_INVALID if oItem is an invalid item.
int GetBaseItemType(object oItem);
So just set it up to check if the base item type is BASE_ITEM_BLASTER_PISTOL (12). The full list is in NWScript. You might want to repeat it for ion pistols, sonic pistols, and the like.
Hey thanks JC. Though, not being the best scripter in the world, I don't really have an idea how to set it up. Here's my attempt:

Code:
int StartingConditional()
{
    if (GetItemInSlot(INVENTORY_SLOT_RIGHTWEAPON, GetFirstPC()) == GetBaseItemType(12));
    {
        return TRUE;
    }
    return FALSE;
}
The compiler is telling me that I have a type mismatch in paramter 1 when attempting to get the base item, as well as an if or else statement followed by a blank statement.


The truly fallen cannot return to the light. If someone "falls" and "returns," they never really, truly fell.

Current Work in Progress: Dantooine Tension

Released Works
Blaster Pistol Enhancement
Dustil Restoration
Ebon Hawk Texture Enhancement
Gaffi Stick Improvement
Weapon Model Overhaul Texture Rework (Thanks to Toasty Fresh!)
Sunry Murder Recording Enhancement
VP's Hi Poly Tin Cans - KotOR 1 Version
Fallen Guardian is offline   you may: quote & reply,