2012-03-29, 14:41
Hi All,
Finally got around to updating to Eden and have a play with the new JSON RPC stuff. I've had a read through Montellese's very useful thread on the changes made and note the following.
But making a JSON RPC request to Player.GetProperties with State properties returns an error message.
Request:
Response
So, is there anywhere now I can find out the state of the player (Paused/Playing)
Thanks
Finally got around to updating to Eden and have a play with the new JSON RPC stuff. I've had a read through Montellese's very useful thread on the changes made and note the following.
Quote:Replaced Player.State, Player.GetTime and Player.GetPercentage with Player.GetProperties
But making a JSON RPC request to Player.GetProperties with State properties returns an error message.
Request:
Code:
"{\r\n \"jsonrpc\": \"2.0\",\r\n \"method\": \"Player.GetProperties\",\r\n \"params\": {\r\n \"properties\": [\r\n \"state\"\r\n ],\r\n \"playerid\": 1\r\n },\r\n \"id\": 1\r\n}"
Response
Code:
{
"error": {
"code": -32602,
"data": {
"method": "Player.GetProperties",
"stack": {
"message": "array element at index 0 does not match",
"name": "properties",
"property": {
"message": "Received value does not match any of the defined enum values",
"name": "Player.Property.Name",
"type": "string"
},
"type": "array"
}
},
"message": "Invalid params."
},
"id": 1,
"jsonrpc": "2.0"
}
So, is there anywhere now I can find out the state of the player (Paused/Playing)
Thanks