Virtual role control method and device, computer equipment and storage medium

文档序号:1148894 发布日期:2020-09-15 浏览:15次 中文

阅读说明:本技术 虚拟角色控制方法、装置、计算机设备和存储介质 (Virtual role control method and device, computer equipment and storage medium ) 是由 郭畅 于 2020-07-02 设计创作,主要内容包括:本申请涉及一种虚拟角色控制方法、装置、计算机设备和存储介质。所述方法包括:在虚拟场景中显示目标虚拟角色的至少一部分;所述目标虚拟角色绑定有基础骨骼和变形骨骼;在所述虚拟场景中触发所述目标虚拟角色的角色动作;当所述角色动作包括角色运动时,通过所述角色运动所关联基础骨骼的运动,控制所述目标虚拟角色在所述虚拟场景中实施所述角色运动;当所述角色动作包括角色局部变形时,通过所述角色局部变形所关联变形骨骼的变形,控制所述目标虚拟角色在所述虚拟场景中实施所述角色局部变形。采用本申请的方法能够提高虚拟角色控制效率。(The application relates to a virtual character control method, a virtual character control device, computer equipment and a storage medium. The method comprises the following steps: displaying at least a portion of a target avatar in a virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton; triggering a role action of the target virtual role in the virtual scene; when the role action comprises role movement, controlling the target virtual role to implement the role movement in the virtual scene through the movement of a basic skeleton associated with the role movement; when the role action comprises role local deformation, controlling the target virtual role to implement the role local deformation in the virtual scene through deformation of a deformed skeleton associated with the role local deformation. By adopting the method, the virtual role control efficiency can be improved.)

1. A method for controlling a virtual character, the method comprising:

displaying at least a portion of a target avatar in a virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton;

triggering a role action of the target virtual role in the virtual scene;

when the role action comprises role movement, controlling the target virtual role to implement the role movement in the virtual scene through the movement of a basic skeleton associated with the role movement;

when the role action comprises role local deformation, controlling the target virtual role to implement the role local deformation in the virtual scene through deformation of a deformed skeleton associated with the role local deformation.

2. The method of claim 1, wherein the movement of the underlying bone comprises at least one of bone movement and bone rotation; the deformation of the deformed bone includes at least one of local bone expansion and contraction and global bone contraction.

3. The method of claim 1, wherein the target virtual character is generated by a character construction step comprising:

creating a base skeleton of a target virtual character, the base skeleton comprising more than one base skeleton;

adding at least one deformed bone to the base skeleton;

and performing skin covering treatment on the basic skeleton added with the deformed skeleton to obtain the target virtual role.

4. The method of claim 3, further comprising:

leading the target virtual role subjected to skin treatment into a three-dimensional engine as a model;

generating the model into a preform by the three-dimensional engine;

importing an animation configuration file of the prefabricated member in a three-dimensional engine;

and calling the prefabricated part through the three-dimensional engine to generate a target virtual character under a virtual scene, and controlling the target virtual character to implement character action through the action parameter value of the animation configuration file.

5. The method of claim 3, wherein said adding at least one deformed bone to said base skeleton comprises:

determining a target basic skeleton in the basic skeletons;

determining the number of deformed bones according to the length of the target basic bones;

adding a deformed bone of the number of deformed bones connected in sequence at a position of the target basic bone on the basic skeleton.

6. The method of claim 1, further comprising:

displaying a thumbnail object of a target virtual character on the character action map;

controlling the thumbnail object to move within the action range of the thumbnail object;

and when the movement of the thumbnail object meets the role interaction triggering condition, switching to a virtual scene for role interaction.

7. The method of claim 1, further comprising:

loading a prefabricated part through a three-dimensional engine in a virtual scene; the prefabricated part is obtained by erecting a deformed skeleton on a basic skeleton of the target virtual role and then performing covering treatment;

and creating an example through the prefabricated member to obtain the target virtual role.

8. The method of claim 1, wherein the virtual scene is an animated editing scene, the method further comprising:

in the virtual scene, when the target virtual character implements the character action, recording a key frame of the target virtual character in the process of implementing the character action;

and generating video animation based on the key frame.

9. The method of claim 8, further comprising:

displaying a thumbnail object of a target virtual character on the character action map;

controlling the thumbnail object to move within the action range of the thumbnail object;

when the movement of the thumbnail object meets a role interaction triggering condition, switching to a role interaction scene;

and playing the video animation when the role action of the target virtual role is triggered in the role interaction scene.

10. An apparatus for controlling a virtual character, the apparatus comprising:

a display module to display at least a portion of a target virtual character in a virtual scene; the target virtual role binds a basic skeleton and a deformed skeleton;

the action triggering module is used for triggering the role action of the target virtual role in the virtual scene;

the control module is used for controlling the target virtual character to implement the character movement in the virtual scene through the movement of a basic skeleton associated with the character movement when the character movement comprises the character movement;

the control module is used for controlling the target virtual character to implement the local character deformation in the virtual scene through the deformation of the deformed skeleton associated with the local character deformation when the character action comprises the local character deformation.

11. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor realizes the steps of the method of any one of claims 1 to 9 when executing the computer program.

12. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 9.

Technical Field

The present application relates to the field of computer technologies, and in particular, to a method and an apparatus for controlling a virtual character, a computer device, and a computer storage medium.

Background

When animating a character, some shots in the animation are needed to highlight special effects of the character. For example, when a hand of a character expands, a trunk expands, and the like, and special deformation is required, it is a conventional practice to deform a corresponding part of the character by manually drawing the part of model animation. However, the conventional virtual character control method has the problem of low virtual character control efficiency.

Disclosure of Invention

In view of the above, it is desirable to provide a method, an apparatus, a computer device, and a storage medium for controlling a virtual character, which can improve the virtual character control efficiency.

A virtual character control method, the method comprising:

displaying at least a portion of a target avatar in a virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton;

triggering a role action of the target virtual role in the virtual scene;

when the role action comprises role movement, controlling the target virtual role to implement the role movement in the virtual scene through the movement of a basic skeleton associated with the role movement;

when the role action comprises role local deformation, controlling the target virtual role to implement the role local deformation in the virtual scene through deformation of a deformed skeleton associated with the role local deformation.

A virtual character control apparatus, the apparatus comprising:

a display module to display at least a portion of a target virtual character in a virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton;

the action triggering module is used for triggering the role action of the target virtual role in the virtual scene;

the control module is used for controlling the target virtual character to implement the character movement in the virtual scene through the movement of a basic skeleton associated with the character movement when the character movement comprises the character movement;

the control module is used for controlling the target virtual character to implement the local character deformation in the virtual scene through the deformation of the deformed skeleton associated with the local character deformation when the character action comprises the local character deformation.

In one embodiment, the movement of the underlying bone includes at least one of bone movement and bone rotation; the deformation of the deformed bone includes at least one of local bone expansion and contraction and global bone contraction.

In one embodiment, the virtual character control apparatus further includes a character construction module. The role building module is used for creating a basic skeleton of the target virtual role, and the basic skeleton comprises more than one basic skeleton; adding at least one deformed bone to the base skeleton; and performing skin covering treatment on the basic skeleton added with the deformed skeleton to obtain the target virtual role.

In one embodiment, the role construction module is further configured to import the skinned target virtual role into the three-dimensional engine as a model; generating the model into a preform by the three-dimensional engine; importing an animation configuration file of the prefabricated member in a three-dimensional engine; calling the prefabricated member to generate a target virtual character under a virtual scene through the three-dimensional engine; the control module is used for controlling the target virtual character to implement the character action according to the action parameter value of the animation configuration file.

In one embodiment, the role construction module is further configured to determine a target basic skeleton in the basic skeleton; determining the number of deformed bones according to the length of the target basic bones; adding a deformed bone of the number of deformed bones connected in sequence at a position of the target basic bone on the basic skeleton.

In one embodiment, the character building module is further configured to load the prefabricated part in the virtual scene through a three-dimensional engine; the prefabricated part is obtained by erecting a deformed skeleton on a basic skeleton of the target virtual role and then performing covering treatment; and creating an example through the prefabricated member to obtain the target virtual role.

In one embodiment, the virtual object control device further comprises an animation generation module, wherein the animation generation module is used for recording a key frame of the target virtual character in the process of implementing the character action in the virtual scene when the target virtual character is in the process of implementing the character action; and generating video animation based on the key frame.

In one embodiment, the control module is further configured to display a thumbnail object of the target virtual character on the character action map; controlling the thumbnail object to move within the action range of the thumbnail object; when the movement of the thumbnail object meets a role interaction triggering condition, switching to a role interaction scene; and playing the video animation when the role action of the target virtual role is triggered in the role interaction scene.

A computer device comprising a memory and a processor, the memory storing a computer program, the processor implementing the following steps when executing the computer program:

displaying at least a portion of a target avatar in a virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton;

triggering a role action of the target virtual role in the virtual scene;

when the role action comprises role movement, controlling the target virtual role to implement the role movement in the virtual scene through the movement of a basic skeleton associated with the role movement;

when the role action comprises role local deformation, controlling the target virtual role to implement the role local deformation in the virtual scene through deformation of a deformed skeleton associated with the role local deformation.

A computer-readable storage medium, on which a computer program is stored which, when executed by a processor, carries out the steps of:

displaying at least a portion of a target avatar in a virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton;

triggering a role action of the target virtual role in the virtual scene;

when the role action comprises role movement, controlling the target virtual role to implement the role movement in the virtual scene through the movement of a basic skeleton associated with the role movement;

when the role action comprises role local deformation, controlling the target virtual role to implement the role local deformation in the virtual scene through deformation of a deformed skeleton associated with the role local deformation.

According to the virtual character control method, the virtual character control device, the computer equipment and the storage medium, the target virtual character is bound with the basic skeleton and the deformed skeleton, when the character action triggered in the virtual scene comprises character movement, the target virtual character is controlled to implement the character movement through the movement of the basic skeleton, and when the character action triggered in the virtual scene comprises local character deformation, the local character deformation is implemented through the deformation of the deformed skeleton.

Drawings

FIG. 1 is a diagram of an application environment of a virtual role control method in one embodiment;

FIG. 2 is a flowchart illustrating a virtual character control method according to an embodiment;

FIG. 3 is a schematic flow chart illustrating the generation of a target avatar in a virtual scene in one embodiment;

FIG. 4 is a flowchart illustrating a virtual character control method according to another embodiment;

FIG. 5 is a schematic diagram of an interface of a virtual scene of character interaction in one embodiment;

FIG. 6 is a schematic interface diagram of a virtual scene of character interaction in another embodiment;

FIG. 7 is a diagram illustrating a hand deformation of a virtual character in one embodiment;

FIG. 8 is a diagram illustrating a base skeleton corresponding to a target virtual character in one embodiment;

FIG. 9 is a schematic view of a base skeleton with deformed bone added in one embodiment;

FIG. 10 is a diagram of a target avatar after skinning in one embodiment;

FIG. 11 is a schematic illustration of a positional interface of a deformed bone according to one embodiment;

FIG. 12 is a schematic illustration of controlling deformation of a deformed bone according to one embodiment;

FIG. 13 is a diagram of a target avatar displayed in the three-dimensional engine, in one embodiment;

FIG. 14 is a diagram illustrating a hand enlarging a target virtual character in one embodiment;

FIG. 15 is a block diagram showing the configuration of a virtual character control apparatus according to an embodiment;

FIG. 16 is a diagram illustrating an internal structure of a computer device according to an embodiment.

Detailed Description

In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.

The virtual role control method provided by the application can be applied to the application environment shown in fig. 1. Wherein the terminal device 110 communicates with the server 120 over a network. Wherein, the terminal device 110 may be but is not limited to: the intelligent terminal comprises intelligent terminals such as a smart phone, a tablet computer, a notebook computer, a desktop computer and an intelligent television. The terminal device 110 is provided with a client, and the client may be used to play videos and the like, for example, the videos are played through a video client, an instant messaging client, a browser client, an education client and the like. The server 120 may be an independent physical server, a server cluster or a distributed system formed by a plurality of physical servers, or a cloud server providing basic cloud computing services such as a cloud service, a cloud database, cloud computing, a cloud function, cloud storage, a network service, cloud communication, middleware service, a domain name service, a security service, a CDN, a big data and artificial intelligence platform, and the like. The number of the terminal devices and the number of the servers are not limited. Wherein the server 120 is operable to send the action parameter value to the terminal device, and the action parameter value is operable to enable the terminal device 110 to control the target virtual character to complete the character action. The terminal device 110 is configured to display at least a part of the target avatar in the virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton; triggering role actions of a target virtual role in a virtual scene; when the role action comprises role movement, controlling a target virtual role to implement the role movement in a virtual scene through the movement of a basic skeleton associated with the role movement; when the role action comprises role local deformation, the target virtual role is controlled to implement the role local deformation in the virtual scene through deformation of a deformed skeleton associated with the role local deformation.

In an embodiment, as shown in fig. 2, a virtual role control method is provided, where the method may be executed by a terminal device or a server, or may be executed by both the terminal device and the server, and the method is described as an example where the method is executed by the terminal device 110, and includes the following steps:

step 202, displaying at least one part of a target virtual character in a virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton.

The virtual scene can be used for simulating a three-dimensional virtual space and can also be used for simulating a two-dimensional virtual space. The virtual scene may include, but is not limited to, sky, land, sea, buildings, mountain forest, target virtual characters, and the like. The virtual scene may be shown after the application is opened, such as after a game is opened. The target virtual character is an active character in the virtual scene. The target avatar may be used to represent an avatar of the user in the virtual scene. The target virtual character may specifically be a target virtual character, a target virtual animal, or the like, but is not limited thereto.

The basic skeleton is used for enabling the target virtual character to realize character movement. The character movement comprises the actions of advancing, retreating, turning, running and the like. The underlying skeleton may specifically be a CS (Character Studio) skeleton. The morphing skeleton is used to morph the target virtual character to implement the character. Character morphing may include, but is not limited to, zooming in, zooming out, telescoping, and the like. The deformed bone may in particular be a dummy bone. In the present application, the basic skeleton and the deformed skeleton may be collectively referred to as a skeleton. Each bone has a unique corresponding bone identifier for distinguishing different bones.

Specifically, the terminal device displays at least a part of the target virtual character in the virtual scene. At least a portion of the target avatar may be, but is not limited to, a head of the target avatar, an avatar of the target avatar, or a side view of the target avatar.

And step 204, triggering role actions of the target virtual role in the virtual scene.

Wherein the character action is used to make the target virtual character move in the virtual scene. The character motion may be, for example, forward, backward, turn, run, zoom in, zoom out, zoom in, release skill, etc., but is not limited thereto.

Specifically, when a role control operation on the target virtual role is detected, a role action of the target virtual role corresponding to the role control operation is triggered in the virtual scene. For example, if w corresponds to forward, s corresponds to backward, a corresponds to movement in a direction, and d corresponds to movement in a right direction, which are input through a keyboard of the terminal device, when a control operation on a w key of a target virtual character is detected, a forward action of the target virtual character corresponding to w is triggered in a virtual scene.

And step 206, when the role action comprises role movement, controlling the target virtual role to implement the role movement in the virtual scene through the movement of the basic skeleton associated with the role movement.

Wherein, each basic skeleton has a unique corresponding basic skeleton identification. Character movement-associated basic skeleton may be, for example, a basic skeleton of a character limb, a basic skeleton including only legs, or the like, without being limited thereto.

Specifically, when the role action triggered in the virtual scene includes role movement, the terminal device may determine, through the basic skeleton identifier associated with the role movement, the basic skeleton associated with the role movement. The terminal equipment controls the target virtual role to implement role movement in the virtual scene through the movement of the basic skeleton associated with the role movement. Taking the role movement as walking and the basic skeleton associated with walking as the basic skeleton of four limbs as an example for explanation, the terminal device controls the target virtual role to implement role walking in the virtual scene through the swing of the basic skeleton of four limbs associated with the role movement.

And step 208, when the role action comprises role local deformation, controlling the target virtual role to implement the role local deformation in the virtual scene through deformation of a deformed skeleton associated with the role local deformation.

Wherein each deformed bone has a unique corresponding deformed bone identifier. The local deformation of the character may be deformation of a part of the body of the character, deformation of a weapon of the character, or the like. The deformed skeleton associated with the local deformation of the role can be set according to the needs of the role. The deformed skeleton associated with the local deformation of the character may be set as needed, and may be specifically set according to the type of the virtual character, and the like. For example, the deformed skeleton associated with the type a of the virtual character is a deformed skeleton at the neck, and the deformed skeleton associated with the type B of the virtual character is a deformed skeleton at the limbs, and the like are not limited thereto.

Specifically, when the role action triggered in the virtual scene includes role local deformation, the terminal device may determine a deformed skeleton associated with the role movement through a deformed skeleton identifier associated with the role movement. The terminal equipment controls the target virtual role to implement role local deformation in the virtual scene through deformation of the deformed skeleton associated with the role local deformation. For example, taking the case where the character local deformation is a right arm enlargement and the deformed skeleton associated with the right arm enlargement is a right arm deformed skeleton, the terminal device controls the target virtual character to perform the right arm enlargement in the virtual scene by enlarging the associated right arm deformed skeleton.

In this embodiment, when the role action includes role movement and role local deformation, the terminal device controls the target virtual role to implement the role movement in the virtual scene through movement of a basic skeleton associated with the role movement, and the terminal device controls the target virtual role to implement the role local deformation in the virtual scene through deformation of a deformed skeleton associated with the role local deformation.

In this embodiment, the type of the local deformation of the character may be at least one. For example, the local deformation of the role comprises local deformation X and local deformation Y, the local deformation X can be triggered by an X key of a keyboard, and the deformed skeleton associated with the local deformation X is a deformed skeleton of four limbs; the Y local deformation can be triggered by a Y key of the keyboard, and the deformed skeleton associated with the Y local deformation is the head deformed skeleton. Then when the character action comprises an X local deformation, the control target virtual character implements the character limb deformation in the virtual scene through the deformation of the limb deformation skeleton associated with the X local deformation. When the character action comprises Y local deformation, the target virtual character is controlled to implement character head deformation in the virtual scene through the deformation of the head deformation skeleton associated with the Y local deformation.

In this embodiment, for example, when the character action triggering the target virtual character in the game is to release a skill, and when the skill includes a character motion, for example, the character motion is a kicking, the target virtual character is controlled to implement the kicking action in the game through the motion of a leg basic skeleton associated with the kicking; when the skill further includes thickening of the leg, that is, when the skill is a leg thickening while kicking, the control target virtual character performs leg deformation during the game by enlarging the leg deformation skeleton associated with the thickening of the leg. In the above example, the game is a virtual scene, the release skill is a character motion, the kicking is a character motion, and the leg thickening is a local deformation of the character.

According to the virtual character control method, the target virtual character is bound with the basic skeleton and the deformed skeleton, when the character action triggered in the virtual scene comprises character movement, the target virtual character is controlled to implement the character movement through the movement of the basic skeleton, when the character action triggered in the virtual scene comprises local character deformation, the local character deformation is implemented through the deformation of the deformed skeleton, compared with a mode of manually drawing an animation of the virtual character in the prior art, the virtual character control efficiency can be improved, meanwhile, as the target virtual character is controlled through the basic skeleton and the deformed skeleton, too many images do not need to be stored, and the occupied storage space can be reduced.

In one embodiment, the movement of the underlying bone includes at least one of bone movement and bone rotation; the deformation of the deformed bone includes at least one of local expansion and contraction of the bone and global scaling of the bone.

In particular, bone movement refers to the movement of bone from one location to another location in a virtual scene. Bone rotation means that the bone moves around the axis but does not change position. Partial bone contraction refers to lengthening or shortening one end of the bone. The bone whole zoom means that the bone is wholly enlarged or wholly reduced. The motion of the underlying bone may include only bone movement, or only bone rotation, or both bone movement and bone rotation. The deformation of the deformed bone may include only local bone expansion or only global bone contraction or both.

According to the virtual character control method, the movement of the basic skeleton comprises at least one of skeleton movement and skeleton rotation, the deformation of the deformed skeleton comprises at least one of skeleton local expansion and skeleton whole scaling, namely the basic skeleton and the deformed skeleton can respectively realize different functions, so that different character actions of the target virtual character are realized, and the interactivity of the virtual character is improved.

In one embodiment, the target virtual character is generated by a character construction step comprising: creating a base skeleton of the target virtual character, the base skeleton comprising more than one base skeleton; adding at least one deformed bone to the base skeleton; and carrying out skinning treatment on the basic skeleton added with the deformed skeleton to obtain the target virtual role.

The virtual roles can move in the virtual scene through the basic framework. The basic skeleton includes at least one basic skeleton. The skin can be added to the skeleton by a skinning treatment.

Specifically, the terminal device creates a virtual skeleton of the target virtual character, and the basic skeleton comprises more than one basic skeleton. The terminal equipment adds at least one deformed skeleton on the basis of the basic skeleton. For example, the terminal device may add deformed bone to the extremities of the base skeleton. And the terminal equipment carries out skinning treatment on the basic skeleton added with the deformed skeleton to obtain the target virtual role.

In this embodiment, after the skin treatment is performed on the basic skeleton added with the deformed skeleton, the terminal device performs the mapping treatment to obtain the target virtual character.

In this embodiment, the terminal device may adjust the virtual skeleton of the target virtual character according to actual requirements. For example, adjusting the length, size, etc. of each bone in the virtual skeleton, or adding a base bone and reducing a base bone, etc.

According to the virtual character control method, the basic skeleton of the target virtual character is created, at least one deformed skeleton is added to the basic skeleton, the basic skeleton added with the deformed skeleton is subjected to skinning processing to obtain the target virtual character, deformation of the target virtual character can be achieved by erecting the deformed skeleton, and occupied storage space is reduced.

In one embodiment, as shown in fig. 3, a flowchart of generating a target virtual character in a virtual scene in one embodiment is shown. The virtual role control method further comprises the following steps:

step 302, importing the target virtual character subjected to skin treatment into a three-dimensional engine as a model.

The three-dimensional engine can be used for developing stand-alone games of Windows, MacOS and Linux platforms, video games of game host platforms such as PlayStation, XBox, Wii, 3DS and Nintendo Switch, and games of mobile equipment such as iOS and Android. The game platform supported by Unity also extends to an HTML5 webpage platform based on WebGL technology, and a new generation multimedia platform such as tvOS, Oculus Rift, ARKit and the like. In addition to being used for developing electronic games, Unity is also a comprehensive authoring tool widely used for interactive contents of building visualization, real-time three-dimensional animation and the like.

Specifically, the terminal device takes the skinned target virtual character as a model and introduces the model into the three-dimensional engine. The target virtual character may be displayed in the three-dimensional engine.

At step 304, the model is generated into a preform by a three-dimensional engine.

The prefabricated member can be prefab, which can be regarded as an assembly template used for batch applying work. For example, in a virtual scene, a model which needs to be reused, such as an enemy, a soldier, a weapon, a bullet or any wall body which is completely the same as the brick, etc. prefab looks like a clone, but the position, angle, or some property generated is different, just like a c + + inner edge class.

Specifically, the terminal device generates the model into a preform by a three-dimensional engine.

Step 306, importing the animation configuration file of the prefabricated member in the three-dimensional engine.

The animation configuration file can comprise animation parameters for controlling the basic skeleton and the deformed skeleton, and can also comprise a target virtual character to implement the character action process.

Specifically, the terminal device imports an animation configuration file of the preform into the three-dimensional engine.

And 308, calling the prefabricated part through the three-dimensional engine to generate a target virtual character under the virtual scene, and controlling the target virtual character to implement the character action through the action parameter value of the animation configuration file.

The action parameter value is used for expressing at least one of a movement parameter value of a basic skeleton, a rotation parameter value of the basic skeleton, a stretching parameter value of a deformed skeleton and a scaling parameter value of the deformed skeleton in the target virtual character. The action parameter value can be sent to the terminal device by the server or stored by the terminal device. And the terminal equipment realizes the motion of the related skeleton through the motion parameter value and controls the target virtual role to implement role motion. The associated bone may be at least one of a basic bone and a deformed bone.

Specifically, the prefab such as prefab is called through the three-dimensional engine to generate a target virtual character in a virtual scene, the target virtual character is configured based on the parameter values of the imported animation configuration file, and the target virtual character is controlled to implement character actions through the parameter values of the animation configuration file. For example, the terminal device generates an animation configuration file through 3DS max software, the animation configuration file of the prefabricated part is imported into the three-dimensional engine, and the action parameter values of each skeleton in the animation configuration file can be analyzed through the three-dimensional engine, so that the basic skeleton and the deformed skeleton can be controlled based on the action parameter values, and the target virtual character implements the character action.

According to the virtual character control method, the target virtual character subjected to skin treatment is taken as a model and is led into the three-dimensional engine, the model is used for generating the prefabricated part through the three-dimensional engine, the animation configuration file is led in, the prefabricated part is called to generate the target virtual character under the virtual scene, the action parameter value of the animation configuration file is used for controlling the target virtual character to implement the character action, the target virtual character can be controlled through the action parameter value to realize deformation, a plurality of images do not need to be stored, and the occupied storage space is reduced.

In one embodiment, as shown in fig. 4, a flowchart of a virtual character control method in another embodiment is shown. After start, enter 3DS MAX software. Among them, the 3DS MAX is also called 3D Studio MAX, often referred to as 3D MAX or 3dsMAX for short, and is a three-dimensional animation rendering and producing software based on a PC (Personal Computer) system. The step of erecting the skeleton for the diagonal comprises the following steps: and creating a basic skeleton of the target virtual character, wherein the basic skeleton comprises more than one basic skeleton, and at least one deformed skeleton is added to the basic skeleton. The skin binding comprises the following steps: and covering and binding the basic skeleton added with the deformed skeleton to obtain the target virtual role. The model import unit comprises the following steps: and taking the target virtual role after skinning processing as a model and importing the model into unity. Wherein unity is a three-dimensional engine. The manufacturing of prefab includes: the model is generated as prefab by a three-dimensional engine. Namely, pre fab includes the erected skeleton, skin bindings, and models. Where prefab is a preform. Animation import unit is the animation configuration file for importing the prefabricated member in the unit. Parsing the animation configuration file may show the artistic effect and animation effect of the target virtual character. Configuration refers to configuring prefab and animation configuration files together in unity. And calling the prefabricated member by the program to generate a target virtual character under the virtual scene, and controlling the target virtual character to implement the character action through the action parameter value of the animation configuration file.

In one embodiment, adding at least one deformed bone to the base skeleton comprises: determining a target basic skeleton in the basic skeleton; determining the number of deformed bones according to the length of a target basic bone; at the position of the target basic skeleton on the basic skeleton, deformed bones of the number of deformed bones connected in order are added.

Wherein, the position corresponding to the target basic skeleton is the position corresponding to the deformed skeleton to be added. The number of target underlying bones is not limited. And the target basic skeleton is at least one basic skeleton preset in the basic skeleton.

Specifically, the terminal device determines a target basic skeleton in the basic skeleton. The target basic skeleton may be a preset basic skeleton, such as a basic skeleton at a limb. Or the terminal equipment can determine a target basic skeleton in the basic skeleton according to the type of the virtual role. For example, if the virtual character is a virtual character, then the target underlying skeleton may be an arm; the virtual character is a virtual monster and the target underlying skeleton may be a leg.

And the terminal equipment determines the number of deformed bones according to the length of the target basic bones. At the position of the target basic skeleton on the basic skeleton, deformed bones of the number of deformed bones connected in order are added. For example, the target avatar is a virtual character, the target base skeleton may be an arm skeleton, and the target base skeleton is four pieces. Then two deformed bones can be erected on the basic skeleton of each program mark according to the length of the target basic skeleton. Since the deformed skeleton is a cube, if only one deformed skeleton is erected on one target base skeleton, the arm of the virtual character may be thick, and thus the number of deformed skeletons needs to be adjusted based on the design size of the arm of the target virtual character.

According to the virtual character control method, the number of the deformed bones is determined according to the length of the target basic bones, and the deformed bones of the number of the deformed bones which are sequentially connected are added at the position of the target basic bones on the basic skeleton, so that the number of the deformed bones is more matched with the virtual character, and the fidelity of the obtained target virtual character can be improved.

In one embodiment, the virtual character control method further includes: displaying a thumbnail object of a target virtual character on the character action map; controlling the movement of the abbreviated object in the action range of the abbreviated object; and when the movement of the thumbnail object meets the role interaction triggering condition, switching to a virtual scene for role interaction.

The character action map is used for displaying the action range of the target virtual character on the electronic map. The virtual scene may be, but not limited to, RPG (Role-playing game), SRPC (game Role-playing game), and the like. The thumbnail object is the reduced image of the target virtual character. The thumbnail objects may be used to perform a character action on the character action map. The virtual scene of character interaction means that the virtual scene comprises at least two virtual characters, wherein one virtual character is a target virtual character, and the target virtual character can interact with another virtual character in the virtual scene.

Specifically, the terminal device displays a thumbnail object of the target virtual character on the character action map. When the movement operation of the thumbnail object is detected, the terminal device controls the thumbnail object to move in the action range of the thumbnail object. When the movement of the thumbnail object satisfies the interaction triggering condition, the interaction triggering condition is, for example, that the terminal device switches to a virtual scene in which the Character interacts when the target virtual Character meets other virtual characters in other camps, or the target virtual Character falls within an attack range of other virtual characters in other camps, or the target virtual Character meets an NPC (Non-Player Character) in battle, or the terminal device triggers a skill releasing operation or a playing olympic operation, but is not limited thereto. The terminal device displays at least one part of a target virtual character in a virtual scene of character interaction, the target virtual character is bound with a basic skeleton and a deformed skeleton, the character action of the target virtual character is triggered in the virtual scene, and when the character action comprises character movement, the target virtual character is controlled to implement the character movement in the virtual scene of character interaction through the movement of the basic skeleton associated with the character movement; when the role action comprises role local deformation, the target virtual role is controlled to implement the role local deformation in the virtual scene through the deformation of the deformed skeleton associated with the role local deformation.

For example, in a battle chess game, a thumbnail object of royy is displayed on a map of the battle chess game, and the thumbnail object is controlled to move within the action range of a displayed square. When the Roy thumbnail object moves to a position where a robust work is spacious, the skill needs to be released or the Olympic content needs to be played, at the moment, the body of the Roy thumbnail object needs to be exaggeratedly deformed, and the Roy thumbnail object needs to be switched into a virtual scene of character interaction as shown in FIG. 5. FIG. 5 is a diagram of an interface of a virtual scene with which characters interact according to an embodiment. FIG. 6 is a schematic interface diagram of a virtual scene with which characters interact in another embodiment. A portion of the leg, head, body, and hand of roy are shown in the virtual scene of fig. 5. And when the character action triggered in the battle chess game comprises the enlargement of the hand, the skeleton related to the enlargement of the hand, for example, the skeleton at the palm, is enlarged, so that the control Roy implements the enlargement of the hand in the interaction process of the battle chess game. While a portion of the right arm, a portion of the left arm, the left hand, the upper body, and the left palm of roy are shown in the virtual scene of fig. 6. And when the character action triggered in the battle chess game comprises arm thickening, the rib related to the hand thickening, such as the rib on the arm, is enlarged, so that the Roy is controlled to implement the arm thickening in the interactive process of the battle chess game. In the above example, the battle chess game is a virtual scene, roy is a target virtual character, a role interaction triggering condition is set when a reduced object of roy moves to a robust spacious work position, the behavior range of the displayed grid is the action direction of the reduced object, the character is locally deformed to become larger hands and thicker arms, and the virtual scene is the battle chess game.

According to the virtual character control method, the thumbnail objects are controlled to move in the corresponding action ranges, and when the thumbnail objects move to meet the character interaction triggering conditions, the virtual character control method is switched to the character interaction scene, so that the interactivity in the virtual scene can be enhanced.

In one embodiment, as shown in FIG. 7, a diagram illustrating a hand deformation of a virtual character in one embodiment is shown. As can be seen from the figure, the hand of the target virtual character is enlarged, and the effect of enlargement is greater than that of the method by the angle of view. The hand in fig. 7 also achieves a local magnification effect of the virtual object by controlling the magnification of the deformed skeleton.

In one embodiment, the virtual character control method further includes: loading a prefabricated part through a three-dimensional engine in a virtual scene; the prefabricated part is obtained by erecting a deformed skeleton on a basic skeleton of a target virtual role and then performing skin covering treatment; and creating an example through the prefabricated member to obtain the target virtual role.

The prefabricated member is obtained by erecting a deformed skeleton on a basic skeleton of a target virtual role and then performing covering treatment. Specifically, in the virtual scene, the terminal device loads the prefabricated part through the three-dimensional engine, and creates an example through the prefabricated part to obtain the target virtual character.

According to the virtual character control method, the prefabricated member is loaded through the three-dimensional engine, the target virtual character is obtained through the prefabricated member creating instance, the fidelity of the target virtual character can be improved, and the user experience is improved.

In one embodiment, the virtual scene is an animated editing scene. The virtual role control method further comprises the following steps: in a virtual scene, when a target virtual character is in the process of implementing the character action, recording a key frame of the target virtual character in the process of implementing the character action; video animations are generated based on the key frames.

The animation editing scene may refer to a scene corresponding to the animation. And recording the action of the target virtual character at the time point of the frame in the key frame. For example, the hand swing, leg deformation, and the like in which the target virtual character is recorded in the key frame are not limited to this. The key frames may or may not be uniformly distributed. For example, frames 1, 10, 20, … … are key frames at frame 100. Uneven distribution, such as frame 1, frame 15, frame 20 … … frame 100, is a key frame.

Specifically, in an animation editing scene, when a target virtual character is in the process of implementing character actions, the terminal device records a key frame of the target virtual character in the process of implementing the character actions, wherein the key frame comprises the action posture of the target virtual character. The terminal device may automatically generate a video animation of successive frames based on the key frames. For example, if the target virtual character implements character movement, recording key frames of the character movement; if the target virtual object implements the local deformation of the role, recording a key frame of the local deformation of the role; and the target virtual object implements character movement and local character deformation, and then recording key frames containing the character movement and the local character deformation.

