Ejemplo n.º 1
0
BOOL LLToolPlacer::placeObject(S32 x, S32 y, MASK mask)
{
    BOOL added = TRUE;

//MK
    if (RRenabled && (gAgent.mRRInterface.mContainsEdit || gAgent.mRRInterface.mContainsRez)) {
        return TRUE;
    }
//mk

    if (gSavedSettings.getBOOL("CreateToolCopySelection"))
    {
        added = addDuplicate(x, y);
    }
    else
    {
        added = addObject( sObjectType, x, y, FALSE );
    }

    // ...and go back to the default tool
    if (added && !gSavedSettings.getBOOL("CreateToolKeepSelected"))
    {
        gToolMgr->getCurrentToolset()->selectTool( gToolTranslate );
    }

    return added;
}
BOOL LLToolPlacer::placeObject(S32 x, S32 y, MASK mask)
{
	BOOL added = TRUE;
	
// [RLVa:KB] - Checked: 2010-01-02 (RLVa-1.1.0l) | Modified: RLVa-1.1.0l
	if ( (rlv_handler_t::isEnabled()) && ((gRlvHandler.hasBehaviour(RLV_BHVR_REZ)) || (gRlvHandler.hasBehaviour(RLV_BHVR_INTERACT))) )
	{
		return TRUE; // Callers seem to expect a "did you handle it?" so we return TRUE rather than FALSE
	}
// [/RLVa:KB]

	if (gSavedSettings.getBOOL("CreateToolCopySelection"))
	{
		added = addDuplicate(x, y);
	}
	else
	{
		added = addObject( sObjectType, x, y, FALSE );
	}

	// ...and go back to the default tool
	if (added && !gSavedSettings.getBOOL("CreateToolKeepSelected"))
	{
		LLToolMgr::getInstance()->getCurrentToolset()->selectTool( LLToolCompTranslate::getInstance() );
	}

	return added;
}
Ejemplo n.º 3
0
ShopItem::ShopItem (int id, int price) : Item (id, 0), mPrice(price)
{
    mDisplayName = getInfo().getName() +
                        " (" + Units::formatCurrency(mPrice).c_str() + ")";
    setInvIndex(-1);
    addDuplicate(-1, 0);
}
Ejemplo n.º 4
0
ShopItem::ShopItem(int inventoryIndex, int id,
                   int quantity, int price) :
    Item(id, 0),
    mPrice(price)
{
    mDisplayName = getInfo().getName() +
                        " (" + Units::formatCurrency(mPrice).c_str() + ")";
    setInvIndex(inventoryIndex);
    addDuplicate(inventoryIndex, quantity);
}
Ejemplo n.º 5
0
ShopItem::ShopItem(const int id,
                   const int type,
                   const ItemColor color,
                   const int price) :
    Item(id, type, 0, 0, color,
         Identified_true,
         Damaged_false,
         Favorite_false,
         Equipm_false,
         Equipped_false),
    mDisplayName(),
    mDuplicates(),
    mPrice(price),
    mShowQuantity(false),
    mVisible(true)
{
    updateDisplayName(0);
    setInvIndex(-1);
    addDuplicate(-1, 0);
}
Ejemplo n.º 6
0
BOOL LLToolPlacer::placeObject(S32 x, S32 y, MASK mask)
{
	BOOL added = TRUE;
	
	if (gSavedSettings.getBOOL("CreateToolCopySelection"))
	{
		added = addDuplicate(x, y);
	}
	else
	{
		added = addObject( sObjectType, x, y, FALSE );
	}

	// ...and go back to the default tool
	if (added && !gSavedSettings.getBOOL("CreateToolKeepSelected"))
	{
		LLToolMgr::getInstance()->getCurrentToolset()->selectTool( LLToolCompTranslate::getInstance() );
	}

	return added;
}
Ejemplo n.º 7
0
ShopItem::ShopItem(const int inventoryIndex,
                   const int id,
                   const int type,
                   const unsigned char color,
                   const int quantity,
                   const int price) :
    Item(id, type, 0, 0, color,
         Identified_true,
         Damaged_false,
         Favorite_false,
         Equipm_false,
         Equipped_false),
    mDisplayName(),
    mDuplicates(),
    mPrice(price),
    mShowQuantity(true),
    mVisible(true)
{
    updateDisplayName(quantity);
    setInvIndex(inventoryIndex);
    addDuplicate(inventoryIndex, quantity);
}