# Purchase Purchase Item

Grammar — Purchase purchaseItem
FlagsNative | Action

Convenience function to mark the specified purchase item as purchased, recently purchased, and play the purchase animation on it.

# Arguments

Returns — void

native void PurchaseItemPurchase(int inPurchaseItemId);

Category: Story / Tech Purchase Panel / Interaction

# Examples

campaigns/libertystory.sc2campaignbase.sc2data/TriggerLibs/CampaignLib.galaxy:12698

        PlayerModifyPropertyInt(1, c_playerPropCredits, c_playerPropOperSetTo, libCamp_gf_StoryCredits());
        libCamp_gf_TS_AddRecentTech(lv_tech);
        PurchaseItemPurchase(libCamp_gv_tS_Tech_UI[(lv_tech)]);
        TriggerDebugOutput(1, (StringExternal("Param/Value/lib_Camp_D1E7DDD8") + IntToText(libCamp_gf_TS_StoryTechPurchasedCountInCategory(libCamp_ge_StoryTechCategory_StoryTechCategoryInfantry))), false);
        AchievementTermQuantitySet(1, "TStory01_1", libCamp_gf_TS_StoryTechPurchasedCountInCategory(libCamp_ge_StoryTechCategory_StoryTechCategoryInfantry));