CN112090076A - Game character action control method, device, equipment and medium - Google Patents

Game character action control method, device, equipment and medium Download PDF

Info

Publication number
CN112090076A
CN112090076A CN202010820728.4A CN202010820728A CN112090076A CN 112090076 A CN112090076 A CN 112090076A CN 202010820728 A CN202010820728 A CN 202010820728A CN 112090076 A CN112090076 A CN 112090076A
Authority
CN
China
Prior art keywords
animation
action
game
centroid
game character
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010820728.4A
Other languages
Chinese (zh)
Other versions
CN112090076B (en
Inventor
邵中慧
孟祥超
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Zhongqing Longtu Network Technology Co ltd
Original Assignee
Shenzhen Zhongqing Longtu Network Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Zhongqing Longtu Network Technology Co ltd filed Critical Shenzhen Zhongqing Longtu Network Technology Co ltd
Priority to CN202010820728.4A priority Critical patent/CN112090076B/en
Publication of CN112090076A publication Critical patent/CN112090076A/en
Application granted granted Critical
Publication of CN112090076B publication Critical patent/CN112090076B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/55Controlling game characters or game objects based on the game progress
    • A63F13/56Computing the motion of game characters with respect to other game characters, game objects or elements of the game scene, e.g. for simulating the behaviour of a group of virtual soldiers or for path finding
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/60Generating or modifying game content before or while executing the game program, e.g. authoring tools specially adapted for game development or game-integrated level editor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T13/00Animation

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Processing Or Creating Images (AREA)

Abstract

The embodiment of the disclosure relates to a game role action control method, a game role action control device, game role action control equipment and a game role action control medium, wherein the method comprises the following steps: determining a bone original mass center of the game role and a virtual mass center corresponding to the bone original mass center, wherein the positions of the virtual mass center and the bone original mass center are kept consistent in the action execution process of the game role; controlling the game role to execute the upper body action based on any one of the skeleton primitive centroid and the virtual centroid and the upper body animation data of the game role; controlling the game character to perform a lower body action based on the skeletal primitive centroid and the other of the virtual centroids and the game character's lower body animation data. The disclosed embodiments optimize action control for a game character when different actions are required to be performed by the upper and lower bodies of the game character, and optimize animation effects presented by the game character.

Description

Game character action control method, device, equipment and medium
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a method, an apparatus, a device, and a medium for controlling actions of game characters.
Background
With the development of the electronic game industry, the competitive games come in a variety of varieties, the tastes of players also become more and more critical, and the quality of game products is required to be improved if manufacturers want to attract players continuously. As the most intuitive impression to the player is left, the level of animation largely determines the player's appreciation for a game.
Conventionally, when a game character performs different actions on its upper and lower bodies, for example, the game character uses skills while moving, it is common to adopt an action control scheme based on a grid and a skeleton. The user firstly introduces the character picture, then a grid is established by taking the outline of the character picture as a boundary, the grid consists of a plurality of nodes, the nodes are scattered and covered on the whole character picture in an average mode, and the picture around each node is dominated by the node. The user also needs to configure bones for the object, assign a node to each bone, and then the object itself records only the weights affected by the bone objects. And when the animation is played, the animation is reproduced through the key frame of the skeleton object and the weight recorded by the object.
In the existing scheme, the calculation amount involved in the process of controlling the game role to respectively execute the upper and lower body actions is large, so that the scheme is complex to realize, for example, from the perspective of skinning weight, if the number of vertexes is more, the number of times of calculating the final coordinate of each vertex in the action execution process is more, and from the perspective of bone parent-child relationship, if the number of bones is more, the number of times of calculating the matrix coordinate system is more; furthermore, the animation effect presented by the game character is not ideal due to the correlation between the motion directions of the upper body and the lower body.
Disclosure of Invention
In order to solve the technical problem described above or at least partially solve the technical problem, embodiments of the present disclosure provide a game character motion control method, apparatus, device, and medium.
In a first aspect, an embodiment of the present disclosure provides a game character action control method, including:
determining a bone primitive centroid of a game character and a virtual centroid corresponding to the bone primitive centroid, wherein the positions of the virtual centroid and the bone primitive centroid are consistent in the action execution process of the game character;
controlling the game character to perform a top-half body action based on any one of the skeletal primitive centroid and the virtual centroid and top-half body animation data of the game character;
controlling the game character to perform a lower body action based on the skeletal primitive centroid and another of the virtual centroids and lower body animation data for the game character.
In a second aspect, an embodiment of the present disclosure further provides a game character motion control apparatus, including:
the center of mass determining module is used for determining a bone primitive center of mass of a game role and a virtual center of mass corresponding to the bone primitive center of mass, wherein the positions of the virtual center of mass and the bone primitive center of mass are kept consistent in the action executing process of the game role;
the upper half body action execution module is used for controlling the game role to execute the upper half body action based on any one of the skeleton primitive centroid and the virtual centroid and the upper half body animation data of the game role;
and the upper body action execution module is used for controlling the game role to execute the lower body action based on the skeletal primitive centroid and the other centroid in the virtual centroid and the lower body animation data of the game role.
In a third aspect, an embodiment of the present disclosure further provides an electronic device, where the electronic device includes: a processor; a memory for storing the processor-executable instructions; the processor is used for reading the executable instruction from the memory and executing the instruction to realize the action control method of any game character provided by the embodiment of the disclosure.
In a fourth aspect, the disclosed embodiment further provides a computer-readable storage medium, where the storage medium stores a computer program, and the computer program, when executed by a processor, implements any game character action control method provided by the disclosed embodiment.
Compared with the prior art, the technical scheme provided by the embodiment of the disclosure has the following advantages: the virtual center of mass is set for the bone of the game role, the upper half body and the lower half body of the game role are separated, the game role is controlled to execute the upper half body action and the lower half body action respectively, the action control aiming at the game role when the upper half body and the lower half body of the game role are required to execute different actions is optimized, the animation effect presented by the game role is optimized, and the problems that the realization flow of the action control is complex when the upper half body and the lower half body of the game role execute different actions and the animation effect of the game role is not ideal in the existing scheme are solved.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure.
In order to more clearly illustrate the embodiments or technical solutions in the prior art of the present disclosure, the drawings used in the description of the embodiments or prior art will be briefly described below, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without inventive exercise.
Fig. 1 is a flowchart of a game character action control method according to an embodiment of the present disclosure;
FIG. 2 is a flow chart of another method for controlling actions of a game character according to an embodiment of the present disclosure;
fig. 3 is a schematic structural diagram of a game character motion control apparatus according to an embodiment of the present disclosure;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
Detailed Description
In order that the above objects, features and advantages of the present disclosure may be more clearly understood, aspects of the present disclosure will be further described below. It should be noted that the embodiments and features of the embodiments of the present disclosure may be combined with each other without conflict.
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present disclosure, but the present disclosure may be practiced in other ways than those described herein; it is to be understood that the embodiments disclosed in the specification are only a few embodiments of the present disclosure, and not all embodiments.
Fig. 1 is a flowchart of a game character motion control method according to an embodiment of the present disclosure, which may be applied to a case where an upper body and a lower body of a game character are controlled to perform different motions respectively. The method provided by the embodiment of the disclosure can be executed by a game character action control device, which can be implemented by software and/or hardware and can be integrated on any electronic equipment with computing capability, such as a terminal, a server and the like.
As shown in fig. 1, a method for controlling actions of a game character according to an embodiment of the present disclosure may include:
s101, determining a bone primitive centroid of the game role and a virtual centroid corresponding to the bone primitive centroid, wherein the positions of the virtual centroid and the bone primitive centroid are kept consistent in the action executing process of the game role.
In the game development process, a developer can determine the original mass center of the skeleton of the game role (referred to as the skeleton primary mass center for short) according to the skeleton structure of the game role, and then a node is added at the skeleton primary mass center to serve as the virtual mass center of the game role. The skeletogenic and virtual centroids are located on the spine. The location coordinates of the skeletal primitive and virtual centroids in the game character's skeletal frame coordinate system can be stored in the game character's configuration information for subsequent reading and use. The game character may be divided into a virtual character and a virtual animal based on different game types, and further, the division of the body of the game character may be determined according to actual conditions based on different game character types, for example, for a game character of a virtual character type, the division of the upper body and the lower body may have a waist position as a separation line.
In different game scenes, when a game character performs any action, the movement, rotation and other operations of the skeleton of each part are controlled by the mass center of the skeleton. By adding the virtual center of mass for the game role, the game role can be realized based on different center of mass when simultaneously executing the upper body action and the lower body action, thereby achieving the effect of isolation control of the upper body action and the lower body action. And the positions of the virtual centroid and the bone primitive centroid are kept consistent in the action process of the game role, so that the actions presented by the game role are ensured to have harmony, reality and consistency in the process of simultaneously executing the upper half body action and the lower half body action by the game role.
And S102, controlling the game role to execute the upper body action based on any one of the skeleton primitive centroid and the virtual centroid and the upper body animation data of the game role.
And S103, controlling the game character to execute the lower body action based on the other mass center of the bone primitive mass center and the virtual mass center and the lower body animation data of the game character.
Specifically, the game role can be controlled to execute the upper body action based on the skeleton primitive centroid and the upper body animation data of the game role; the game character may also be controlled to perform the upper body motion based on the virtual centroid and the upper body animation data of the game character. When the game character is controlled to perform the lower body motion after the centroid for controlling the game character to perform the upper body motion is determined, it is implemented based on the remaining another centroid. For example, in the animation design process of the game character, according to the hierarchical relationship of human-shaped skeletons, the upper half skeleton of the game character can be set as the original skeleton centroid from the spine, the lower half skeleton of the game character, including the pelvis, the legs and the like, can be set as the newly added virtual centroid.
In the process of controlling the game role to execute the action, the complete animation data of the game role designed in advance can be obtained in an animation data importing mode, and then the complete animation data is analyzed to distinguish the upper half animation data and the lower half animation data of the game role. The upper body animation data and the lower body animation data of the game character may be determined according to a specific game scene, and the embodiment of the present disclosure is not particularly limited. For example, for a situation where a game character is attacked while moving, the upper body actions of the game character include actions using game skills, and the lower body actions include movement actions, such as a ride-on ride movement of the game character. Finally, the complete animation effect is presented through the fusion between the upper body action and the lower body action of the game role.
The technical solution of the embodiments of the present disclosure may be applied to a development stage of a game, for example, a developer develops and designs upper body movements and lower body movements of a game character, or may be applied to a stage in which a player participates in a game, for example, the player controls the game character to perform various movements through a user terminal. Furthermore, there is no strict execution order limitation between the operation S102 and the operation S103, and the logic order shown in fig. 1 should not be understood as a specific limitation to the embodiments of the present disclosure. That is, the timing for controlling the game character to perform the upper body motion and the timing for controlling the game character to perform the lower body motion may be triggered simultaneously, or may be delayed by a predetermined time, for example, an operation for controlling the game character to perform the lower body motion is triggered during the process of controlling the game character to perform the upper body motion, which is related to the actual game design logic.
The virtual center of mass is set for the skeleton of the game role, the upper half body and the lower half body of the game role are separated, and the game role is controlled to execute the upper half body action and the lower half body action respectively, so that the game role has higher moving freedom, the action control aiming at the game role when the upper half body and the lower half body of the game role are required to execute different actions is optimized, the animation effect presented by the game role is optimized, the problems that the realization flow of the action control is complex when the upper half body and the lower half body of the game role execute different actions in the existing scheme and the animation effect of the game role is not ideal are solved, and the complex game animation expression requirement can be met.
On the basis of the above technical solution, further, the method provided by the embodiment of the present disclosure further includes:
detecting whether the position of the virtual centroid coincides with the position of the original skeleton centroid in real time in the process of controlling the game role to execute the upper half body action and the lower half body action;
if it is detected that the virtual center of mass does not coincide with the location of the skeletogenic center of mass, the location of the virtual center of mass is adjusted to coincide with the location of the skeletogenic center of mass.
During the process of controlling the game role to execute the action, a pre-programmed centroid position detection program can be called to detect the positions of the virtual centroid and the original skeleton centroid in real time, and if the positions of the virtual centroid and the original skeleton centroid are detected to be not coincident, the position of the virtual centroid is adjusted by taking the position of the original skeleton centroid as a reference to be coincident with the position of the original skeleton centroid; if the two positions are detected to coincide, the position adjustment operation does not need to be performed. In order to ensure the animation effect of the game character in the process of adjusting the position of the virtual centroid, the position of the limb portion (i.e., the upper body or the lower body) whose motion is controlled based on the virtual centroid can be adaptively adjusted according to the adjustment of the position of the virtual centroid, so that the coordination of the upper and lower body motions can be ensured, and the phenomenon of obvious torsional deformation of the motion can be avoided.
The positions of the original skeleton centroid and the virtual centroid are detected in real time, and the position adjustment operation of the virtual centroid is executed according to the detection result, so that the coordination, the reality and the continuity of the execution of the actions of the upper half body and the lower half body are ensured in the process that the upper half body and the lower half body of the game role are separated to execute different actions, and the high-quality animation effect can be finally presented.
Fig. 2 is a flowchart of another game character action control method provided in the embodiment of the present disclosure, which is further optimized and expanded based on the above technical solution, and can be combined with the above optional embodiments. As shown in fig. 2, the method may include:
s201, determining a bone primitive centroid of the game role and a virtual centroid corresponding to the bone primitive centroid, wherein the positions of the virtual centroid and the bone primitive centroid are kept consistent in the action executing process of the game role.
S202, adding an animation mask to the animation corresponding to the lower body in the target animation data of the game role, and controlling the game role to execute the upper body action based on any one of the bone primitive centroid and the virtual centroid and the upper body animation data of the game role.
And S203, adding an animation mask to the animation corresponding to the upper body limb in the target animation data of the game character, and controlling the game character to execute the lower body action based on the other mass center of the bone primitive mass center and the virtual mass center and the lower body animation data of the game character.
By using the animation mask, the limb parts of the game role can be isolated in a partitioned way, so that different animation effects are implemented on the upper half body and the lower half body of the game role, the animation direction of the upper half body and the lower half body can maintain the self direction, and the game role is not interfered by the other party. With respect to specific implementations of the animator masking technique, reference may be made to existing implementation principles, and the disclosed embodiments are not particularly limited.
S204, in the process of controlling the game character to execute the upper half body action and the lower half body action, acquiring an action fusion event added in a target action frame of the game character, wherein the action fusion event comprises an action participating in fusion and a fusion parameter.
The animation data of the game character includes a plurality of frames of images, each of which involves the upper body motion and the lower body motion of the game character. The target action frame added with the action fusion event includes an action frame with superimposed deformation of the upper body action and the lower body action or deformation of the skin of the game character, and the action frame can be specifically determined by a developer in advance based on animation data of the game character, or can be automatically detected and labeled by a preset action frame detection program. After the target action frame is determined, the action participating in the fusion and the fusion parameters can be set by a developer according to action smoothing requirements, so as to form an action fusion event and add the action fusion event to the target action frame. The fusion parameters may include any parameters that are required to be used in the motion smoothing process of the upper and lower bodies and that define the degree of adjustment required for the bones in the upper and lower bodies during the motion smoothing process, such as information on the direction, displacement, angle, and the like of the adjustment. By adding the action fusion event into the target action frame, the connection between the upper body action and the lower body action can be smoother, and a high-quality animation effect is presented.
And S205, smoothing the connection of the upper body motion and the lower body motion in the target motion frame of the game character according to the motion fusion event.
For example, when a developer uses animation software to make an action file of a game character, some custom events, namely action fusion events, can be added at some target action frames with large body deformation or distortion. Specifically, the developer may determine, based on experience and observation, the frame or frames in a continuous motion frame sequence, which may be deformed or warped, as the target motion frame, and then add the motion fusion event to the corresponding target motion frame.
Taking a specific Animation design software tool as an example, a developer can combine the action files of game characters into an Animation Controller (Animation Controller) of a Unity engine by using an Animation in a Unity editor. The Animation Controller is divided into a base layer, an upper body layer and a lower body layer. And forming an action switching state machine according to action requirements under different roles. The state machine comprises a father state machine, a son state and a son Blend Tree. The Blend Tree comprises a plurality of fusion weight parameters (namely fusion parameters), and the parameters finally determine how the actions of the game characters are played and fused. The specific meaning of the fusion weight parameter is related to the definition in the animation tool.
When the developer adds the action fusion event on the target action frame which is likely to have deformation and penetration or skin distortion and configures Blend Tree fusion weight parameters, the action fusion event comprising the fusion weight parameters is automatically transmitted to the upper-layer game logic when the upper-half action and the lower-half action of the game role are played. After receiving the action fusion event, the upper-layer game logic code analyzes the Blend Tree fusion weight parameter in the event, and then carries out smooth processing on the upper half body action and the lower half body action of the game role based on the analyzed parameter, thereby ensuring the smooth switching of the upper half body action and the lower half body action and avoiding the distortion at the joint of the upper half body and the lower half body.
The virtual center of mass is set for the skeleton of the game role, and the upper half body and the lower half body of the game role are separated by combining an animation masking technology, so that the game role is controlled to execute the upper half body action and the lower half body action respectively, the action control aiming at the game role when the upper half body and the lower half body of the game role are required to execute different actions is optimized, the animation effect presented by the game role is optimized, and the problems that the action control realization process is complex and the animation effect of the game role is not ideal when the upper half body and the lower half body of the game role execute different actions in the existing scheme are solved; meanwhile, the action fusion event added in the target action frame of the game role is utilized to smooth the connection of the upper body action and the lower body action in the target action frame of the game role, so that the smooth switching of the upper body action and the lower body action is ensured, the distortion deformation at the connection part of the upper body and the lower body is avoided, and the animation effect of the game role is further optimized.
On the basis of the above technical solution, optionally, the method provided by the embodiment of the present disclosure may further include:
acquiring target animation data of a game role, and determining animation types related to the target animation data, wherein the animation types comprise an upper body animation and a lower body animation, namely the current target animation data simultaneously defines actions to be executed by the upper body and the lower body of the game role;
if the target animation data is determined to relate to the upper body animation and the lower body animation at the same time, the adding operation of the animation mask is triggered to respectively add the animation mask to the animation of the corresponding lower body limb and the animation of the corresponding upper body limb in the target animation data.
Further, if it is determined that the target animation data relates to both the upper body animation and the lower body animation, an adding operation of the animation mask is triggered, including:
adjusting weights of upper body limbs and lower body limbs of the game character if it is determined that the target animation data relates to both the upper body animation and the lower body animation;
and triggering the adding operation of the animation mask according to the adjusted weights of the upper body limb and the lower body limb.
For example, when the upper body and the lower body of the game character relate to the same action type, that is, the upper body and the lower body of the game character do not need to be separated, the weight of the upper body is set to 1, and the weight of the lower body is set to 0, for example, the game character is about to be in a moving state, the action types related to the upper body and the lower body only move, the lower body performs a horse riding action, the upper body does not need to additionally perform other types of actions except some related actions according to the action of the lower body, and at this time, the weight of the upper body of the game character can be determined to be 1 and the weight of the lower body to be 0; when the upper body and the lower body of the game character relate to different action types, that is, when the upper body and the lower body of the game character need to be separated, the upper body weight is set to 1, and the lower body weight is also set to 1. Therefore, when the weight corresponding to the upper and lower bodies of the game character is detected to be adjusted, the starting operation of the animation mask function is triggered according to the adjusted weight. In addition, the weight change can be embodied, and the weight values corresponding to the upper and lower half bodies are not limited in the embodiments of the present disclosure.
Whether the adding operation of the animation mask is triggered or not is determined by analyzing whether the target animation data of the game role relates to the upper body action and the lower body action at the same time, so that on one hand, the reasonability of the calling time of the animation mask technology is ensured, and on the other hand, the smooth implementation of the separation execution of the upper body action and the lower body action of the game role is further ensured.
By taking a game scene played by a multi-player online role as an example, the technical scheme of the embodiment of the disclosure can meet the requirements of playing methods and animation expression of the game role during moving and attacking; the flexible animation relationship between the upper and lower bodies can make the game animation more smoothly expressed.
Fig. 3 is a schematic structural diagram of a game character motion control apparatus according to an embodiment of the present disclosure. The embodiment of the present disclosure can be applied to a case where the upper body and the lower body of the game character are controlled to perform different actions, respectively. The apparatus provided by the embodiment of the present disclosure may be implemented by software and/or hardware, and may be integrated on any electronic device with computing capability, such as a terminal, a server, and the like.
As shown in fig. 3, the game character motion control apparatus provided by the embodiment of the present disclosure may include a centroid determining module 301, an upper body motion executing module 302, and a lower body motion executing module 303, where:
the centroid determining module 301 is configured to determine a bone primitive centroid of the game character and a virtual centroid corresponding to the bone primitive centroid, where positions of the virtual centroid and the bone primitive centroid are consistent in an action executing process of the game character;
an upper body action execution module 302, configured to control the game character to execute an upper body action based on any one of the skeleton primitive centroid and the virtual centroid and upper body animation data of the game character;
and a lower body action execution module 303, configured to control the game character to execute a lower body action based on the skeletal primitive centroid and the other centroid of the virtual centroids and the lower body animation data of the game character.
Optionally, the apparatus provided in the embodiment of the present disclosure further includes:
the position detection module is used for detecting whether the position of the virtual centroid coincides with the position of the original skeleton centroid in real time in the process of controlling the game role to execute the upper half body action and the lower half body action;
and the position adjusting module is used for adjusting the position of the virtual center of mass to coincide with the position of the bone origin center of mass if the virtual center of mass is detected to be not coincident with the position of the bone origin center of mass.
Optionally, the upper body action execution module 302 is specifically configured to:
adding an animation mask to the animation corresponding to the lower body in the target animation data of the game role, and controlling the game role to execute the upper body action based on any one of the bone primitive centroid and the virtual centroid and the upper body animation data of the game role;
accordingly, the lower body action performing module 303 is specifically configured to:
animation masks are added to the animation corresponding to the upper body limbs in the target animation data of the game role, and the game role is controlled to execute the lower body actions based on the other mass center of the bone primitive mass center and the virtual mass center and the lower body animation data of the game role.
Optionally, the apparatus provided in the embodiment of the present disclosure further includes:
the target animation data acquisition module is used for acquiring target animation data of the game role and determining animation types related to the target animation data, wherein the animation types comprise an upper body animation and a lower body animation;
and the animation mask triggering module is used for triggering the addition operation of the animation mask if the target animation data is determined to relate to the upper body animation and the lower body animation at the same time so as to add the animation mask to the animation of the corresponding lower body limb and the animation of the corresponding upper body limb in the target animation data respectively.
Optionally, the animation mask triggering module includes:
a weight adjustment unit for adjusting weights of an upper body extremity and a lower body extremity of the game character if it is determined that the target animation data relates to both the upper body animation and the lower body animation;
and the animation mask triggering unit is used for triggering the adding operation of the animation mask according to the adjusted weights of the upper body limb and the lower body limb.
Optionally, the apparatus provided in the embodiment of the present disclosure further includes:
the event acquisition module is used for acquiring an action fusion event added in a target action frame of the game role in the process of controlling the game role to execute the upper half body action and the lower half body action, wherein the action fusion event comprises an action participating in fusion and a fusion parameter;
and the action smoothing module is used for smoothing the connection of the upper body action and the lower body action in the target action frame of the game role according to the action fusion event.
Optionally, the target action frame includes an action frame in which an upper body action and a lower body action are superimposed and deformed, or a skin of the game character is distorted and deformed.
Optionally, the upper body motion comprises a motion of a game character using a game skill, and the lower body motion comprises a movement motion.
The game role action control device provided by the embodiment of the disclosure can execute any game role action control method provided by the embodiment of the disclosure, and has corresponding functional modules and beneficial effects of the execution method. Reference may be made to the description of any method embodiment of the disclosure that may not be described in detail in the embodiments of the apparatus of the disclosure.
Fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure. As shown in fig. 4, the electronic device 400 includes one or more processors 401 and memory 402.
The processor 401 may be a Central Processing Unit (CPU) or other form of processing unit having data processing capabilities and/or instruction execution capabilities, and may control other components in the electronic device 400 to perform desired functions.
Memory 402 may include one or more computer program products that may include various forms of computer-readable storage media, such as volatile memory and/or non-volatile memory. Volatile memory can include, for example, Random Access Memory (RAM), cache memory (or the like). The non-volatile memory may include, for example, Read Only Memory (ROM), a hard disk, flash memory, and the like. One or more computer program instructions may be stored on a computer readable storage medium and executed by the processor 401 to implement the above three-dimensional display method of two-dimensional pictures of the embodiments of the present disclosure and/or other desired functions. Various contents such as an input signal, a signal component, a noise component, etc. may also be stored in the computer-readable storage medium.
In one example, the electronic device 400 may further include: an input device 403 and an output device 404, which are interconnected by a bus system and/or other form of connection mechanism (not shown).
The input device 403 may also include, for example, a keyboard, a mouse, and the like.
The output device 404 may output various information to the outside, including the determined distance information, direction information, and the like. The output devices 404 may include, for example, a display, speakers, a printer, and a communication network and its connected remote output devices, among others.
Of course, for simplicity, only some of the components of the electronic device 400 relevant to the present disclosure are shown in fig. 4, omitting components such as buses, input/output interfaces, and the like. In addition, electronic device 400 may include any other suitable components depending on the particular application.
In addition to the above methods and apparatus, embodiments of the present disclosure may also be a computer program product comprising computer program instructions that, when executed by a processor, cause the processor to perform any of the game character motion control methods provided by embodiments of the present disclosure.
The computer program product may write program code for performing the operations of embodiments of the present disclosure in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server.
Furthermore, embodiments of the present disclosure may also be a computer-readable storage medium having stored thereon computer program instructions that, when executed by a processor, cause the processor to perform any of the game character motion control methods provided by embodiments of the present disclosure.
A computer-readable storage medium may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may include, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
It is noted that, in this document, relational terms such as "first" and "second," and the like, may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The foregoing are merely exemplary embodiments of the present disclosure, which enable those skilled in the art to understand or practice the present disclosure. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the disclosure. Thus, the present disclosure is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (11)

1. A game character motion control method is characterized by comprising the following steps:
determining a bone primitive centroid of a game character and a virtual centroid corresponding to the bone primitive centroid, wherein the positions of the virtual centroid and the bone primitive centroid are consistent in the action execution process of the game character;
controlling the game character to perform a top-half body action based on any one of the skeletal primitive centroid and the virtual centroid and top-half body animation data of the game character;
controlling the game character to perform a lower body action based on the skeletal primitive centroid and another of the virtual centroids and lower body animation data for the game character.
2. The method of claim 1, further comprising:
detecting whether the position of the virtual centroid coincides with the position of the bone primitive centroid in real time in the process of controlling the game role to execute the upper body action and the lower body action;
adjusting the position of the virtual center of mass to coincide with the position of the skeletal primitive center of mass if it is detected that the virtual center of mass does not coincide with the position of the skeletal primitive center of mass.
3. The method of claim 1, wherein controlling the game character to perform a top-half body action based on any of the skeletal primitive centroid and the virtual centroid and top-half body animation data for the game character comprises:
adding an animation mask to the animation of the lower body limb in the target animation data of the game role, and controlling the game role to execute an upper body action based on any one of the skeleton primitive centroid and the virtual centroid and the upper body animation data of the game role;
accordingly, controlling the game character to perform a lower body action based on the skeletal primitive centroid and another of the virtual centroids and the game character's lower body animation data, including:
and adding an animation mask to the animation corresponding to the upper body limb in the target animation data of the game character, and controlling the game character to execute the lower body action based on the other mass center of the bone primitive mass center and the virtual mass center and the lower body animation data of the game character.
4. The method of claim 3, further comprising:
acquiring target animation data of the game role, and determining animation types related to the target animation data, wherein the animation types comprise an upper body animation and a lower body animation;
and if the target animation data is determined to relate to the upper body animation and the lower body animation at the same time, triggering an animation mask adding operation so as to add the animation mask to the animation of the corresponding lower body limb and the animation of the corresponding upper body limb in the target animation data respectively.
5. The method of claim 4, wherein if it is determined that the target animation data relates to both the upper body animation and the lower body animation, triggering an animation mask adding operation, comprises:
adjusting weights of upper body limbs and lower body limbs of the game character if it is determined that the target animation data relates to both the upper body animation and the lower body animation;
and triggering the adding operation of the animation mask according to the adjusted weights of the upper body limb and the lower body limb.
6. The method of claim 1, further comprising:
in the process of controlling the game role to execute the upper half body action and the lower half body action, acquiring an action fusion event added in a target action frame of the game role, wherein the action fusion event comprises an action participating in fusion and a fusion parameter;
and smoothing the connection of the upper body action and the lower body action in the target action frame of the game character according to the action fusion event.
7. The method according to claim 6, wherein the target action frame includes an action frame in which there is a superimposed deformation of the upper body motion and the lower body motion, or a skinning distortion deformation of the game character.
8. The method of claim 1, wherein the upper body motion comprises a game skill using motion of the game character and the lower body motion comprises a movement motion.
9. A game character motion control device, comprising:
the center of mass determining module is used for determining a bone primitive center of mass of a game role and a virtual center of mass corresponding to the bone primitive center of mass, wherein the positions of the virtual center of mass and the bone primitive center of mass are kept consistent in the action executing process of the game role;
the upper half body action execution module is used for controlling the game role to execute the upper half body action based on any one of the skeleton primitive centroid and the virtual centroid and the upper half body animation data of the game role;
and the lower body action execution module is used for controlling the game role to execute the lower body action based on the bone primitive centroid and the other centroid in the virtual centroid and the lower body animation data of the game role.
10. An electronic device, comprising:
a processor;
a memory for storing the processor-executable instructions;
the processor is used for reading the executable instructions from the memory and executing the instructions to realize the game character action control method of any one of the claims 1 to 8.
11. A computer-readable storage medium, characterized in that the storage medium stores a computer program which, when executed by a processor, implements the game character motion control method of any one of claims 1 to 8.
CN202010820728.4A 2020-08-14 2020-08-14 Game character action control method, device, equipment and medium Active CN112090076B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010820728.4A CN112090076B (en) 2020-08-14 2020-08-14 Game character action control method, device, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010820728.4A CN112090076B (en) 2020-08-14 2020-08-14 Game character action control method, device, equipment and medium

Publications (2)

Publication Number Publication Date
CN112090076A true CN112090076A (en) 2020-12-18
CN112090076B CN112090076B (en) 2022-02-01

Family

ID=73754387

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010820728.4A Active CN112090076B (en) 2020-08-14 2020-08-14 Game character action control method, device, equipment and medium

Country Status (1)

Country Link
CN (1) CN112090076B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024125388A1 (en) * 2022-12-15 2024-06-20 完美世界(北京)软件科技发展有限公司 Character partial animation implementation method and apparatus, computer device, and storage medium

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1975785A (en) * 2006-12-19 2007-06-06 北京金山软件有限公司 Skeleton cartoon generating, realizing method/device, game optical disk and external card
CN101079154A (en) * 2007-03-02 2007-11-28 腾讯科技(深圳)有限公司 Role animation realization method and system
CN102640187A (en) * 2009-12-07 2012-08-15 微软公司 Visual target tracking
CN103038727A (en) * 2010-06-29 2013-04-10 微软公司 Skeletal joint recognition and tracking system
US20140011585A1 (en) * 2012-07-03 2014-01-09 Kabushiki Kaisha Square Enix (Also Trading As Square Enix Co., Ltd.) Game apparatus
US20140232650A1 (en) * 2013-02-15 2014-08-21 Microsoft Corporation User Center-Of-Mass And Mass Distribution Extraction Using Depth Images
CN104463146A (en) * 2014-12-30 2015-03-25 华南师范大学 Posture identification method and device based on near-infrared TOF camera depth information
CN105252532A (en) * 2015-11-24 2016-01-20 山东大学 Method of cooperative flexible attitude control for motion capture robot
CN106780683A (en) * 2017-02-23 2017-05-31 网易(杭州)网络有限公司 The processing method and processing device of bone animation data
CN106984045A (en) * 2017-04-13 2017-07-28 网易(杭州)网络有限公司 Method, device, storage medium and the games system of game role action control
CN107551542A (en) * 2017-08-11 2018-01-09 杭州电魂网络科技股份有限公司 A kind of control method and device of virtual role
CN109032339A (en) * 2018-06-29 2018-12-18 贵州威爱教育科技有限公司 A kind of method and system that real-time intelligent body-sensing is synchronous

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1975785A (en) * 2006-12-19 2007-06-06 北京金山软件有限公司 Skeleton cartoon generating, realizing method/device, game optical disk and external card
CN101079154A (en) * 2007-03-02 2007-11-28 腾讯科技(深圳)有限公司 Role animation realization method and system
CN102640187A (en) * 2009-12-07 2012-08-15 微软公司 Visual target tracking
CN103038727A (en) * 2010-06-29 2013-04-10 微软公司 Skeletal joint recognition and tracking system
US20140011585A1 (en) * 2012-07-03 2014-01-09 Kabushiki Kaisha Square Enix (Also Trading As Square Enix Co., Ltd.) Game apparatus
US20140232650A1 (en) * 2013-02-15 2014-08-21 Microsoft Corporation User Center-Of-Mass And Mass Distribution Extraction Using Depth Images
CN104463146A (en) * 2014-12-30 2015-03-25 华南师范大学 Posture identification method and device based on near-infrared TOF camera depth information
CN105252532A (en) * 2015-11-24 2016-01-20 山东大学 Method of cooperative flexible attitude control for motion capture robot
CN106780683A (en) * 2017-02-23 2017-05-31 网易(杭州)网络有限公司 The processing method and processing device of bone animation data
CN106984045A (en) * 2017-04-13 2017-07-28 网易(杭州)网络有限公司 Method, device, storage medium and the games system of game role action control
CN107551542A (en) * 2017-08-11 2018-01-09 杭州电魂网络科技股份有限公司 A kind of control method and device of virtual role
CN109032339A (en) * 2018-06-29 2018-12-18 贵州威爱教育科技有限公司 A kind of method and system that real-time intelligent body-sensing is synchronous

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024125388A1 (en) * 2022-12-15 2024-06-20 完美世界(北京)软件科技发展有限公司 Character partial animation implementation method and apparatus, computer device, and storage medium

Also Published As

Publication number Publication date
CN112090076B (en) 2022-02-01

Similar Documents

Publication Publication Date Title
US9240067B2 (en) Animation of photo-images via fitting of combined models
CN108335345B (en) Control method and device of facial animation model and computing equipment
JP5137970B2 (en) Reality enhancement method and apparatus for automatically tracking textured planar geometric objects in real time without marking in a video stream
US8395620B2 (en) Method and system for tracking of a subject
CN111773724B (en) Method and device for crossing virtual obstacle
US9208613B2 (en) Action modeling device, method, and program
JP3853329B2 (en) GAME PROGRAM AND GAME DEVICE
CN112684970B (en) Adaptive display method and device of virtual scene, electronic equipment and storage medium
US11816772B2 (en) System for customizing in-game character animations by players
JP2007151647A (en) Image processing apparatus and method and program
CN112927332B (en) Bone animation updating method, device, equipment and storage medium
US20230394735A1 (en) Enhanced animation generation based on video with local phase
JP2008090498A (en) Image processing method and image processor
CN112090076B (en) Game character action control method, device, equipment and medium
US9827495B2 (en) Simulation device, simulation method, program, and information storage medium
CN112843704B (en) Animation model processing method, device, equipment and storage medium
CN114053696A (en) Image rendering processing method and device and electronic equipment
US10099135B2 (en) Relative inverse kinematics graphical user interface tool
US20230360348A1 (en) Method and apparatus for generating main control object projection, device, and medium
CN111489426A (en) Expression generation method, device, equipment and storage medium
JP2023089947A (en) Feature tracking system and method
US20220172431A1 (en) Simulated face generation for rendering 3-d models of people that do not exist
JP4930373B2 (en) Image processing program and image processing system using the same
JP6576544B2 (en) Information processing apparatus, information processing method, and computer-readable storage medium
CN111013152A (en) Game model action generation method and device and electronic terminal

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant