Skip to content

Version 1.6.0. SteamGameCoordinator sent no response. #346

@jlj089742

Description

@jlj089742

Using SteamGameCoordinator to send EGCItemMg.k_EMsgGCUnlockCrate, the sending code is as follows, but no MessageCallback was received after sending.

public void sendUnlockCrate(long crateId, long keyId)  {
        ClientGCMsg<ClientToGCUnlockCrateRequest> unlockCrate = new ClientGCMsg<>(ClientToGCUnlockCrateRequest.class);
        Field bodyField = ReflectUtil.getField(ClientGCMsg.class, "body");
        bodyField.setAccessible(true);
        ClientToGCUnlockCrateRequest body = null;
        body = (ClientToGCUnlockCrateRequest) bodyField.get(unlockCrate);
        body.setCrateId(crateId).setKeyId(keyId);
        steamGameCoordinator.send(unlockCrate, 730);
    }
@Accessors(chain = true)
public class ClientToGCUnlockCrateRequest implements IGCSerializableMessage {

    @Setter
    private long crateId;
    @Setter
    private long keyId;

    public void serialize(OutputStream outputStream) throws IOException {
        BinaryWriter writer = new BinaryWriter(outputStream);
        writer.writeLong(keyId);
        writer.writeLong(crateId);
    }

    public void deserialize(InputStream inputStream) throws IOException {
    }

    public int getEMsg() {
        return EGCItemMg.k_EMsgGCUnlockCrate;
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions