Implement inventory functions.

Fix CI build.
This commit is contained in:
Mr_Goldberg 2019-12-04 08:44:14 -05:00
parent 233835c576
commit 949a327b8a
No known key found for this signature in database
GPG key ID: 8597D87419DEF278
2 changed files with 8 additions and 2 deletions

View file

@ -72,6 +72,7 @@ build_windows:
- DLL_FILES="$(ls dll/*.cpp | tr "\n" " ")"; sed "s|dll/\*.cpp|$DLL_FILES|g" -i *.bat - DLL_FILES="$(ls dll/*.cpp | tr "\n" " ")"; sed "s|dll/\*.cpp|$DLL_FILES|g" -i *.bat
- DLL_FILES="$(ls detours/*.cpp | tr "\n" " ")"; sed "s|detours/\*.cpp|$DLL_FILES|g" -i *.bat - DLL_FILES="$(ls detours/*.cpp | tr "\n" " ")"; sed "s|detours/\*.cpp|$DLL_FILES|g" -i *.bat
- DLL_FILES="$(ls dll/*.proto | tr "\n" " " | sed "s/.proto/.pb.cc/g")"; sed "s|dll/\*.cc|$DLL_FILES|g" -i *.bat - DLL_FILES="$(ls dll/*.proto | tr "\n" " " | sed "s/.proto/.pb.cc/g")"; sed "s|dll/\*.cc|$DLL_FILES|g" -i *.bat
- DLL_FILES="$(ls steamclient_loader/*.cpp | tr "\n" " ")"; sed "s|steamclient_loader/\*.cpp|$DLL_FILES|g" -i *.bat
- export WINEDEBUG=-all - export WINEDEBUG=-all
- wine cmd /c build_win_debug_experimental.bat - wine cmd /c build_win_debug_experimental.bat
- wine cmd /c build_win_release.bat - wine cmd /c build_win_release.bat

View file

@ -757,7 +757,10 @@ STEAM_CALL_RESULT( SteamInventoryRequestPricesResult_t )
SteamAPICall_t RequestPrices() SteamAPICall_t RequestPrices()
{ {
PRINT_DEBUG("RequestPrices\n"); PRINT_DEBUG("RequestPrices\n");
return 0; SteamInventoryRequestPricesResult_t data;
data.m_result = k_EResultOK;
memcpy(data.m_rgchCurrency, "USD", 4);
return callback_results->addCallResult(data.k_iCallback, &data, sizeof(data), 0.2);
} }
@ -765,6 +768,7 @@ SteamAPICall_t RequestPrices()
uint32 GetNumItemsWithPrices() uint32 GetNumItemsWithPrices()
{ {
PRINT_DEBUG("GetNumItemsWithPrices\n"); PRINT_DEBUG("GetNumItemsWithPrices\n");
return 0;
} }
bool GetItemsWithPrices( STEAM_ARRAY_COUNT(unArrayLength) STEAM_OUT_ARRAY_COUNT(pArrayItemDefs, Items with prices) SteamItemDef_t *pArrayItemDefs, bool GetItemsWithPrices( STEAM_ARRAY_COUNT(unArrayLength) STEAM_OUT_ARRAY_COUNT(pArrayItemDefs, Items with prices) SteamItemDef_t *pArrayItemDefs,
@ -773,6 +777,7 @@ bool GetItemsWithPrices( STEAM_ARRAY_COUNT(unArrayLength) STEAM_OUT_ARRAY_COUNT(
uint32 unArrayLength ) uint32 unArrayLength )
{ {
PRINT_DEBUG("GetItemsWithPrices\n"); PRINT_DEBUG("GetItemsWithPrices\n");
return false;
} }
// Returns item definition ids and their prices in the user's local currency. // Returns item definition ids and their prices in the user's local currency.
@ -848,7 +853,7 @@ void RunCallbacks()
//only gets called once //only gets called once
//also gets called when getting items //also gets called when getting items
SteamInventoryDefinitionUpdate_t data = {}; SteamInventoryDefinitionUpdate_t data = {};
callbacks->addCBResult(data.k_iCallback, &data, sizeof(data)); callbacks->addCBResult(data.k_iCallback, &data, sizeof(data), 0.05);
} }
call_definition_update = false; call_definition_update = false;