Merge pull request #7324 from aws-lumberyard-dev/LYN-6769_TestingRPCs_AutonToAuth_ServerToAuth

Multiplayer AutomatedTesting: Autonomous->Authority and Server->Authority RPCs
monroegm-disable-blank-issue-2
Gene Walters 4 years ago committed by GitHub
commit be783e2c3c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -73,6 +73,19 @@ def Multiplayer_AutoComponent_RPC():
helper.succeed_if_log_line_found('EditorServer', "Script: AutoComponent_RPC_NetLevelEntity: Authority sending RPC to play some fx.", section_tracer.prints, PLAYFX_RPC_WAIT_TIME_SECONDS)
helper.succeed_if_log_line_found('Script', "AutoComponent_RPC_NetLevelEntity: I'm a client playing some fx.", section_tracer.prints, PLAYFX_RPC_WAIT_TIME_SECONDS)
# Autonomous->Authority RPC
# Sending 2 RPCs: 1 containing a parameter and 1 without
AUTONOMOUS_TO_AUTHORITY_RPC_WAIT_TIME_SECONDS = 1.0 # This RPC is sent as soon as the autonomous player script is spawned. 1 second should be more than enough time to send/receive that RPC.
helper.succeed_if_log_line_found('Script', "AutoComponent_RPC: Sending AutonomousToAuthorityNoParam RPC.", section_tracer.prints, AUTONOMOUS_TO_AUTHORITY_RPC_WAIT_TIME_SECONDS)
helper.succeed_if_log_line_found('Script', "AutoComponent_RPC: Sending AutonomousToAuthority RPC (with float param).", section_tracer.prints, AUTONOMOUS_TO_AUTHORITY_RPC_WAIT_TIME_SECONDS)
helper.succeed_if_log_line_found('EditorServer', "Script: AutoComponent_RPC: Successfully received AutonomousToAuthorityNoParams RPC.", section_tracer.prints, AUTONOMOUS_TO_AUTHORITY_RPC_WAIT_TIME_SECONDS)
helper.succeed_if_log_line_found('EditorServer', "Script: AutoComponent_RPC: Successfully received AutonomousToAuthority RPC (with expected float param).", section_tracer.prints, AUTONOMOUS_TO_AUTHORITY_RPC_WAIT_TIME_SECONDS)
# Server->Authority RPC. Inter-Entity Communication.
SERVER_TO_AUTHORITY_RPC_WAIT_TIME_SECONDS = 1.0 # This RPC is sent as soon as the networked level entity finds the player in the level, and previous tests are relying on the player's existence. 1 second should be more than enough time to send/receive that RPC.
helper.succeed_if_log_line_found('EditorServer', "Script: AutoComponent_RPC_NetLevelEntity: Send ServerToAuthority RPC.", section_tracer.prints, SERVER_TO_AUTHORITY_RPC_WAIT_TIME_SECONDS)
helper.succeed_if_log_line_found('EditorServer', "Script: AutoComponent_RPC: Received ServerToAuthority RPC. Damage=42.", section_tracer.prints, SERVER_TO_AUTHORITY_RPC_WAIT_TIME_SECONDS)
# Exit game mode
helper.exit_game_mode(TestSuccessFailTuples.exit_game_mode)

@ -669,8 +669,14 @@
"Component_[7256163899440301540]": {
"$type": "EditorScriptCanvasComponent",
"Id": 7256163899440301540,
"m_name": "AutoComponent_RPC_NetLevelEntity",
"m_name": "AutoComponent_RPC_NetLevelEntity.scriptcanvas",
"runtimeDataIsValid": true,
"runtimeDataOverrides": {
"source": {
"id": "{1D517006-AC01-5ECA-AE66-0E007871F0CD}",
"path": "C:/prj/o3de/AutomatedTesting/Levels/Multiplayer/AutoComponent_RPC/AutoComponent_RPC_NetLevelEntity.scriptcanvas"
}
},
"sourceHandle": {
"id": "{1D517006-AC01-5ECA-AE66-0E007871F0CD}",
"path": "levels/multiplayer/autocomponent_rpc/autocomponent_rpc_netlevelentity.scriptcanvas"

@ -91,22 +91,10 @@
"$type": "EditorScriptCanvasComponent",
"Id": 10596595655489113153,
"m_name": "AutoComponent_RPC",
"m_assetHolder": {
"m_asset": {
"assetId": {
"guid": "{5ED120C4-07DC-56F1-80A7-37BFC98FD74E}"
},
"assetHint": "levels/multiplayer/autocomponent_rpc/autocomponent_rpc.scriptcanvas"
}
},
"runtimeDataIsValid": true,
"runtimeDataOverrides": {
"source": {
"assetId": {
"guid": "{5ED120C4-07DC-56F1-80A7-37BFC98FD74E}"
},
"assetHint": "levels/multiplayer/autocomponent_rpc/autocomponent_rpc.scriptcanvas"
}
"sourceHandle": {
"id": "{5ED120C4-07DC-56F1-80A7-37BFC98FD74E}",
"path": "levels/multiplayer/autocomponent_rpc/autocomponent_rpc.scriptcanvas"
}
},
"Component_[11440172471478606933]": {
@ -184,6 +172,13 @@
"$type": "EditorEntityIconComponent",
"Id": 9407892837096707905
},
"Component_[9505416969829669337]": {
"$type": "EditorTagComponent",
"Id": 9505416969829669337,
"Tags": [
"Player"
]
},
"Component_[9878555871810913249]": {
"$type": "{27F1E1A1-8D9D-4C3B-BD3A-AFB9762449C0} TransformComponent",
"Id": 9878555871810913249,

Loading…
Cancel
Save