According to the virtual character control method, in an animation editing scene, when the target virtual character performs the character action, the key frame of the target virtual character in the implementation process is recorded, the video animation is generated based on the key frame, the video animation of the target virtual character in the character action implementing process can be manufactured, the video animation of the virtual character is easy to modify, and the virtual character control efficiency is improved.

In one embodiment, the virtual character control method further includes: displaying a thumbnail object of a target virtual character on the character action map; controlling the movement of the abbreviated object in the action range of the abbreviated object; when the movement of the thumbnail object meets the role interaction triggering condition, switching to a role interaction scene; and when the role action of the target virtual role is triggered in the role interaction scene, playing the video animation.

The role interaction scene comprises at least two virtual roles, wherein one virtual role is a target virtual role, and the target virtual role can interact with another virtual role in the role interaction scene.

Specifically, the terminal device displays a character action map, and displays a thumbnail object of a target virtual character on the character action map. When the movement operation of the thumbnail object is detected, the terminal device controls the thumbnail object to move in the action range of the thumbnail object. When the movement of the thumbnail object meets the interaction triggering condition, the interaction triggering condition is not limited to that, for example, when the target virtual character meets other virtual characters in other camps, or the target virtual character falls within the attack range of other virtual characters in other camps, or the target virtual character meets the NPC of battle, and the terminal device switches to the character interaction scene. And when the role action of the target virtual role is triggered in the role interaction scene, the terminal equipment plays the video animation.

For example, in a battle chess game, a thumbnail object of royy is displayed on a map of the battle chess game, and the thumbnail object is controlled to move within the action range of a displayed square. When the thumbnail object of Roy moves to the position of a robust absenteeism, the scene is switched to the skill release scene. And triggering the role action of the target virtual role in the skill release scene, and playing the video animation generated in the animation editing scene. In the above example, the battle chess game is a virtual scene, the behavior range of the displayed squares is the action direction of the abbreviated object, and the skill release scene is a character interaction scene.

According to the virtual character control method, the movement of the abbreviated object in the corresponding action range is controlled, when the movement of the abbreviated object meets the character interaction triggering condition, the role interaction scene is switched, and when the character action of the target virtual character is triggered under the role interaction scene, the video animation is played, so that the virtual character can realize the deformation effect through the deformed skeleton, and the fidelity of the virtual character is improved.

In one embodiment, a virtual character control method includes the steps of:

step (a1), creating a base skeleton of the target virtual character, the base skeleton comprising more than one base skeleton.

And (a2) determining a target basic skeleton in the basic skeletons.

And (a3) determining the number of deformed bones according to the length of the target basic bones.

A step (a4) of adding deformed bones of the number of deformed bones connected in series at the position of the target basic bone on the basic skeleton.

And (a5) skinning the basic skeleton added with the deformed skeleton to obtain the target virtual character.

And (a6) introducing the skinned target virtual character into a three-dimensional engine as a model.

Step (a7), generating the model into a prefabricated member by a three-dimensional engine.

And (a8) importing the animation configuration file of the prefabricated member in the three-dimensional engine.

And (a9) calling the prefabricated member to generate a target virtual character under the virtual scene through the three-dimensional engine, and controlling the target virtual character to implement the character action through the action parameter value of the animation configuration file.

And a step (a10) of displaying the thumbnail object of the target virtual character on the character action map.

And a step (a11) of controlling the movement of the thumbnail object within the action range of the thumbnail object.

And (a12) switching to a virtual scene for character interaction when the movement of the thumbnail object meets the character interaction triggering condition.

A step (a13) of loading, in a virtual scene, a preform by means of a three-dimensional engine; the prefabricated member is obtained by erecting a deformed skeleton on a basic skeleton of a target virtual role and then performing covering treatment.

And (a14) creating an example through the prefabricated member to obtain the target virtual character.

A step (a15) of displaying at least a part of the target virtual character in the virtual scene. The target virtual role is bound with a basic skeleton and a deformed skeleton.

And (a16) triggering the role action of the target virtual role in the virtual scene.

And (a17) when the character motion includes character motion, controlling the target virtual character to implement the character motion in the virtual scene through the motion of the basic skeleton associated with the character motion.

And a step (a18) of, when the character action includes a character local deformation, controlling the target virtual character to implement the character local deformation in the virtual scene by deformation of a deformed skeleton associated with the character local deformation.

According to the virtual character control method, the basic skeleton of the target virtual character is established, the number of the deformed skeletons is determined based on the target basic skeleton, the number of the deformed skeletons can be more matched with the virtual character, and the fidelity of the obtained target virtual character can be improved; the three-dimensional engine calls the prefabricated member to generate the target virtual character, and the target virtual character is controlled to implement the character action through the action parameter value, so that the virtual character control efficiency can be improved compared with a mode of manually drawing the animation of the virtual character in the prior art, and meanwhile, as the target virtual character is controlled through the basic skeleton and the deformed skeleton, too many images do not need to be stored, and the occupied storage space can be reduced.

In one embodiment, a virtual character control method includes the steps of:

and (b1) displaying at least one part of the target virtual character in the animation editing scene, wherein the target virtual character is bound with the basic skeleton and the deformed skeleton.

And (b2) triggering the character action of the target virtual character in the animation editing scene.

And (b3) when the character motion comprises character motion, controlling the target virtual character to implement the character motion in the animation editing scene through the motion of the basic skeleton related to the character motion.

And (b4) when the character action includes the local character deformation, controlling the target virtual character to implement the local character deformation in the animation editing scene through the deformation of the deformed skeleton associated with the local character deformation.

And (b5) recording key frames of the target virtual character in the process of implementing the character action when the target virtual character is in the process of implementing the character action in the animation editing scene.

And (b6) generating video animation based on the key frame.

And a step (b7) of displaying the thumbnail object of the target virtual character on the character action map.

And (b9) controlling the movement of the thumbnail object in the action range of the thumbnail object.

And (b10) switching to the role interaction scene when the movement of the thumbnail object meets the role interaction triggering condition.

And (b11), playing the video animation when the character action of the target virtual character is triggered in the character interaction scene.

According to the virtual character control method, in an animation editing scene, when a target virtual character performs a character action, a key frame of the target virtual character in the implementation process is recorded, a video animation is generated based on the key frame, the video animation of the target virtual character in the character action implementation process can be manufactured, the video animation of the virtual character is easy to modify, the virtual character control efficiency is improved, a thumbnail object is controlled to move in a corresponding action range, when the movement of the thumbnail object meets a character interaction triggering condition, a character interaction scene is switched, and when the character action of the target virtual character is triggered in the character interaction scene, the video animation is played, so that the virtual character can realize a deformation effect through a deformed skeleton, and the fidelity of the virtual character is improved.

In one embodiment, 3DS MAX: the 3D Studio Max, often referred to as 3D Max or 3ds Max for short, is a three-dimensional animation rendering and producing software developed by the internet corporation (incorporated by Autodesk corporation) based on a PC system. Its predecessor is 3D Studio family software based on DOS operating system. Fig. 8 is a schematic diagram of a basic skeleton corresponding to a target virtual character in one embodiment. Fig. 9 is a schematic view of a basic skeleton with deformed skeleton added in one embodiment. Here, block 902 is illustrated as deformed bone 902. In fig. 9, the left arm of the target avatar includes 4 deformed bones 902, and the right arm also includes 4 deformed bones 902. A block 904 on the head of the target avatar is a special effect hanging point 904 for displaying a bubble box or the like at a corresponding position. Also included in fig. 9 is weapon mounting point 906, at which 906 is a corresponding location to enable mounting of a weapon.

Fig. 10 is a schematic diagram of a target virtual character after skinning in one embodiment. The grid in fig. 10 is the skin (skin) of the target avatar. The target virtual object in fig. 10 has a weapon on the right hand. Through skinning, the target virtual character can be more vivid. The skin may be selected in 3DS MAX software and DQ skin switching may be selected in a double quad number in the parameters. Bones may be added or removed in the software and each bone has a corresponding bone identification. And may set envelope attributes, etc. in the software. And the contents of the selectable display, such as checking color to display vertex weights, displaying colored planes, displaying all Gizmos (small devices), not displaying envelopes in fig. 10, and checking drawing cross-sections and envelopes on top, and setting advanced parameters. High level parameters such as always deform, back transform vertices, etc.

Fig. 11 is a schematic illustration of a positional interface of a deformed bone according to an embodiment. Wherein, finding out the deformed skeleton building point in max software, then selecting a virtual object (English edition: dummy) to drag out the deformed skeleton, adjusting the size of the deformed skeleton, and matching with the virtual role. The deformed skeleton may be arranged at a position corresponding to the basic skeleton and may be arranged according to the muscle tendency of the virtual character.

Fig. 12 is a schematic illustration of the control of deformed bone deformation in one embodiment. After the covering binding is finished, the deformed skeleton can be enlarged and reduced in the 3DS MAX software, and the left arm of the target virtual character can be visually displayed to be enlarged. FIG. 13 is a diagram illustrating a target avatar displayed in the three-dimensional engine in one embodiment. FIG. 14 is a diagram illustrating a hand zooming in on a target virtual character in one embodiment. In fig. 14, a deformed skeleton is bound to the palm portion of the target virtual character, and the hand of the target virtual character is made to exhibit a magnifying effect by controlling the enlargement of the deformed skeleton.

The application also provides an application scene applied to the battle chess game, and the application scene applies the virtual character control method. Specifically, the application of the virtual character control method in the application scenario is as follows: in a battle game project, many characters are in battle, and in the battle of the characters, it is sometimes necessary to play a close-up of Olympic, release skill, release large move, or the like. In some special battles, the expression method of art animation needs to be more exaggerated and powerful, which needs to add local amplification or deformation functions to the arms, fingers, torso, feet and other parts on the basis of traditional animation expression. A CS skeleton for the target virtual character is created, the CS skeleton including more than one CS skeleton. Determining a target CS skeleton in the CS skeleton; determining the number of deformed bones according to the length of the target CS bones; at the position of the target CS bone on the CS skeleton, dummy bones of the number of deformed bones connected in series are added. Covering the CS skeleton added with dummy skeleton to obtain a target virtual role; and taking the target virtual role after skinning processing as a model and importing the model into unity. Generating the model into prefab through unity; importing an animation configuration file of prefab in unity; and invoking prefab through unity to generate a target virtual character under a virtual scene, and controlling the target virtual character to implement character action through the action parameter value of the animation configuration file. Displaying the thumbnail head portrait of the target virtual character on the character action map of the battle chess game; wherein, the thumbnail head portrait is a thumbnail object; controlling the thumbnail head portrait to move in the corresponding movable range; and when the movement of the thumbnail object meets the role interaction triggering condition, namely the skill needs to be released or the ambiguity needs to be played, switching to the battle scene. Displaying at least a portion of a target virtual character in a battle chess game; the target virtual character is bound with a CS skeleton and a dummy skeleton. Taking the role action as a releasing skill and the virtual scene of role interaction as an battle scene as an example, triggering the skill of the target virtual role in the battle virtual scene; when the skill comprises character movement, such as walking, jumping and the like, the target virtual character is controlled to implement the character movement in the battle chess game scene through the movement of the CS skeleton related to the character movement. When the skill comprises local character deformation, such as hand enlargement and the like, the target virtual character is controlled to implement the local character deformation in the battle chess game scene through the deformation of the dummy skeleton associated with the local character deformation. The virtual scene is a battle chess game scene, the CS skeleton is a basic skeleton, the target CS skeleton is a target basic skeleton, the dummy skeleton is a deformed skeleton, the unity is a three-dimensional engine, the prefab is a prefabricated part, the thumbnail head image is a thumbnail object, and the character interaction scene is an battle array scene.

The application also provides an animation editing application scene, and the application scene applies the virtual character control method. When the character animation is manufactured, some scenes in the game need to highlight the special effect of the character, for example, when the extension of hands is increased, the trunk is enlarged, and the part of the character needs special deformation, at least one part of a target virtual character is displayed in an animation editing scene; the target virtual role is bound with a CS skeleton and a dummy skeleton; triggering role actions of a target virtual role in a virtual scene; when the role action comprises role movement, controlling a target virtual role to implement the role movement in an animation editing scene through the movement of a CS skeleton associated with the role movement; when the role action comprises role local deformation, the target virtual role is controlled to implement the role local deformation in the animation editing scene through the deformation of the dummy skeleton associated with the role local deformation. In an animation editing scene, when a target virtual character performs a character action, recording a key frame of the target virtual character in the character action performing process; video animations are generated based on the key frames. Displaying a thumbnail object of a target virtual character on a character action map in a virtual scene; controlling the movement of the abbreviated object in the action range of the abbreviated object; when the movement of the thumbnail object meets the role interaction triggering condition, switching to an array scene; and when the role action of the target virtual role is triggered, playing the video animation generated in the role action implementation process based on the target virtual role. The virtual scene is an animation editing scene, the CS skeleton is a basic skeleton, the target CS skeleton is a target basic skeleton, the dummy skeleton is a deformed skeleton, and the opposite scene is a character interaction scene.

It should be understood that although the steps in the flowcharts of fig. 2 to 4 are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least some of the steps in fig. 2 to 4 may include multiple steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of performing the steps or stages is not necessarily sequential, but may be performed alternately or alternately with other steps or at least some of the other steps or stages.

In one embodiment, as shown in fig. 15, there is provided a virtual character control apparatus, which may be a part of a computer device using a software module or a hardware module, or a combination of the two, and specifically includes: a display module 1502, an action trigger module 1504, and a control module 1506, wherein:

a display module 1502 for displaying at least a portion of a target avatar in a virtual scene; the target virtual role is bound with a basic skeleton and a deformed skeleton;

an action triggering module 1504 for triggering a role action of a target virtual role in a virtual scene;

the first control module 1506 is configured to, when the character motion includes character motion, control the target virtual character to implement the character motion in the virtual scene through motion of a basic skeleton associated with the character motion;

the second control module 1506 is configured to, when the character action includes a character local deformation, control the target virtual character to implement the character local deformation in the virtual scene through deformation of a deformed bone associated with the character local deformation.

According to the virtual character control device, the basic skeleton and the deformation skeleton are bound to the target virtual character, when the character action triggered in the virtual scene comprises character movement, the target virtual character is controlled to implement the character movement through the movement of the basic skeleton, when the character action triggered in the virtual scene comprises local character deformation, the local character deformation is implemented through the deformation of the deformation skeleton, compared with a mode that animation of the virtual character is drawn manually in the traditional technology, the virtual character control efficiency can be improved, meanwhile, as the target virtual character is controlled through the basic skeleton and the deformation skeleton, too many images do not need to be stored, and the occupied storage space can be reduced.

In one embodiment, the movement of the underlying bone includes at least one of bone movement and bone rotation; the deformation of the deformed bone includes at least one of local expansion and contraction of the bone and global scaling of the bone.

According to the virtual character control device, the movement of the basic skeleton comprises at least one of skeleton movement and skeleton rotation, the deformation of the deformed skeleton comprises at least one of skeleton local expansion and skeleton whole scaling, namely the basic skeleton and the deformed skeleton can respectively realize different functions, so that different character actions of the target virtual character are realized, and the interactivity of the virtual character is improved.

In one embodiment, the virtual character control apparatus further includes a character construction module. The role building module is used for creating a basic skeleton of the target virtual role, and the basic skeleton comprises more than one basic skeleton; adding at least one deformed bone to the base skeleton; and carrying out skinning treatment on the basic skeleton added with the deformed skeleton to obtain the target virtual role.

The virtual character control device creates a basic skeleton of a target virtual character, adds at least one deformed skeleton on the basic skeleton, carries out skinning treatment on the basic skeleton added with the deformed skeleton to obtain the target virtual character, can realize deformation of the target virtual character by erecting the deformed skeleton, and reduces occupied storage space.

In one embodiment, the role construction module is further configured to import the skinned target virtual role into the three-dimensional engine as a model; generating the model into a prefabricated member through a three-dimensional engine; importing an animation configuration file of the prefabricated member in a three-dimensional engine; calling the prefabricated member to generate a target virtual role in a virtual scene through a three-dimensional engine; the control module 1506 is configured to control the target virtual character to perform the character action according to the action parameter value of the animation profile.

According to the virtual character control device, the target virtual character subjected to skin treatment is taken as a model and is led into the three-dimensional engine, the model is used for generating the prefabricated member through the three-dimensional engine, the animation configuration file is led in, the prefabricated member is called to generate the target virtual character under the virtual scene, the action parameter value of the animation configuration file is used for controlling the target virtual character to implement the character action, the target virtual character can be controlled through the action parameter value to realize deformation, a lot of images do not need to be stored, and the occupied storage space is reduced.

In one embodiment, the role construction module is further configured to determine a target base skeleton in the base skeleton; determining the number of deformed bones according to the length of a target basic bone; at the position of the target basic skeleton on the basic skeleton, deformed bones of the number of deformed bones connected in order are added.

The virtual character control device determines the number of the deformed bones according to the length of the target basic bones, and adds the deformed bones of the number of the deformed bones which are sequentially connected to the positions of the target basic bones on the basic skeleton, so that the number of the deformed bones is more matched with the virtual character, and the fidelity of the obtained target virtual character can be improved.

In one embodiment, the character construction module is further configured to load the preform through a three-dimensional engine in the virtual scene; the prefabricated part is obtained by erecting a deformed skeleton on a basic skeleton of a target virtual role and then performing skin covering treatment; and creating an example through the prefabricated member to obtain the target virtual role.

The virtual character control device controls the movement of the abbreviated object in the corresponding action range, and when the movement of the abbreviated object meets the character interaction triggering condition, the virtual character control device is switched to the character interaction scene, so that the interactivity in the virtual scene can be enhanced.

In one embodiment, the virtual object control device further comprises an animation generation module, wherein the animation generation module is used for recording a key frame of the target virtual character in the role action implementation process when the target virtual character is in the role action implementation process in the virtual scene; video animations are generated based on the key frames.

According to the virtual character control device, in the virtual scene, when the target virtual character performs the character action, the key frame of the target virtual character in the implementation process is recorded, the video animation is generated based on the key frame, the video animation of the target virtual character in the character action implementing process can be manufactured, the video animation of the virtual character is easy to modify, and the virtual character control efficiency is improved.

In one embodiment, the control module 1506 is further operable to display the thumbnail object of the target virtual character on the character action map; controlling the movement of the abbreviated object in the action range of the abbreviated object; when the movement of the thumbnail object meets the role interaction triggering condition, switching to a role interaction scene; and when the role action of the target virtual role is triggered in the role interaction scene, playing the video animation.

The virtual character control device controls the thumbnail objects to move in the corresponding action range, when the movement of the thumbnail objects meets the character interaction triggering condition, the thumbnail objects are switched to the character interaction scene, and when the character action of the target virtual character is triggered under the character interaction scene, the video animation is played, so that the virtual character can realize the deformation effect through the deformed skeleton, and the fidelity of the virtual character is improved.

For specific limitations of the avatar control apparatus, reference may be made to the above limitations of the avatar control method, which are not described herein again. Each module in the virtual character control apparatus may be wholly or partially implemented by software, hardware, or a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.

In one embodiment, a computer device is provided, which may be a terminal device, and its internal structure diagram may be as shown in fig. 16. The computer device includes a processor, a memory, a communication interface, a display screen, and an input device connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The communication interface of the computer device is used for carrying out wired or wireless communication with external terminal equipment, and the wireless communication can be realized through WIFI, an operator network, NFC (near field communication) or other technologies. The computer program is executed by a processor to implement a virtual character control method. The display screen of the computer equipment can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, a key, a track ball or a touch pad arranged on the shell of the computer equipment, an external keyboard, a touch pad or a mouse and the like.

Those skilled in the art will appreciate that the architecture shown in fig. 16 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.

In one embodiment, a computer device is further provided, which includes a memory and a processor, the memory stores a computer program, and the processor implements the steps of the above method embodiments when executing the computer program.

In an embodiment, a computer-readable storage medium is provided, in which a computer program is stored which, when being executed by a processor, carries out the steps of the above-mentioned method embodiments.

In one embodiment, a computer program product or computer program is provided that includes computer instructions stored in a computer-readable storage medium. The computer instructions are read by a processor of a computer device from a computer-readable storage medium, and the computer instructions are executed by the processor to cause the computer device to perform the steps in the above-mentioned method embodiments.

It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database or other medium used in the embodiments provided herein can include at least one of non-volatile and volatile memory. Non-volatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical storage, or the like. Volatile Memory can include Random Access Memory (RAM) or external cache Memory. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM), among others.

The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.

The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present patent shall be subject to the appended claims.

30页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:虚拟载具的控制方法、装置、设备及介质

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类