AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugin/Gameplay Ideas and Requests (https://forums.alliedmods.net/forumdisplay.php?f=60)
-   -   [REQ] [HELP] SDKCall coding (https://forums.alliedmods.net/showthread.php?t=332407)

overmase 05-10-2021 13:27

[REQ] [HELP] SDKCall coding
 
If the process of respawning the player with a specific action respawns with the following code,
there is a problem that the player can not switch weapons or jump

After investigating the cause, it seems that calling m_iPlayerState with SetEntProp is incorrect.
I found that the solution was to set the PlayerState setting in SDKCall and the player would work fine.

I don't understand SDKCall, so I want this source code to code how to set PlayerState using SDKCall

This action is the only problem, and if you don't know without looking at all the sources, send it privately


PHP Code:


public Action SpawnPlayer(Handle timerany reviveClient)
{
int client GetClientUserId(reviveClient);

DispatchSpawn(reviveClient);
SetEntProp(reviveClientProp_Send"m_iPlayerState"0);
SetEntProp(reviveClientProp_Send"m_iHideHUD"2050);

TeleportEntity(reviveClientpPos[client], NULL_VECTORNULL_VECTOR);



notyouraverage 05-10-2021 17:06

Re: [REQ] [HELP] SDKCall coding
 
you may change you approach by looking into other plugins that have been made.

there are quite a lot around for respawning players.

and since you seem to know how to program, you shouldn't have any issues implementing existing code, i guess.

greets

overmase 05-11-2021 00:24

Re: [REQ] [HELP] SDKCall coding
 
The code I wrote was referred to by looking at the code of other respawn plugins.

I've seen some plugins, but I didn't have a respawn plugin for playerstate settings using SDKcall

I can't do much plugins, I'm asking for coding help rather than advice, are there any respawn plugins using playerstate with SDKCall?


All times are GMT -4. The time now is 07:44.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.