Skip to content

Commit

Permalink
Update Steamworks SDK
Browse files Browse the repository at this point in the history
  • Loading branch information
vittorioromeo committed Apr 5, 2023
1 parent c2eb50e commit c5d5e48
Show file tree
Hide file tree
Showing 28 changed files with 494 additions and 180 deletions.
Binary file modified _RELEASE/libsdkencryptedappticket.so
Binary file not shown.
Binary file modified _RELEASE/libsteam_api.so
Binary file not shown.
Binary file modified _RELEASE/sdkencryptedappticket64.dll
Binary file not shown.
Binary file modified _RELEASE/steam_api64.dll
Binary file not shown.
Binary file modified _RELEASE/steam_api64.lib
Binary file not shown.
2 changes: 1 addition & 1 deletion public/steam/isteamapplist.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ STEAM_DEFINE_USER_INTERFACE_ACCESSOR( ISteamAppList *, SteamAppList, STEAMAPPLIS


//---------------------------------------------------------------------------------
// Purpose: Sent when a new app is installed
// Purpose: Sent when a new app is installed (not downloaded yet)
//---------------------------------------------------------------------------------
STEAM_CALLBACK_BEGIN( SteamAppInstalled_t, k_iSteamAppListCallbacks + 1 )
STEAM_CALLBACK_MEMBER( 0, AppId_t, m_nAppID ) // ID of the app that installs
Expand Down
27 changes: 3 additions & 24 deletions public/steam/isteamapps.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,9 @@ class ISteamApps

// check if game is a timed trial with limited playtime
virtual bool BIsTimedTrial( uint32* punSecondsAllowed, uint32* punSecondsPlayed ) = 0;

// set current DLC AppID being played (or 0 if none). Allows Steam to track usage of major DLC extensions
virtual bool SetDlcContext( AppId_t nAppID ) = 0;
};

#define STEAMAPPS_INTERFACE_VERSION "STEAMAPPS_INTERFACE_VERSION008"
Expand All @@ -134,30 +137,6 @@ struct DlcInstalled_t
};


//-----------------------------------------------------------------------------
// Purpose: possible results when registering an activation code
//-----------------------------------------------------------------------------
enum ERegisterActivationCodeResult
{
k_ERegisterActivationCodeResultOK = 0,
k_ERegisterActivationCodeResultFail = 1,
k_ERegisterActivationCodeResultAlreadyRegistered = 2,
k_ERegisterActivationCodeResultTimeout = 3,
k_ERegisterActivationCodeAlreadyOwned = 4,
};


//-----------------------------------------------------------------------------
// Purpose: response to RegisterActivationCode()
//-----------------------------------------------------------------------------
struct RegisterActivationCodeResponse_t
{
enum { k_iCallback = k_iSteamAppsCallbacks + 8 };
ERegisterActivationCodeResult m_eResult;
uint32 m_unPackageRegistered; // package that was registered. Only set on success
};


//---------------------------------------------------------------------------------
// Purpose: posted after the user gains executes a Steam URL with command line or query parameters
// such as steam://run/<appid>//-commandline/?param1=value1&param2=value2&param3=value3 etc
Expand Down
15 changes: 13 additions & 2 deletions public/steam/isteamcontroller.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@

#define STEAM_CONTROLLER_MAX_COUNT 16

#define STEAM_CONTROLLER_MAX_ANALOG_ACTIONS 16
#define STEAM_CONTROLLER_MAX_ANALOG_ACTIONS 24

#define STEAM_CONTROLLER_MAX_DIGITAL_ACTIONS 128
#define STEAM_CONTROLLER_MAX_DIGITAL_ACTIONS 256

#define STEAM_CONTROLLER_MAX_ORIGINS 8

Expand Down Expand Up @@ -448,6 +448,16 @@ enum EControllerActionOrigin
k_EControllerActionOrigin_SteamDeck_Reserved19,
k_EControllerActionOrigin_SteamDeck_Reserved20,

