First Thanks for this nice example.
i got one more Problem the Price of the Item always Returns -1
My Code :
Plugin Init
PHP Code:
// Item Name Price Handler Plugin ID -1 = Lokal
AddShopItem( "Gay or Not?", 15, "gay_check", -1 );
AddShopItem Func
PHP Code:
AddShopItem( szItemName[ ], iCost, szHandler[ ], iPlugin )
{
new eItemData[ ItemData ];
copy( eItemData[ ItemName ], charsmax( eItemData[ ItemName ] ), szItemName );
eItemData[ ItemCost ] = iCost;
eItemData[ ItemFuncID ] = get_func_id( szHandler, iPlugin );
eItemData[ ItemPlugin ] = iPlugin;
// Here in Testing Print eItemData[ ItemCost ] also returns -1
ArrayPushArray( g_aItems, eItemData );
g_iTotalItems++;
return ( g_iTotalItems - 1 );
}
Best Regards
__________________