| 890 | /////////////////////////////////////////////////////////////////////////////// |
| 891 | |
| 892 | void SampleBridges::helpRender(PxU32 x, PxU32 y, PxU8 textAlpha) |
| 893 | { |
| 894 | Renderer* renderer = getRenderer(); |
| 895 | const PxU32 yInc = 18; |
| 896 | const PxReal scale = 0.5f; |
| 897 | const PxReal shadowOffset = 6.0f; |
| 898 | const RendererColor textColor(255, 255, 255, textAlpha); |
| 899 | const bool isMouseSupported = getApplication().getPlatform()->getSampleUserInput()->mouseSupported(); |
| 900 | const bool isPadSupported = getApplication().getPlatform()->getSampleUserInput()->gamepadSupported(); |
| 901 | const char* msg; |
| 902 | |
| 903 | if (isMouseSupported && isPadSupported) |
| 904 | renderer->print(x, y += yInc, "Use mouse or right stick to rotate the camera", scale, shadowOffset, textColor); |
| 905 | else if (isMouseSupported) |
| 906 | renderer->print(x, y += yInc, "Use mouse to rotate the camera", scale, shadowOffset, textColor); |
| 907 | else if (isPadSupported) |
| 908 | renderer->print(x, y += yInc, "Use right stick to rotate the camera", scale, shadowOffset, textColor); |
| 909 | if (isPadSupported) |
| 910 | renderer->print(x, y += yInc, "Use left stick to move",scale, shadowOffset, textColor); |
| 911 | msg = mApplication.inputMoveInfoMsg("Press "," to move", CAMERA_MOVE_FORWARD,CAMERA_MOVE_BACKWARD, CAMERA_MOVE_LEFT, CAMERA_MOVE_RIGHT); |
| 912 | if(msg) |
| 913 | renderer->print(x, y += yInc, msg,scale, shadowOffset, textColor); |
| 914 | msg = mApplication.inputInfoMsg("Press "," to move fast", CAMERA_SHIFT_SPEED, -1); |
| 915 | if(msg) |
| 916 | renderer->print(x, y += yInc, msg, scale, shadowOffset, textColor); |
| 917 | msg = mApplication.inputInfoMsg("Press "," to jump", CAMERA_JUMP,-1); |
| 918 | if(msg) |
| 919 | renderer->print(x, y += yInc, msg,scale, shadowOffset, textColor); |
| 920 | msg = mApplication.inputInfoMsg("Press "," to crouch", CAMERA_CROUCH,-1); |
| 921 | if(msg) |
| 922 | renderer->print(x, y += yInc, msg,scale, shadowOffset, textColor); ; |
| 923 | msg = mApplication.inputInfoMsg("Press "," to throw an object", SPAWN_DEBUG_OBJECT, -1); |
| 924 | if(msg) |
| 925 | renderer->print(x, y += yInc, msg,scale, shadowOffset, textColor); ; |
| 926 | msg = mApplication.inputInfoMsg("Press "," to reset CCT position", RETRY,-1); |
| 927 | if(msg) |
| 928 | renderer->print(x, y += yInc, msg,scale, shadowOffset, textColor); |
| 929 | msg = mApplication.inputInfoMsg("Press "," to teleport from one platform to another", TELEPORT,-1); |
| 930 | if(msg) |
| 931 | renderer->print(x, y += yInc, msg,scale, shadowOffset, textColor); |
| 932 | } |
| 933 | |
| 934 | void SampleBridges::descriptionRender(PxU32 x, PxU32 y, PxU8 textAlpha) |
| 935 | { |
nothing calls this directly
no test coverage detected