k_EControllerActionOrigin_Switch_JoyConButton_N, // With a Horizontal JoyCon this will be Y or what would be Dpad Right when vertical
k_EControllerActionOrigin_Switch_JoyConButton_E, // X
k_EControllerActionOrigin_Switch_JoyConButton_S, // A
k_EControllerActionOrigin_Switch_JoyConButton_W, // B

k_EControllerActionOrigin_PS5_LeftGrip,
k_EControllerActionOrigin_PS5_RightGrip,
k_EControllerActionOrigin_PS5_LeftFn,
k_EControllerActionOrigin_PS5_RightFn,

k_EControllerActionOrigin_Count, // If Steam has added support for new controllers origins will go here.
k_EControllerActionOrigin_MaximumPossibleValue = 32767, // Origins are currently a maximum of 16 bits.
};
Expand Down Expand Up @@ -529,6 +539,7 @@ typedef uint64 ControllerAnalogActionHandle_t;
#define ControllerAnalogActionData_t InputAnalogActionData_t
#define ControllerDigitalActionData_t InputDigitalActionData_t
#define ControllerMotionData_t InputMotionData_t
#define ControllerMotionDataV2_t InputMotionDataV2_t
#else
struct ControllerAnalogActionData_t
{
Expand Down
169 changes: 169 additions & 0 deletions public/steam/isteamdualsense.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,169 @@
/* SIE CONFIDENTIAL
* $PSLibId$
* Copyright (C) 2019 Sony Interactive Entertainment Inc.
* All Rights Reserved.
*/


#ifndef _SCE_PAD_TRIGGER_EFFECT_H
#define _SCE_PAD_TRIGGER_EFFECT_H


#define SCE_PAD_TRIGGER_EFFECT_TRIGGER_MASK_L2 0x01
#define SCE_PAD_TRIGGER_EFFECT_TRIGGER_MASK_R2 0x02

#define SCE_PAD_TRIGGER_EFFECT_PARAM_INDEX_FOR_L2 0
#define SCE_PAD_TRIGGER_EFFECT_PARAM_INDEX_FOR_R2 1

#define SCE_PAD_TRIGGER_EFFECT_TRIGGER_NUM 2

/* Definition of control point num */
#define SCE_PAD_TRIGGER_EFFECT_CONTROL_POINT_NUM 10

typedef enum ScePadTriggerEffectMode{
SCE_PAD_TRIGGER_EFFECT_MODE_OFF,
SCE_PAD_TRIGGER_EFFECT_MODE_FEEDBACK,
SCE_PAD_TRIGGER_EFFECT_MODE_WEAPON,
SCE_PAD_TRIGGER_EFFECT_MODE_VIBRATION,
SCE_PAD_TRIGGER_EFFECT_MODE_MULTIPLE_POSITION_FEEDBACK,
SCE_PAD_TRIGGER_EFFECT_MODE_SLOPE_FEEDBACK,
SCE_PAD_TRIGGER_EFFECT_MODE_MULTIPLE_POSITION_VIBRATION,
} ScePadTriggerEffectMode;

/**
*E
* @brief parameter for setting the trigger effect to off mode.
* Off Mode: Stop trigger effect.
**/
typedef struct ScePadTriggerEffectOffParam{
uint8_t padding[48];
} ScePadTriggerEffectOffParam;

/**
*E
* @brief parameter for setting the trigger effect to Feedback mode.
* Feedback Mode: The motor arm pushes back trigger.
* Trigger obtains stiffness at specified position.
**/
typedef struct ScePadTriggerEffectFeedbackParam{
uint8_t position; /*E position where the strength of target trigger start changing(0~9). */
uint8_t strength; /*E strength that the motor arm pushes back target trigger(0~8 (0: Same as Off mode)). */
uint8_t padding[46];
} ScePadTriggerEffectFeedbackParam;

/**
*E
* @brief parameter for setting the trigger effect to Weapon mode.
* Weapon Mode: Emulate weapon like gun trigger.
**/
typedef struct ScePadTriggerEffectWeaponParam{
uint8_t startPosition; /*E position where the stiffness of trigger start changing(2~7). */
uint8_t endPosition; /*E position where the stiffness of trigger finish changing(startPosition+1~8). */
uint8_t strength; /*E strength of gun trigger(0~8 (0: Same as Off mode)). */
uint8_t padding[45];
} ScePadTriggerEffectWeaponParam;

/**
*E
* @brief parameter for setting the trigger effect to Vibration mode.
* Vibration Mode: Vibrates motor arm around specified position.
**/
typedef struct ScePadTriggerEffectVibrationParam{
uint8_t position; /*E position where the motor arm start vibrating(0~9). */
uint8_t amplitude; /*E vibration amplitude(0~8 (0: Same as Off mode)). */
uint8_t frequency; /*E vibration frequency(0~255[Hz] (0: Same as Off mode)). */
uint8_t padding[45];
} ScePadTriggerEffectVibrationParam;

/**
*E
* @brief parameter for setting the trigger effect to ScePadTriggerEffectMultiplePositionFeedbackParam mode.
* Multi Position Feedback Mode: The motor arm pushes back trigger.
* Trigger obtains specified stiffness at each control point.
**/
typedef struct ScePadTriggerEffectMultiplePositionFeedbackParam{
uint8_t strength[SCE_PAD_TRIGGER_EFFECT_CONTROL_POINT_NUM]; /*E strength that the motor arm pushes back target trigger at position(0~8 (0: Same as Off mode)).
* strength[0] means strength of motor arm at position0.
* strength[1] means strength of motor arm at position1.
* ...
* */
uint8_t padding[38];
} ScePadTriggerEffectMultiplePositionFeedbackParam;

/**
*E
* @brief parameter for setting the trigger effect to Feedback3 mode.
* Slope Feedback Mode: The motor arm pushes back trigger between two spedified control points.
* Stiffness of the trigger is changing depending on the set place.
**/
typedef struct ScePadTriggerEffectSlopeFeedbackParam{

uint8_t startPosition; /*E position where the strength of target trigger start changing(0~endPosition). */
uint8_t endPosition; /*E position where the strength of target trigger finish changing(startPosition+1~9). */
uint8_t startStrength; /*E strength when trigger's position is startPosition(1~8) */
uint8_t endStrength; /*E strength when trigger's position is endPosition(1~8) */
uint8_t padding[44];
} ScePadTriggerEffectSlopeFeedbackParam;

/**
*E
* @brief parameter for setting the trigger effect to Vibration2 mode.
* Multi Position Vibration Mode: Vibrates motor arm around specified control point.
* Trigger vibrates specified amplitude at each control point.
**/
typedef struct ScePadTriggerEffectMultiplePositionVibrationParam{
uint8_t frequency; /*E vibration frequency(0~255 (0: Same as Off mode)) */
uint8_t amplitude[SCE_PAD_TRIGGER_EFFECT_CONTROL_POINT_NUM]; /*E vibration amplitude at position(0~8 (0: Same as Off mode)).
* amplitude[0] means amplitude of vibration at position0.
* amplitude[1] means amplitude of vibration at position1.
* ...
* */
uint8_t padding[37];
} ScePadTriggerEffectMultiplePositionVibrationParam;

/**
*E
* @brief parameter for setting the trigger effect mode.
**/
typedef union ScePadTriggerEffectCommandData{
ScePadTriggerEffectOffParam offParam;
ScePadTriggerEffectFeedbackParam feedbackParam;
ScePadTriggerEffectWeaponParam weaponParam;
ScePadTriggerEffectVibrationParam vibrationParam;
ScePadTriggerEffectMultiplePositionFeedbackParam multiplePositionFeedbackParam;
ScePadTriggerEffectSlopeFeedbackParam slopeFeedbackParam;
ScePadTriggerEffectMultiplePositionVibrationParam multiplePositionVibrationParam;
} ScePadTriggerEffectCommandData;

/**
*E
* @brief parameter for setting the trigger effect.
**/
typedef struct ScePadTriggerEffectCommand{
ScePadTriggerEffectMode mode;
uint8_t padding[4];
ScePadTriggerEffectCommandData commandData;
} ScePadTriggerEffectCommand;

/**
*E
* @brief parameter for the scePadSetTriggerEffect function.
**/
typedef struct ScePadTriggerEffectParam{

uint8_t triggerMask; /*E Set trigger mask to activate trigger effect commands.
* SCE_PAD_TRIGGER_EFFECT_TRIGGER_MASK_L2 : 0x01
* SCE_PAD_TRIGGER_EFFECT_TRIGGER_MASK_R2 : 0x02
* */
uint8_t padding[7];

ScePadTriggerEffectCommand command[SCE_PAD_TRIGGER_EFFECT_TRIGGER_NUM]; /*E command[SCE_PAD_TRIGGER_EFFECT_PARAM_INDEX_FOR_L2] is for L2 trigger setting
* and param[SCE_PAD_TRIGGER_EFFECT_PARAM_INDEX_FOR_R2] is for R2 trgger setting.
* */
} ScePadTriggerEffectParam;

#if defined(__cplusplus) && __cplusplus >= 201103L
static_assert( sizeof( ScePadTriggerEffectParam ) == 120, "ScePadTriggerEffectParam has incorrect size" );
#endif

#endif /* _SCE_PAD_TRIGGER_EFFECT_H */
4 changes: 3 additions & 1 deletion public/steam/isteamfriends.h
Original file line number Diff line number Diff line change
Expand Up @@ -514,7 +514,9 @@ enum EPersonaChange
struct GameOverlayActivated_t
{
enum { k_iCallback = k_iSteamFriendsCallbacks + 31 };
uint8 m_bActive; // true if it's just been activated, false otherwise
uint8 m_bActive; // true if it's just been activated, false otherwise
bool m_bUserInitiated; // true if the user asked for the overlay to be activated/deactivated
AppId_t m_nAppID; // the appID of the game (should always be the current game)
};


Expand Down
6 changes: 4 additions & 2 deletions public/steam/isteamgameserver.h
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,9 @@ class ISteamGameServer

// Retrieve ticket to be sent to the entity who wishes to authenticate you ( using BeginAuthSession API ).
// pcbTicket retrieves the length of the actual ticket.
virtual HAuthTicket GetAuthSessionTicket( void *pTicket, int cbMaxTicket, uint32 *pcbTicket ) = 0;
// SteamNetworkingIdentity is an optional parameter to hold the public IP address of the entity you are connecting to
// if an IP address is passed Steam will only allow the ticket to be used by an entity with that IP address
virtual HAuthTicket GetAuthSessionTicket( void *pTicket, int cbMaxTicket, uint32 *pcbTicket, const SteamNetworkingIdentity *pSnid ) = 0;

// Authenticate ticket ( from GetAuthSessionTicket ) from entity steamID to be sure it is valid and isnt reused
// Registers for callbacks if the entity goes offline or cancels the ticket ( see ValidateAuthTicketResponse_t callback and EAuthSessionResponse )
Expand Down Expand Up @@ -264,7 +266,7 @@ class ISteamGameServer
)
};

#define STEAMGAMESERVER_INTERFACE_VERSION "SteamGameServer014"
#define STEAMGAMESERVER_INTERFACE_VERSION "SteamGameServer015"

// Global accessor
inline ISteamGameServer *SteamGameServer();
Expand Down
Loading

0 comments on commit c5d5e48

Please sign in to comment.