Method, apparatus, and device for controlling a virtual character to ride a vehicle through a handle
The virtual character switches the riding method in the virtual environment through the trigger button and rotation angle of the handle, which solves the problem of low operation efficiency in the interactive control of virtual characters and vehicles, and improves the player's operation accuracy and gaming experience.
Patent Information
- Application Number
- CN202210590550.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-26
- Publication Date
- 2025-07-29
- Estimated Expiration
- 2042-05-26
AI Technical Summary
In the prior art, the operation efficiency of controlling the virtual character riding vehicle through the handle is low, especially in the interaction control between the virtual character and the vehicle, there is inconvenience of human-computer interaction.
The virtual character is controlled through the trigger buttons and rotation angle of the handle to switch from positive riding to side riding in the virtual environment, increasing the contact area and contact strength between the virtual character and the vehicle, and controlling the speed and movement of the vehicle through the rocker operation.
It improves the player's operation efficiency and accuracy, makes it easier for players to remember the operating rules of the controller, reduces the situation of misoperation, and enhances the immersion and experience of the game.
Smart Images

Figure CN115300900B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of game technologies, and in particular, to a method, apparatus, and device for controlling a virtual character in a game to ride a vehicle through a gamepad. Background Art
[0002] In some games, players can use virtual vehicles in the game to increase the movement speed of the controlled virtual character or complete specific game tasks. In traditional personal computer games, players can use the keyboard and mouse to complete rich game operations. However, the keyboard and mouse are separated and have fixed operation positions, which reduces the convenience of player operations. During the game operation process, the player's operation feel is not comfortable. To solve the above problems, game operations are completed through gamepads. However, in games that require operation through gamepads, limited by this input and interaction method of the gamepad, there are some deficiencies or inconveniences in the interactive control of virtual characters, especially the interactive control of virtual characters involving virtual vehicles. Summary of the Invention
[0003] In view of this, this application provides a method, apparatus, and device for controlling a virtual character to ride a vehicle through a gamepad, which is used to solve the problem of low operation efficiency of players for game control devices in the prior art.
[0004] In a first aspect, an embodiment of this application provides a method for controlling a virtual character to ride a vehicle through a gamepad. At least one trigger button is included on the front side of the gamepad. The method includes:
[0005] Responding to a movement control operation received through the gamepad, controlling the virtual character and the vehicle ridden by the virtual character to move together in a virtual environment in a forward-riding manner;
[0006] Responding to the trigger button being pressed and the rotation angle of the gamepad being greater than an angle threshold, controlling the virtual character and the vehicle ridden by the virtual character to switch from a forward-riding manner to a side-riding manner in the virtual environment.
[0007] Optionally, the forward-riding refers to the following riding manner: a straight line passing through the center of gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment passes through the vehicle.
[0008] Optionally, the forward-riding refers to the following riding manner: the center of gravity position of the virtual character in the virtual environment is higher than the connection position between the virtual character and the vehicle.
[0009] Optionally, the side-mounted riding refers to the following riding method: a straight line passing through the center-of-gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment does not pass through the vehicle.
[0010] Optionally, the side-mounted riding refers to the following riding method: the center-of-gravity position of the virtual character in the virtual environment is lower than the connection position between the virtual character and the vehicle.
[0011] Optionally, the method further includes:
[0012] Determining the orientation of side-mounted riding according to the rotation direction of the handle.
[0013] Optionally, the exposed area of the virtual character in the specified viewing direction in the upright riding mode is larger than that in the side-mounted riding mode, where the specified viewing direction is the viewing direction parallel to the horizontal plane of the virtual environment, perpendicular to the moving direction of the vehicle, and opposite to the orientation of side-mounted riding.
[0014] Optionally, the upper side of the handle includes a first joystick and a second joystick; the method further includes:
[0015] In response to a first pushing operation on the first joystick and a second pushing operation on the second joystick, controlling the vehicle to reduce its moving speed, where the first pushing operation is a pushing operation towards the second joystick, the second pushing operation is a pushing operation towards the first joystick, and the first pushing operation and the second pushing operation at least partially overlap in time sequence.
[0016] Optionally, the upper side of the handle includes a first joystick and a second joystick; the method further includes:
[0017] In response to a third pushing operation on the first joystick and a fourth pushing operation on the second joystick, controlling the vehicle to increase its moving speed or controlling the vehicle to perform a specific action to raise its center-of-gravity position, where the pushing directions of the third pushing operation and the fourth pushing operation are the same.
[0018] Optionally, the third pushing operation and the fourth pushing operation are perpendicular to the front side of the handle or the tangent plane of the front side; or, the third pushing operation and the fourth pushing operation are perpendicular to the connection line between the first joystick and the second joystick.
[0019] In a second aspect, an embodiment of the present application provides a method for controlling a virtual character to ride a vehicle through a handle. The front side of the handle includes at least one trigger button. The device includes:
[0020] The first response module is used to respond to the movement control operation received through the handle, and control the virtual character and the vehicle ridden by the virtual character to move together in the virtual environment in the upright riding manner.
[0021] The second response module is used to respond to the pressing of the trigger button and the rotation angle of the handle being greater than the angle threshold, and control the virtual character and the vehicle ridden by the virtual character to switch from the upright riding manner to the side riding manner in the virtual environment.
[0022] In a third aspect, an embodiment of the present application provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, the steps of the above method are implemented.
[0023] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored. When the computer program is run by a processor, the steps of the above method are executed.
[0024] The method for controlling a virtual character to ride a vehicle through a handle proposed in one embodiment of the present application first responds to the movement control operation received through the handle, and controls the virtual character and the vehicle ridden by the virtual character to move together in the virtual environment in the upright riding manner; finally, responds to the pressing of the trigger button and the rotation angle of the handle being greater than the angle threshold, and controls the virtual character and the vehicle ridden by the virtual character to switch from the upright riding manner to the side riding manner in the virtual environment.
[0025] In one embodiment of the present application, when a player controls the virtual character and the vehicle ridden by the virtual character to switch from the upright riding manner to the side riding manner through the handle, the player presses the trigger button to restore the virtual character to increase the contact area between the player and the vehicle, and increase the contact force between the player and the vehicle, and the player rotates the handle to restore the virtual character to ride from on the vehicle to on the side of the vehicle, so that the operation tendency of the player's operation on the handle is consistent with the action tendency of the virtual character to perform actions in the virtual environment, enabling the player to easily remember the operation rules of the handle, reducing the situation of operation errors, and improving the operation efficiency and accuracy of the player.
[0026] To make the above objects, features, and advantages of the present application more obvious and understandable, the following specific preferred embodiments are given, and in conjunction with the accompanying drawings, the detailed description is as follows. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] To more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the accompanying drawings required for the embodiments. It should be understood that the following drawings only show some embodiments of the present application and should not be regarded as limiting the scope. For those of ordinary skill in the art, without creative efforts, other related drawings can also be obtained based on these drawings.
[0028] Figure 1 Schematic flowchart of a method for controlling a virtual character to ride a vehicle through a handle according to one embodiment of the present application;
[0029] Figure 2 Schematic diagram of the handle structure according to one embodiment of the present application;
[0030] Figure 3 Schematic diagram of the standard state of the handle according to one embodiment of the present application;
[0031] Figure 4 Schematic diagram of the rotation state of the handle according to one embodiment of the present application;
[0032] Figure 5 Schematic diagram of the first upright riding mode according to one embodiment of the present application;
[0033] Figure 6 Schematic diagram of the second upright riding mode according to one embodiment of the present application;
[0034] Figure 7 Schematic diagram of the first sideway riding mode according to one embodiment of the present application;
[0035] Figure 8 Schematic diagram of the second sideway riding mode according to one embodiment of the present application;
[0036] Figure 9 Schematic diagram of the first joystick pushing operation according to one embodiment of the present application;
[0037] Figure 10 Schematic diagram of the deceleration action of the virtual character according to one embodiment of the present application;
[0038] Figure 11 Schematic diagram of the second joystick pushing operation according to one embodiment of the present application;
[0039] Figure 12 Schematic diagram of the first lifting action of the virtual character according to one embodiment of the present application;
[0040] Figure 13 Schematic diagram of the second lifting action of the virtual character according to one embodiment of the present application;
[0041] Figure 14 Schematic structural diagram of a device for controlling a virtual character to ride a vehicle through a handle provided in one embodiment of the present application;
[0042] Figure 15 Schematic structural diagram of a computer device provided in one embodiment of the present application. Specific embodiments
[0043] To make the objectives, technical solutions, and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, rather than all the embodiments. Usually, the components of the embodiments of the present application described and illustrated herein can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the present application claimed, but merely represents selected embodiments of the present application. All other embodiments obtained by those skilled in the art based on the embodiments of the present application without creative efforts fall within the scope of protection of the present application.
[0044] At the current stage, there has emerged a game method in which players complete game operations through a handle. The handle is connected to a terminal device in a wired or wireless manner. Players control a virtual character to perform corresponding actions in a virtual environment, and a game screen corresponding to the virtual environment including the virtual character is displayed in the graphical user interface of the terminal device. Sometimes in the virtual environment, the virtual character will ride a virtual vehicle to move or perform some actions in the virtual environment, which requires the handle to control both the virtual character and the virtual vehicle at the same time. At the current stage, the matching situation between each button on the handle and the control actions of the virtual character and / or the virtual vehicle is randomly set by each handle developer. For example, developer A will match the game screen of slowing down a horse with the X button or the RB button, and developer B will match the game screen of slowing down a horse with the L3 button. Players need to remember a lot of rules. If players do not remember the rules clearly, during the process of controlling the virtual character, it is very likely that there will be misoperations and untimely responses, resulting in low operation efficiency of the players.
[0045] Based on the above defects, one embodiment of the present application provides a method for controlling a virtual character to ride a vehicle through a handle, as Figure 1 shown, at least one trigger button is included on the front side of the handle, and the method includes:
[0046] S101, in response to a movement control operation received through the handle, controlling the virtual character and the vehicle ridden by the virtual character to move together in a virtual environment in a forward-riding manner;
[0047] S102. In response to the trigger button being pressed and the rotation angle of the handle being greater than the angle threshold, control the virtual character and the vehicle ridden by the virtual character to switch from the upright riding mode to the side riding mode in the virtual environment.
[0048] The handle provided in this application can be connected to the terminal device wirelessly or wiredly. A graphical user interface is provided in the terminal device so that the virtual character controlled by the handle and the vehicle ridden by the virtual character are displayed in the graphical user interface.
[0049] The method for controlling a virtual character to ride a vehicle by the handle in one embodiment of this application can run on the terminal device or the server. Among them, the terminal device can be a local terminal device. When the method for controlling a virtual character to ride a vehicle by the handle runs on the server, it can be a cloud game.
[0050] In an alternative embodiment, a cloud game refers to a game mode based on cloud computing. In the operation mode of a cloud game, the running entity of the game program and the entity presenting the game screen are separated. The storage and operation of the method for controlling a virtual character to ride a vehicle by the handle are completed on the cloud game server. The role of the terminal device is for data reception, transmission, and presentation of the game screen. For example, the terminal device can be a display device with data transmission function near the user side, such as a mobile terminal, a television, a computer, a handheld computer, etc.; however, the terminal device for game data processing is the cloud game server in the cloud. When playing the game, the player operates the game control device connected to the terminal device to send an operation instruction to the cloud game server. The cloud game server runs the game according to the operation instruction, encodes and compresses data such as the game screen, returns it to the terminal device through the network, and finally, the game screen is decoded and output through the terminal device.
[0051] In an alternative embodiment, the terminal device can be a local terminal device. The local terminal device stores the game program and is used to present the game screen. The local terminal device is used to interact with the player through the graphical user interface, that is, the game program is downloaded and installed on the electronic device and run conventionally. The way the local terminal device provides the graphical user interface to the player can include various methods. For example, it can be rendered and displayed on the display screen of the terminal device, or provided to the player through holographic projection. For example, the local terminal device can include a display screen and a processor. The display screen is used to present the graphical user interface, which includes a part of the virtual environment. The processor is used to run the game, generate the graphical user interface, and control the display of the graphical user interface on the display screen.
[0052] The game of this application includes a virtual environment, a virtual character located in the virtual environment and controlled by a player through a gamepad, and a vehicle ridden by the virtual character. The vehicle can be a virtual horse. The terminal device or cloud game can respond to the control of the gamepad for the virtual character and the vehicle ridden by the virtual character, so that the virtual character and the vehicle ridden by the virtual character perform virtual actions in the virtual environment, such as moving in the virtual environment or releasing skills. The virtual environment can include any one or more of the following game elements: terrain, mountains, rocks, flowers, plants, rivers, buildings, virtual objects, game props, vehicles, etc. Generally, a virtual camera is set in the virtual environment, and the game screen displayed on the graphical user interface is part of the virtual environment content captured by the virtual camera. For example, in a first-person game, the virtual camera can be set at the head (such as the eye position) of the virtual character controlled by the player. The virtual camera moves with the movement of the virtual character, and the orientation of the virtual camera rotates with the rotation of the virtual character. Therefore, the game screen presented on the graphical user interface is part of the virtual environment within a preset range in front of the virtual character. Another example is that in a third-person game, the virtual camera can be set directly above or above and behind the virtual character controlled by the player. Therefore, the game screen presented on the graphical user interface is part of the virtual environment including the virtual character. If an account of the virtual character is logged in on the terminal device or cloud game, the virtual character is controlled by the terminal device or cloud game. A virtual character refers to a dynamic object that can be controlled in the virtual environment. Optionally, the dynamic object can be a virtual person, a virtual animal, an anime character, etc. The virtual character is a character controlled by the player through the terminal device, or an artificial intelligence (AI) set in the virtual environment battle through training, or a non-player character (NPC) set in the virtual environment battle. Optionally, the virtual character is a virtual person competing in the virtual environment.
[0053] In order to enable players to complete more game operations, more physical buttons will be integrated on the gamepad, such as Figure 2As shown, this is a game controller. The game controller includes at least two trigger buttons and two joysticks, and is generally divided into two regions (a left region and a right region) in the game controller. The two trigger buttons are respectively arranged in the left region and the right region, and both trigger buttons are arranged at the front side of the controller. Among them, the left trigger button 10 is arranged at the front side of the left region, and the right trigger button 20 is arranged at the front side of the right region. The front side of the controller is the side that is perpendicular to the horizontal plane, perpendicular to the player's orientation, and away from the player in the controller. The two trigger buttons can control the virtual character to perform pulling or boosting actions in the virtual environment. The two joysticks are respectively arranged in the left region and the right region. Among them, the left joystick 30 is arranged at the upper side of the left region. The upper side in the controller is the side that is parallel to the horizontal plane and is provided with at least one physical button and at least one joystick. The right joystick 40 is arranged at the upper side position of the right region. One of the two joystick buttons can be used to control the movement of the virtual character in the virtual environment, and the other can be used to control the viewing direction of the virtual camera (the specific setting method can be determined according to the actual situation). And a gravity sensing device is also arranged inside the controller. The gravity sensing device can detect the rotation angle of the controller used by the player relative to the standard state of the controller. For example, Figure 3 As shown, the standard state of the controller is the state where the controller is parallel to the horizontal plane. The player controls the rotation of the controller. For example, as Figure 4 shown, if the controller rotates 45° relative to the horizontal plane, the gravity detection device in the controller can detect the rotation angle of the controller. The right region of the controller also includes a triangle button (△), a square button (□), a cross button (×), and a circle button (○). Among them, each button in the right region corresponds to a different function. For example, the triangle button can control the virtual character to get on a vehicle in the virtual environment, and can also control the virtual character to get off the vehicle; the square button can control the virtual character to perform a jumping action in the virtual environment; the cross button can control the virtual character to run in the virtual environment, or can control the virtual character to run in the virtual environment while riding a vehicle; the circle button can control the virtual character to perform a hitting action in the virtual environment. The left region of the controller also includes direction buttons pointing to four directions respectively. The function corresponding to each direction button can be set according to the actual situation.
[0054] S101, in response to a movement control operation received through the controller, control the virtual character and the vehicle ridden by the virtual character to move together in the virtual environment in a straddling manner.
[0055] In the above step S101, the movement control operation is an operation performed by the player on the movement control in the handle. Here, the movement control is a control for jointly controlling the virtual character and the vehicle ridden by the virtual character to move in the virtual environment. The movement control can be a certain joystick in the handle. In the virtual environment of the present application, there are a virtual character and a vehicle ridden by the virtual character. In some scenarios, the virtual character does not need to ride the vehicle (that is, the virtual character moves alone in the virtual environment), while in other scenarios, the virtual character needs to ride the vehicle (that is, the virtual character and the vehicle ridden by the virtual character move together in the virtual environment). Therefore, the movement control operation includes two control methods: First, when the virtual character does not ride the vehicle, the movement control operation only controls the virtual character to move in the virtual environment. Second, when the virtual character rides the vehicle, the movement control operation controls the virtual character and the vehicle ridden by the virtual character to move together in the virtual environment. The present application describes in detail the scenario where the virtual character rides the vehicle. The vehicle ridden by the virtual character refers to a virtual object that can carry the virtual character to move in the virtual environment, such as a virtual horse, a virtual dragon, a virtual mechanical vehicle, etc.
[0056] When the virtual character rides a vehicle in the virtual environment, the riding method of the virtual character may include the following methods: riding upright and riding sideways.
[0057] As Figure 5 and Figure 6 shown, the method of riding upright is shown from different observation directions. Figure 5 is the method of riding upright observed in the observation direction parallel to the horizontal plane of the virtual environment and parallel to the moving direction of the vehicle. Figure 6 is the method of riding upright observed in the observation direction parallel to the horizontal plane of the virtual environment and perpendicular to the moving direction of the vehicle. As Figure 5 and Figure 6 shown, riding upright means that the straight line passing through the center of gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment passes through the vehicle. The center of gravity position of the virtual character in the virtual environment is higher than the connection position between the virtual character and the vehicle. The connection position between the virtual character and the vehicle can be the position where the virtual character contacts the vehicle when riding the vehicle and can support the virtual character to ride on the vehicle.
[0058] As Figure 7 and Figure 8 shown, the method of riding sideways is shown from different observation directions, where Figure 7 is the method of riding sideways observed in the observation direction parallel to the horizontal plane of the virtual environment and parallel to the moving direction of the vehicle. Figure 8It is a side-mounted riding mode observed in the viewing direction parallel to the horizontal plane of the virtual environment and perpendicular to the moving direction of the vehicle. As Figure 7 and Figure 8 shown, side-mounted riding refers to the following riding mode: the straight line passing through the center-of-gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment does not pass through the vehicle, and the center-of-gravity position of the virtual character in the virtual environment is lower than the hitch position of the virtual character and the vehicle.
[0059] In specific implementation, there are two riding modes for the virtual character to ride the vehicle: upright riding and side-mounted riding. In response to the player's movement control operation on the handle, if the handle is in the standard state at this time, the handle will generate a first movement control signal, and the first movement control signal is used to control the virtual character and the vehicle ridden by the virtual character to move together in the virtual environment in the upright riding mode. That is, the handle sends the first movement control signal to the terminal device, and the terminal device controls the virtual character and the vehicle ridden by the virtual character in the virtual environment to move in the upright riding mode according to the received first movement control signal, and the terminal device will update and display the game screen of the virtual character and the vehicle ridden by the virtual character moving in the upright riding mode in the graphical user interface.
[0060] S102, in response to the trigger button being pressed and the rotation angle of the handle being greater than the angle threshold, control the virtual character and the vehicle ridden by the virtual character to switch from the upright riding mode to the side-mounted riding mode in the virtual environment.
[0061] In the above step S102, in some scenarios (for example, the player wants to control the virtual character riding the vehicle to avoid an attack, the player wants to control the virtual character riding the vehicle to pick up something, etc.), the virtual character riding on the vehicle needs to switch from the upright riding mode to the side-mounted riding mode, and the switching of the riding mode of the virtual character needs to be controlled by the player through the handle. When the virtual character rides side-mounted in the game environment, affected by the gravity factor in the virtual environment, the virtual character is easily thrown off the vehicle. Therefore, for safety reasons, the virtual character needs to increase the contact area between itself and the vehicle, and increase the contact force between itself and the vehicle (for example, the virtual character hugs the neck of the virtual horse to increase the contact area between itself and the virtual horse, and increase the contact force between itself and the virtual horse). By pressing the trigger button on the handle by the player, the virtual character is controlled to perform a pulling or boosting action in the virtual environment, so that the virtual character in the virtual environment increases the contact area between itself and the vehicle, and the action of increasing the contact force between itself and the vehicle.
[0062] In a virtual environment, switching from a straddle riding mode to a side-saddle riding mode can be manifested as the virtual character changing from riding on the vehicle to riding on the side of the vehicle. To restore the action of switching the riding mode, the player rotates the handle to restore the action of switching the riding mode.
[0063] The angle threshold is pre-set by the system. For example, the angle threshold is 45°. During the game, the player holds the handle to control the virtual character and the vehicle ridden by the virtual character. During the operation of the handle, due to the different operating forces and operating methods of the two hands, the handle may experience some slight jitters and cannot always be in a standard state. Therefore, to reduce the misoperation caused by the jitters during the user's operation, the angle threshold is set to accurately control the virtual character to complete the side-saddle riding action.
[0064] In a specific implementation, in the side-saddle riding mode, the virtual character must increase the contact area and contact force between itself and the vehicle, and the virtual character also needs to perform the riding action on the side of the vehicle. To make the action performed by the player closer to the action performed by the virtual character, when the player presses the trigger button and the rotation angle of the handle is greater than the angle threshold, the virtual character and the vehicle ridden by the virtual character in the virtual environment will be controlled to switch from the straddle riding mode to the side-saddle riding mode. Specifically, in response to the trigger button being pressed and the rotation angle of the handle being greater than the angle threshold, the handle will generate a hugging signal corresponding to the trigger button being pressed and a side-turn signal corresponding to the rotation angle of the handle being greater than the angle threshold. The handle sends the hugging signal and the side-turn signal to the terminal device, and the terminal device controls the virtual character and the vehicle ridden by the virtual character in the virtual environment to switch from the straddle riding mode to the side-saddle riding mode according to the hugging signal and the side-turn signal, and displays in the graphical user interface of the terminal device the game screen of the virtual character and the vehicle of the virtual character switching from the straddle riding mode to the side-saddle riding mode.
[0065] In the above step S102, only the switching of the riding mode of the virtual character and the vehicle ridden by the virtual character is controlled, but the movement of the virtual character and the vehicle ridden by the virtual character in the virtual environment is still controlled by the movement control operation received by the handle. If the movement control operation has not terminated, during the process of the virtual character and the vehicle ridden by the virtual character moving together in the virtual environment, in response to the trigger button being pressed and the rotation angle of the handle being greater than the angle threshold, the virtual character and the vehicle ridden by the virtual character in the virtual environment will be controlled to switch from the straddle riding mode to the side-saddle riding mode.
[0066] Sideways riding can include two orientations: the left orientation relative to the orientation of the vehicle (i.e., left-side riding) and the right orientation relative to the orientation of the vehicle (i.e., right-side riding). Riding sideways to the left means that when taking the orientation of the vehicle as the reference object, the virtual character performs the action of riding sideways on the left side of the vehicle. Riding sideways to the right means that when taking the orientation of the vehicle as the reference object, the virtual character performs the action of riding sideways on the right side of the vehicle.
[0067] In this application, the virtual character and the vehicle ridden by the virtual character in the virtual environment are controlled by a handle. Therefore, the orientation of the virtual character's sideways riding is determined according to the rotation direction of the handle. That is, when the player controls the handle to rotate to the left relative to the standard state of the handle, the virtual character performs left-side riding in the virtual environment; when the player controls the handle to rotate to the right relative to the standard state of the handle, the virtual character performs right-side riding in the virtual environment.
[0068] Specifically, in order to more easily distinguish between upright riding and sideways riding in the virtual environment, the exposed areas of upright riding and sideways riding in the specified viewing direction are different. That is, the exposed area of the virtual character in the specified viewing direction in the upright riding mode is larger than that in the sideways riding mode. Here, the specified viewing direction is the viewing direction parallel to the horizontal plane of the virtual environment, perpendicular to the moving direction of the vehicle, and in the opposite direction to the orientation of the sideways riding. For example, when the virtual character is riding the vehicle in the right-side riding mode, at this time the virtual character is located on the right side of the vehicle, then the specified viewing direction is the direction parallel to the horizontal plane of the virtual environment, perpendicular to the moving direction of the vehicle, and located on the left side of the vehicle. When the virtual character is located on the right side of the vehicle and performs the right-side riding action, the exposed area of the virtual character observed from the left side of the vehicle (when the virtual character is located on the right side of the vehicle and performs the right-side riding action, most of the virtual character's body is blocked by the vehicle when observed from the left side of the vehicle) is smaller than the exposed area of the virtual character performing the upright riding action observed from the left side of the vehicle (when the virtual character performs the upright riding action, whether observed from the left side or the right side of the vehicle, most of the virtual character's body is not blocked).
[0069] In one embodiment of the present application, when the player controls the virtual character and the vehicle ridden by the virtual character to switch from the front-riding mode to the side-riding mode through the handle, the player presses the trigger button to restore the virtual character to increase the contact area between himself and the vehicle, as well as increase the contact force between himself and the vehicle, and the player rotates the handle to restore the virtual character to ride on the side of the vehicle from riding on the vehicle, so that the operation tendency of the player's handle operation is consistent with the action tendency of the virtual character performing actions in the virtual environment, enabling the player to easily remember the operation rules of the handle, reducing the situation of operation errors, and improving the operation efficiency and accuracy of the player.
[0070] After performing the above step S102, the virtual character and the vehicle ridden by the virtual character move in the virtual environment in a side-riding mode, but the player still needs to control the virtual character and the vehicle ridden by the virtual character to complete more tasks (for example, when shooting, the virtual character needs to perform the shooting action in the front-riding mode). The virtual character cannot always maintain the side-riding mode and still needs to be restored to the front-riding mode to complete more tasks. Therefore, the present application also provides another embodiment, and the method further includes:
[0071] Step 103, in response to the trigger button being released and the rotation angle of the handle being less than or equal to the angle threshold, control the virtual character and the vehicle ridden by the virtual character to switch from the side-riding mode to the front-riding mode in the virtual environment.
[0072] In the above step 103, when the player releases the trigger button and adjusts the rotation angle of the handle to be less than the angle threshold, the player wants to control the virtual character to switch from side-riding to front-riding. Specifically, in response to the trigger button being released and the rotation angle of the handle being less than or equal to the angle threshold, the handle generates a release signal corresponding to the release of the trigger button, and generates a first restoration signal corresponding to the rotation angle of the handle being less than or equal to the angle threshold. The handle sends the release signal and the first restoration signal to the terminal device, and the terminal device controls the virtual character and the vehicle ridden by the virtual character in the virtual environment to switch from the side-riding mode to the front-riding mode according to the release signal and the first restoration signal, and displays a game screen in which the virtual character and the vehicle of the virtual character switch from the side-riding mode to the front-riding mode in the graphical user interface of the terminal device.
[0073] Two joysticks are further provided on the upper side of the handle, namely the first joystick and the second joystick. In addition to controlling the movement of the virtual character and the vehicle ridden by the virtual character in the virtual environment, and controlling the orientation of the virtual camera in the virtual environment, the joysticks in the handle can also control the vehicle to perform corresponding actions. The method provided by the present application further includes:
[0074] Step 104, in response to a first pushing operation on the first joystick and a second pushing operation on the second joystick, control the vehicle to reduce its moving speed, where the first pushing operation is a pushing operation towards the second joystick, the second pushing operation is a pushing operation towards the first joystick, and the first pushing operation and the second pushing operation at least partially overlap in time sequence.
[0075] In the above Step 104, the first pushing operation is an operation on the first joystick, and the second pushing operation is an operation on the second joystick. The first pushing operation is a pushing operation towards the second joystick, and the second pushing operation is a pushing operation towards the first joystick. Equivalently, as Figure 9 shown, the operation directions of the first pushing operation and the second pushing operation are approaching each other. The fact that the first pushing operation and the second pushing operation at least partially overlap in time sequence means that there is a partial time period during the operation process when the operation times of the first pushing operation and the second pushing operation overlap. For example, the start time of the first pushing operation is 08:38:15.023 milliseconds in the morning, the end time of the first pushing operation is 08:38:16.002 milliseconds in the morning, the start time of the second pushing operation is 08:38:15.040 milliseconds in the morning, and the end time of the second pushing operation is 08:38:16.010 milliseconds in the morning. Then the overlapping time of the first pushing operation and the second pushing operation is between 08:38:15.040 milliseconds and 08:38:16.002 milliseconds in the morning.
[0076] In a specific implementation, in response to a first pushing operation on the first joystick and a second pushing operation on the second joystick, the handle generates a speed reduction control signal. The speed reduction control signal is used to control the vehicle ridden by the virtual character to slow down slowly in the virtual environment. The handle sends the speed reduction control signal to the terminal device. The terminal device controls the vehicle ridden by the virtual character to slow down slowly in the virtual environment according to the received speed reduction control signal, and the terminal device updates and displays the game screen of the vehicle ridden by the virtual character slowing down slowly in the virtual environment on the graphical user interface.
[0077] Based on the game screen displayed on the graphical user interface of the terminal device, it can be observed that the virtual character rides the vehicle. Equivalently, it is the virtual character that controls the vehicle it rides. Of course, this is only the form shown in the game screen and is only used to restore the actions performed when a person rides a vehicle in the display scene. Through this restoration of the game screen, the immersion and experience of the player in the game can be improved. Therefore, while the player controls the vehicle to slow down through the joystick in the handle, it is also equivalent to controlling the virtual character through the joystick in the handle, so that the virtual character controls the vehicle to slow down. Specifically, Step 104 includes:
[0078] Step 1041: In response to a first pushing operation on the first joystick and a second pushing operation on the second joystick, control the virtual character to perform a speed reduction action and control the vehicle to reduce its moving speed.
[0079] In the above step 1041, the speed reduction action is an action performed by the virtual character while the player controls the vehicle to reduce its moving speed. For example, as Figure 10 shown, the legs of the virtual character move closer to the vehicle and clamp the vehicle.
[0080] In a specific implementation, in response to a first pushing operation on the first joystick and a second pushing operation on the second joystick, the handle generates a speed reduction control signal. The speed reduction control signal is used to control the virtual character to perform a speed reduction action in the virtual environment and control the vehicle ridden by the virtual character to slow down gradually. The handle sends the speed reduction control signal to the terminal device. The terminal device controls the virtual character to perform a speed reduction action in the virtual environment according to the received speed reduction control signal and controls the vehicle ridden by the virtual character to slow down gradually in the virtual environment. Moreover, the terminal device updates and displays the game screen in which the virtual character performs a speed reduction action in the virtual environment and controls the vehicle ridden by the virtual character to slow down gradually in the graphical user interface.
[0081] After executing 104, the virtual character and the vehicle ridden by the virtual character cannot keep moving at a reduced speed all the time. Sometimes, in order to avoid the attack of enemies or look for teammates, etc., the vehicle ridden by the virtual character still needs to increase its moving speed or perform other actions. Therefore, it is necessary to control the vehicle to end the speed reduction. There are several ways to control the vehicle to end the speed reduction:
[0082] Step 1042: In response to the restoration of the first joystick and the second joystick, control the vehicle to end the speed reduction; or,
[0083] Step 1043: Control the vehicle to reduce its moving speed to a first preset moving speed and then control the vehicle to end the speed reduction; or,
[0084] Step 1044: Control the vehicle to reduce its moving speed for a first preset duration and then control the vehicle to end the speed reduction.
[0085] In the above step 1042, the restoration of the first joystick and the second joystick refers to that the first joystick and the second joystick automatically return to their original positions (the positions where the joysticks are located when the player does not touch the joysticks), or the player controls the first joystick and the second joystick to return to their original positions.
[0086] In the above step 1043, the first preset moving speed is automatically set by the system. Step 1043 means that after the moving speed of the vehicle reaches the first preset moving speed, the moving speed of the vehicle will not continue to decrease. For example, the first preset moving speed is 0.
[0087] In the above step 1044, the first preset duration is automatically set by the system. Step 1044 means that when the deceleration duration of the vehicle since the start of reducing the moving speed reaches the first preset duration, the vehicle will no longer continue to decelerate. For example, the first preset duration can be 10 seconds.
[0088] Two joysticks are provided on the upper side of the handle, namely the first joystick and the second joystick. In addition to being able to control the movement of the virtual character and the vehicle ridden by the virtual character in the virtual environment, the joysticks in the handle can control the orientation of the virtual camera in the virtual environment, and in addition to being able to control the vehicle to perform the reduction of the moving speed described in the above step 104, they can also control the vehicle to increase the moving speed or perform specific actions. The method provided in this application further includes:
[0089] Step 105, in response to a third pushing operation acting on the first joystick and a fourth pushing operation acting on the second joystick, control the vehicle to increase its moving speed or control the vehicle to perform a specific action to raise its center of gravity position, where the pushing directions of the third pushing operation and the fourth pushing operation are the same.
[0090] In the above step 105, the third pushing operation is an operation acting on the first joystick, and the fourth pushing operation is an operation acting on the second joystick. The pushing directions of the third pushing operation and the fourth pushing operation are the same, and the third pushing operation and the fourth pushing operation are perpendicular to the front side of the handle or the tangent plane of the front side; or, as Figure 11 shown, the third pushing operation and the fourth pushing operation are perpendicular to the connection line between the first joystick and the second joystick (generally, the operation directions of the third pushing operation and the fourth pushing operation are the directions away from the front side of the handle). The third pushing operation and the fourth pushing operation at least partially overlap in time sequence, which means that the operation times of the third pushing operation and the fourth pushing operation overlap partially during the operation process. For example, the start time of the third pushing operation is 023 milliseconds at 9:10:15 am, the end time of the third pushing operation is 002 milliseconds at 9:10:16 am, the start time of the fourth pushing operation is 040 milliseconds at 9:10:10 am, and the end time of the fourth pushing operation is 010 milliseconds at 9:10:16 am. Then the overlapping time of the third pushing operation and the fourth pushing operation is between 040 milliseconds at 9:10:15 am and 002 milliseconds at 9:10:16 am.
[0091] In specific implementation, in response to a third pushing operation on the first joystick and a fourth pushing operation on the second joystick, the handle will generate an acceleration control signal or a specific control signal. The acceleration control signal is used to control the vehicle ridden by the virtual character to increase its moving speed in the virtual environment, and the specific control signal is used to control the vehicle ridden by the virtual character to perform a specific action in the virtual environment to raise its center of gravity. Wherein, the center of gravity position of the vehicle when performing the specific action is higher than the center of gravity position of the vehicle when performing a non-specific action. The handle sends the acceleration control signal or the specific control signal to the terminal device, and the terminal device controls the vehicle ridden by the virtual character to increase its moving speed or perform a specific action in the virtual environment according to the received acceleration control signal or specific control signal. And the terminal device will update and display the game screen of the vehicle ridden by the virtual character increasing its moving speed or performing a specific action in the virtual environment in the graphical user interface.
[0092] Based on the game screen shown on the graphical user interface of the terminal device, it can be observed that the virtual character rides a vehicle. That is to say, it is the virtual character that controls the vehicle it rides. Of course, this is only the form shown in the game screen, which is only used to restore and display the actions performed when a character rides a vehicle in the scene. Through the restoration of this game screen, the immersion and experience of the player in the game can be improved. Therefore, while the player controls the vehicle to increase its moving speed or control the vehicle to perform a specific action to raise its center of gravity through the joystick in the handle, it is also equivalent to controlling the virtual character through the joystick in the handle to achieve the control of the vehicle by the virtual character in the virtual environment. Specifically, step 105 includes:
[0093] Step 1051, in response to a third pushing operation on the first joystick and a fourth pushing operation on the second joystick, control the virtual character to perform a lifting action, and control the lifting moving speed of the vehicle or control the vehicle to perform a specific action to raise its center of gravity.
[0094] In the above step 1051, the lifting action is the action performed by the virtual character while the player controls the vehicle to increase its moving speed or control the vehicle to perform a specific action to raise its center of gravity. For example, as Figure 12 shown, the virtual character tightens the reins of the vehicle to control the vehicle to increase its moving speed. Or, as Figure 13 shown, the virtual character tightens the reins of the vehicle to control the vehicle to perform a specific action (jumping action) to raise its center of gravity.
[0095] In specific implementation, in response to a third pushing operation on the first joystick and a fourth pushing operation on the second joystick, the handle will generate an acceleration control signal or a specific control signal. The handle will send the acceleration control signal or the specific control signal to the terminal device. The terminal device controls the vehicle ridden by the virtual character to increase the moving speed or perform a specific action in the virtual environment according to the received acceleration control signal or specific control signal, and controls the virtual character to perform a lifting action. Moreover, the terminal device will update and display the game screen of the vehicle ridden by the virtual character increasing the moving speed or performing a specific action, and the virtual character performing the lifting action in the graphical user interface.
[0096] The player controls the vehicle in the virtual environment to increase the moving speed, which may be to chase or avoid enemies. And the player controls the vehicle in the virtual environment to perform a specific action to raise the center of gravity position, which may be to cross obstacles or traps. Therefore, when responding to the third pushing operation on the first joystick and the fourth pushing operation on the second joystick, the action performed by the vehicle can be determined according to the scene information of the virtual environment. That is, step 105 of the method provided in this application includes:
[0097] Step 1052, in response to the third pushing operation on the first joystick and the fourth pushing operation on the second joystick, control the vehicle to perform an action corresponding to the environment information according to the environment information of the virtual environment;
[0098] Controlling the vehicle to perform an action corresponding to the environment information according to the environment information of the virtual environment includes:
[0099] Step 10521, if the environment information indicates a flat road condition, control the vehicle to increase the moving speed;
[0100] Step 10522, if the environment information indicates a rough road condition, control the vehicle to perform a specific action to raise its center of gravity position.
[0101] Specifically, in step 1052 and steps 10521 and 10522 that reference step 1052, in response to the third push operation on the first joystick and the fourth push operation on the second joystick, environmental information of the virtual environment is obtained. If the environmental information indicates a flat road, that is, the road traveled by the vehicle ridden by the virtual character in the virtual environment is relatively flat and free of obstacles or traps, then the player intends to control the vehicle to increase its speed on the road. If the environmental information indicates a dangerous prop, then the road traveled by the vehicle ridden by the virtual character in the virtual environment has obstacles or traps, indicating that the player intends to control the vehicle to cross the obstacles or traps on the road. Therefore, the player will control the vehicle to perform a specific action to increase its center of gravity.
[0102] After executing step 105, the avatar and the vehicle it rides cannot continue to increase its movement speed. Sometimes, in order to avoid enemy attacks, find teammates, or attack enemies, the vehicle it rides may need to slow down or perform other actions. Therefore, it is necessary to control the vehicle to stop increasing its movement speed. There are several ways to control the vehicle to stop increasing its movement speed:
[0103] Step 1053, in response to the restoration of the first joystick and the second joystick, controlling the vehicle to stop increasing the moving speed; or,
[0104] Step 1054, controlling the vehicle to increase the moving speed to a second preset moving speed, and controlling the vehicle to stop increasing the moving speed; or,
[0105] Step 1055, controlling the vehicle to increase its moving speed until the time reaches a preset duration, and controlling the vehicle to stop increasing its moving speed.
[0106] In the above step 1053, the restoration of the first joystick and the second joystick refers to the first joystick and the second joystick automatically restoring to their original positions (the positions of the joysticks when the player does not touch the joysticks), or the player controlling the first joystick and the second joystick to restore to their original positions.
[0107] In the above step 1054, the second preset moving speed is automatically set by the system. Step 1043 means that after the moving speed of the vehicle reaches the second preset moving speed, the moving speed of the vehicle will not continue to increase. For example, the second preset moving speed is 20m / s.
[0108] In step 1055, the second preset time period is automatically set by the system. Step 1055 means that once the vehicle's speed increases after it starts to increase, the vehicle will not continue to increase its speed. For example, the second preset time period may be 10 seconds.
[0109] After the execution of 105, the vehicle ridden by the virtual character will raise the center of gravity position. However, affected by the gravity factor in the virtual environment, the center of gravity position of the vehicle ridden by the virtual character will automatically stop rising when it reaches a certain height. Therefore, in response to the center of gravity position of the vehicle reaching the preset height, the control of the vehicle to perform a specific action is stopped.
[0110] In the above method of controlling a virtual character to ride a vehicle through a handle, step 104, and steps 1041 to 1044 that refer to step 104 can rely on the above method of controlling a virtual character to ride a vehicle through a handle, or can be a complete embodiment alone without relying on the above method. Additionally, when it is a separate embodiment, the features in the embodiment are the same as those in the above method, and will not be elaborated here. Similarly, in the method of controlling a virtual character to ride a vehicle through a handle, step 105, and steps 1051 to 1055 that refer to step 105 can rely on the above method of controlling a virtual character to ride a vehicle through a handle, or can be a complete embodiment alone without relying on the above method. Additionally, when it is a separate embodiment, the features in the embodiment are the same as those in the above method, and will not be elaborated here.
[0111] Specifically, steps S101 to 105 and the refined features related to the above steps S101 to 105 can be used as one embodiment of the present application (such as Embodiment 1). And in the above method of controlling a virtual character to ride a vehicle through a handle, step 104, and steps 1041 to 1044 that refer to step 104 can rely on the above method of controlling a virtual character to ride a vehicle through a handle, and can be used as another embodiment of the present application (such as Embodiment 2). When it is a separate embodiment (i.e., Embodiment 2), the specific content of the virtual device, computer device, and storage medium corresponding to this Embodiment 2 is similar to the writing of the virtual device, computer device, and storage medium in the following Embodiment 1, and will not be repeated here. In the above method of controlling a virtual character to ride a vehicle through a handle, step 105, and steps 1051 to 1055 that refer to step 105 can rely on the above method of controlling a virtual character to ride a vehicle through a handle, and can be used as another embodiment of the present application (such as Embodiment 3). When it is a separate embodiment (i.e., Embodiment 3), the specific content of the virtual device, computer device, and storage medium corresponding to this Embodiment 3 is similar to the writing of the virtual device, computer device, and storage medium in the following Embodiment 1, and will not be repeated here.
[0112] One embodiment of the present application provides a device for controlling a virtual character to ride a vehicle through a handle, as Figure 14 shown, at least one trigger button is included on the front side of the handle, and the device includes:
[0113] The first response module 1401 is configured to respond to a movement control operation received through the handle, and control the virtual character and the vehicle ridden by the virtual character to move together in a virtual environment in a upright riding manner;
[0114] The second response module 1042 is configured to respond to the trigger button being pressed and the rotation angle of the handle being greater than the angle threshold, and control the virtual character and the vehicle ridden by the virtual character to switch from the upright riding manner to the side riding manner in the virtual environment.
[0115] Optionally, the upright riding refers to the following riding manner: a straight line passing through the center of gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment passes through the vehicle.
[0116] Optionally, the upright riding refers to the following riding manner: the center of gravity position of the virtual character in the virtual environment is higher than the connection position between the virtual character and the vehicle.
[0117] Optionally, the side riding refers to the following riding manner: a straight line passing through the center of gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment does not pass through the vehicle.
[0118] Optionally, the side riding refers to the following riding manner: the center of gravity position of the virtual character in the virtual environment is lower than the connection position between the virtual character and the vehicle.
[0119] Optionally, the control device further includes:
[0120] A determination module, configured to determine the orientation of the side riding according to the rotation direction of the handle.
[0121] Optionally, the exposed area of the virtual character in the upright riding manner in the specified viewing direction is greater than the exposed area of the virtual character in the side riding manner in the specified viewing direction, where the specified viewing direction is the viewing direction parallel to the horizontal plane of the virtual environment, perpendicular to the moving direction of the vehicle, and opposite to the orientation of the side riding.
[0122] Optionally, the upper side of the handle includes a first joystick and a second joystick; the device further includes:
[0123] A third response module, configured to respond to a first pushing operation acting on the first joystick and a second pushing operation acting on the second joystick, and control the vehicle to reduce the moving speed, where the first pushing operation is a pushing operation towards the second joystick, the second pushing operation is a pushing operation towards the first joystick, and the first pushing operation and the second pushing operation at least partially overlap in time sequence.
[0124] Optionally, the upper side of the handle includes a first rocker and a second rocker; and the method further includes:
[0125] A fourth response module is used to respond to a third pushing operation acting on the first rocker and a fourth pushing operation acting on the second rocker to control the lifting movement speed of the vehicle or control the vehicle to perform a specific action to increase its center of gravity position, wherein the pushing directions of the third pushing operation and the fourth pushing operation are the same.
[0126] Optionally, the third pushing operation and the fourth pushing operation are perpendicular to the front side of the handle or a cross-section of the front side; or, the third pushing operation and the fourth pushing operation are perpendicular to a line connecting the first rocker and the second rocker.
[0127] Corresponds to Figure 1 In the method of controlling a virtual character to ride a vehicle through a handle, one embodiment of the present application further provides a computer device 1500, such as Figure 15 As shown, the device includes a memory 1501, a processor 1502, and a computer program stored in the memory 1501 and executable on the processor 1502. The processor 1502 executes a method for controlling a virtual character to ride a vehicle through a handle provided in one embodiment of the present application, the method comprising:
[0128] In response to a movement control operation received through the handle, controlling the virtual character and the vehicle ridden by the virtual character to move together in a virtual environment in a manner of riding the virtual character;
[0129] In response to the trigger button being pressed and the rotation angle of the handle being greater than an angle threshold, the virtual character and the vehicle ridden by the virtual character are controlled to switch from a frontal riding mode to a sideways riding mode in the virtual environment.
[0130] Optionally, the upright riding refers to the following riding method: a straight line passing through the center of gravity of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment passes through the vehicle.
[0131] Optionally, the upright riding refers to the following riding method: the center of gravity of the virtual character in the virtual environment is higher than the connection position between the virtual character and the vehicle.
[0132] Optionally, the sideways riding refers to the following riding method: a straight line passing through the center of gravity of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment does not pass through the vehicle.
[0133] Optionally, the side-mounted riding refers to the following riding mode: the center of gravity position of the virtual character in the virtual environment is lower than the hitch position of the virtual character and the vehicle.
[0134] Optionally, the method further includes:
[0135] Determining the orientation of the side-mounted riding according to the rotation direction of the handle.
[0136] Optionally, the exposed area of the virtual character in the specified viewing direction in the upright riding mode is larger than that in the side-mounted riding mode, where the specified viewing direction is the viewing direction parallel to the horizontal plane of the virtual environment, perpendicular to the moving direction of the vehicle, and in the opposite direction of the orientation of the side-mounted riding.
[0137] Optionally, the upper side of the handle includes a first joystick and a second joystick; the method further includes:
[0138] In response to a first pushing operation acting on the first joystick and a second pushing operation acting on the second joystick, controlling the vehicle to reduce its moving speed, where the first pushing operation is a pushing operation towards the second joystick, the second pushing operation is a pushing operation towards the first joystick, and the first pushing operation and the second pushing operation at least partially overlap in time sequence.
[0139] Optionally, the upper side of the handle includes a first joystick and a second joystick; the method further includes:
[0140] In response to a third pushing operation acting on the first joystick and a fourth pushing operation acting on the second joystick, controlling the vehicle to increase its moving speed or controlling the vehicle to perform a specific action to raise its center of gravity position, where the pushing directions of the third pushing operation and the fourth pushing operation are the same.
[0141] Optionally, the third pushing operation and the fourth pushing operation are perpendicular to the front side of the handle or the tangent plane of the front side; or, the third pushing operation and the fourth pushing operation are perpendicular to the connection line between the first joystick and the second joystick.
[0142] Specifically, the above-mentioned memory 1501 and processor 1502 can be general memories and processors, which are not specifically limited here. When the processor 1502 runs the computer program stored in the memory 1501, it can execute the method of controlling a virtual character to ride a vehicle through a handle, solving the problem of low operation efficiency of game control devices in the prior art. Moreover, when the player in this application switches the virtual character and the vehicle ridden by the virtual character from the upright riding mode to the side riding mode through the handle, the player presses the trigger button to restore the virtual character to increase the contact area between himself and the vehicle, and increase the contact force between himself and the vehicle. And the player rotates the handle to restore the virtual character from riding on the vehicle to riding on the side of the vehicle, so that the operation tendency of the player's handle operation is consistent with the action tendency of the virtual character performing actions in the virtual environment, enabling the player to easily remember the operation rules of the handle, reducing the situation of operation errors, and improving the player's operation efficiency and accuracy.
[0143] Corresponding to Figure 1 For the method of controlling a virtual character to ride a vehicle through a handle in [reference], one embodiment of the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is run by a processor, it executes the method of controlling a virtual character to ride a vehicle through a handle. The method includes:
[0144] Responding to a movement control operation received through the handle, controlling the virtual character and the vehicle ridden by the virtual character to move together in the virtual environment in an upright riding mode;
[0145] Responding to the trigger button being pressed and the rotation angle of the handle being greater than the angle threshold, controlling the virtual character and the vehicle ridden by the virtual character to switch from the upright riding mode to the side riding mode in the virtual environment.
[0146] Optionally, the upright riding refers to the following riding mode: a straight line passing through the center of gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment passes through the vehicle.
[0147] Optionally, the upright riding refers to the following riding mode: the center of gravity position of the virtual character in the virtual environment is higher than the hanging position of the virtual character and the vehicle.
[0148] Optionally, the side riding refers to the following riding mode: a straight line passing through the center of gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment does not pass through the vehicle.
[0149] Optionally, the side-mounted riding refers to the following riding method: the center of gravity position of the virtual character in the virtual environment is lower than the connection position between the virtual character and the vehicle.
[0150] Optionally, the method further includes:
[0151] Determining the orientation of side-mounted riding according to the rotation direction of the handle.
[0152] Optionally, the exposed area of the virtual character in the specified viewing direction in the upright riding mode is greater than the exposed area of the virtual character in the side-mounted riding mode in the specified viewing direction, where the specified viewing direction is the viewing direction parallel to the horizontal plane of the virtual environment, perpendicular to the moving direction of the vehicle, and opposite to the orientation of side-mounted riding.
[0153] Optionally, the upper side of the handle includes a first joystick and a second joystick; the method further includes:
[0154] In response to a first pushing operation acting on the first joystick and a second pushing operation acting on the second joystick, controlling the vehicle to reduce its moving speed, where the first pushing operation is a pushing operation towards the second joystick, the second pushing operation is a pushing operation towards the first joystick, and the first pushing operation and the second pushing operation at least partially overlap in time sequence.
[0155] Optionally, the upper side of the handle includes a first joystick and a second joystick; the method further includes:
[0156] In response to a third pushing operation acting on the first joystick and a fourth pushing operation acting on the second joystick, controlling the vehicle to increase its moving speed or controlling the vehicle to perform a specific action to raise its center of gravity position, where the pushing directions of the third pushing operation and the fourth pushing operation are the same.
[0157] Optionally, the third pushing operation and the fourth pushing operation are perpendicular to the front side of the handle or the tangent plane of the front side; or, the third pushing operation and the fourth pushing operation are perpendicular to the connection line between the first joystick and the second joystick.
[0158] Specifically, the storage medium can be a general storage medium, such as a removable disk, a hard disk, etc. When the computer program on the storage medium is run, it can execute the method of controlling a virtual character to ride a vehicle through a handle, solving the problem of low operation efficiency of players for game control devices in the prior art. When the player in this application switches the virtual character and the vehicle ridden by the virtual character from the upright riding mode to the side riding mode through the handle, the player presses the trigger button to restore the virtual character to increase the contact area between the player and the vehicle, as well as increase the contact force between the player and the vehicle, and the player turns the handle to restore the virtual character from riding on the vehicle to riding on the side of the vehicle, so that the operation tendency of the player's handle operation is consistent with the action tendency of the virtual character performing actions in the virtual environment, enabling the player to easily remember the operation rules of the handle, reducing the situation of operation errors, and improving the operation efficiency and accuracy of the player.
[0159] In the embodiments provided in the present application, it should be understood that the disclosed methods and devices can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of the units is only a logical function division, and there may be other division methods in actual implementation. For another example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed coupling or direct coupling or communication connection to each other can be through some communication interfaces, and the indirect coupling or communication connection of the devices or units can be in electrical, mechanical or other forms.
[0160] The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they can be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0161] In addition, the functional units in the embodiments provided in the present application can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit.
[0162] When the above-mentioned function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of this application. The aforementioned storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard disks, read-only memories (ROM, Read-Only Memory), random access memories (RAM, Random Access Memory), magnetic disks, or optical discs.
[0163] It should be noted that: similar reference numerals and letters represent similar items in the following drawings. Therefore, once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. In addition, the terms "first", "second", "third", etc. are only used for descriptive distinction and cannot be understood as indicating or implying relative importance.
[0164] Finally, it should be noted that: the above-mentioned embodiments are only specific implementation manners of this application, used to illustrate the technical solution of this application, rather than limiting it. The protection scope of this application is not limited thereto. Although this application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: any person skilled in the art within the technical scope disclosed in this application can still modify the technical solutions recorded in the foregoing embodiments, or can easily think of changes, or perform equivalent replacements on some of the technical features; and these modifications, changes, or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of this application. All should be covered within the protection scope of this application. Therefore, the protection scope of this application should be subject to the protection scope of the claims.
Claims
1. A method for controlling a virtual character to ride a vehicle through a handle, characterized in that, The front side of the handle includes at least one trigger button, and the method includes: Responding to a movement control operation received through the handle, controlling the virtual character and the vehicle ridden by the virtual character to move together in a virtual environment in a forward-riding manner; Responding to the trigger button being pressed and the rotation angle of the handle being greater than an angle threshold, controlling the virtual character and the vehicle ridden by the virtual character to switch from a forward-riding manner to a side-riding manner in the virtual environment; Switching from a forward-riding manner to a side-riding manner means that the virtual character changes from riding on the vehicle to riding on the side of the vehicle; Responding to the trigger button being pressed and the rotation angle of the handle being greater than an angle threshold, the handle generates a holding signal corresponding to the trigger button being pressed and a side-turn signal corresponding to the rotation angle of the handle being greater than the angle threshold, and the handle sends the holding signal and the side-turn signal to the terminal device, and the terminal device controls the virtual character and the vehicle ridden by the virtual character in the virtual environment to switch from a forward-riding manner to a side-riding manner according to the holding signal and the side-turn signal.
2. The method according to claim 1, characterized in that, The forward-riding manner refers to the following riding manner: a straight line passing through the center-of-gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment passes through the vehicle.
3. The method according to claim 2, wherein The forward-riding manner refers to the following riding manner: the center-of-gravity position of the virtual character in the virtual environment is higher than the connection position between the virtual character and the vehicle.
4. The method according to claim 1, wherein The side-riding manner refers to the following riding manner: a straight line passing through the center-of-gravity position of the virtual character in the virtual environment and perpendicular to the horizontal plane of the virtual environment does not pass through the vehicle.
5. The method according to claim 4, wherein The side-riding manner refers to the following riding manner: the center-of-gravity position of the virtual character in the virtual environment is lower than the connection position between the virtual character and the vehicle.
6. The method according to claim 1, characterized in that, The method further includes: Determining the orientation of side-riding according to the rotation direction of the handle.
7. The method according to claim 6, wherein The exposed area of the virtual character in a forward-riding manner in a specified observation direction is greater than the exposed area of the virtual character in a side-riding manner in the specified observation direction, where the specified observation direction is the observation direction parallel to the horizontal plane of the virtual environment, perpendicular to the moving direction of the vehicle, and opposite to the orientation of side-riding.
8. The method according to claim 1, characterized in that The upper side of the handle includes a first joystick and a second joystick; the method further includes: Responding to a first pushing operation on the first joystick and a second pushing operation on the second joystick, controlling the vehicle to reduce its moving speed, where the first pushing operation is a pushing operation towards the second joystick, the second pushing operation is a pushing operation towards the first joystick, and the first pushing operation and the second pushing operation at least partially overlap in time sequence.
9. The method according to claim 1, wherein The upper side of the handle includes a first joystick and a second joystick; the method further includes: Responding to a third pushing operation on the first joystick and a fourth pushing operation on the second joystick, controlling the vehicle to increase its moving speed or controlling the vehicle to perform a specific action to raise its center-of-gravity position, where the pushing directions of the third pushing operation and the fourth pushing operation are the same.
10. The method according to claim 9, characterized in that, The third pushing operation and the fourth pushing operation are perpendicular to the front side of the handle or the cutting plane of the front side; or, the third pushing operation and the fourth pushing operation are perpendicular to the connection line between the first rocker and the second rocker.
11. A device for controlling a virtual character to ride a vehicle through a handle, characterized in that, The front side of the handle includes at least one trigger button, and the device includes: In response to the movement control operation received through the handle, controlling the virtual character and the vehicle ridden by the virtual character to move together in a forward riding manner in the virtual environment; In response to the trigger button being pressed and the rotation angle of the handle being greater than the angle threshold, controlling the virtual character and the vehicle ridden by the virtual character to switch from the forward riding manner to the side riding manner in the virtual environment; The switch from the forward riding manner to the side riding manner means that the virtual character changes from riding on the vehicle to riding on the side of the vehicle; In response to the trigger button being pressed and the rotation angle of the handle being greater than the angle threshold, the handle generates a holding signal corresponding to the pressing of the trigger button, and generates a side turning signal corresponding to the rotation angle of the handle being greater than the angle threshold. The handle sends the holding signal and the side turning signal to the terminal device, and the terminal device controls the virtual character and the vehicle ridden by the virtual character in the virtual environment to switch from the forward riding manner to the side riding manner according to the holding signal and the side turning signal.
12. A computer device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the method described in any one of the above claims 1-10.
13. A computer-readable storage medium, on which a computer program is stored, characterized in that, When the computer program is run by the processor, it executes the steps of the method described in any one of the above claims 1-10.
Citation Information
Patent Citations
Video driving game system and control device
US20110034226A1
Simulated Handlebar Twist-Grip Control of a Simulated Vehicle Using a Hand-Held Inertial Sensing Remote Controller
US20110053691A1