A control method for virtual elements in simulation deduction based on large models, electronic equipment, storage medium and program product
By acquiring and analyzing historical adversarial data, adjusting the layout of virtual scenes and generating virtual character reaction actions that conform to personality tags, the problem that virtual characters and scenes cannot be dynamically adapted in the existing technology is solved, and a higher authenticity and interactivity of simulation exercises are achieved.
Patent Information
- Application Number
- CN202510585870.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-08
- Publication Date
- 2025-08-15
- Estimated Expiration
- 2045-05-08
AI Technical Summary
The existing simulation deduction system cannot dynamically adjust virtual characters and scenes based on the actual reactions of the players and the exercise process, resulting in a reduction in training effect. The virtual enemy characters behave in a single and mechanical manner, and cannot truly reflect the actual confrontation environment, affecting the authenticity and fun of the simulation exercise.
By obtaining historical adversarial data between virtual characters and players, analyzing adversarial authenticity and difficulty, adjusting the layout of the virtual scene and generating reaction actions that conform to personality labels, using large models to generate virtual character behaviors, and optimizing the regulation of virtual elements based on scene feature recognition and preset adversarial rules.
Improve the dynamic adaptability and interactivity of simulation exercises, enhance the virtual character intelligence and custom diversity of scenes, and provide a more realistic and challenging simulation exercise experience.
Smart Images

Figure CN120105755B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer human-computer interaction technology, and more specifically, to a method for controlling virtual elements in simulation deduction based on a large model, an electronic device, a storage medium, and a program product. Background Art
[0002] Simulation systems are commonly used in competitive games, military training, emergency drills, and various simulated confrontation exercises. In these highly realistic scenarios, the behavioral logic of virtual characters and the dynamic changes in the virtual scene are important indicators for measuring the authenticity and effectiveness of training exercises. However, in related technologies, the virtual scene and the behavior of virtual characters have difficulty dynamically reproducing the uncertainties of real confrontations. Given this, there is an urgent need for a method to control virtual elements in simulations and deductions, so that virtual characters and virtual scenes can dynamically adapt to the current player behavior, more realistically simulate actual exercise scenarios, and provide players with a more immersive and challenging simulation exercise experience. Summary of the Invention
[0003] The purpose of the embodiments of the present application is to provide a method, electronic device, storage medium and program product for controlling virtual elements in simulation deduction based on a large model, so as to achieve the technical effect of improving the dynamic adaptability and interactivity of simulation exercises.
[0004] In a first aspect, an embodiment of the present application provides a method for controlling virtual elements in a large-scale model-based simulation, wherein the virtual elements include virtual characters and virtual scenes. The method includes:
[0005] Acquiring historical confrontation data between the virtual character and the player at a historical moment in the simulation; the historical confrontation data includes historical behavior data of the virtual character, historical behavior data of the player, and historical layout data of the virtual scene; wherein the historical behavior data of the virtual character carries a personality tag of the virtual character;
[0006] Analyzing the virtual character historical behavior data, the player historical behavior data, and the virtual scene historical layout data to determine an evaluation result of the confrontation authenticity and confrontation difficulty of the virtual scene at the historical moment;
[0007] Adjusting the historical layout of the virtual scene based on the evaluation result to obtain a target virtual scene;
[0008] The player's historical behavior data and the virtual character's personality tag are input into a behavior generation model to obtain a reaction action of the virtual character to the player; the reaction action is used to instruct the virtual character to use the reaction action to fight against the player in the target virtual scene.
[0009] In the above implementation process, by obtaining the historical confrontation data between the virtual characters and players in the simulation deduction system, including virtual character behavior, player behavior and virtual scene layout, and evaluating the authenticity and difficulty of the confrontation based on these data, the virtual scene layout is adjusted according to the evaluation results, and the virtual character's current reaction actions to the player are generated, which significantly improves the dynamic adaptability and interactivity of the simulation exercise, allowing players to experience a more realistic and challenging simulation exercise environment.
[0010] Furthermore, before obtaining the historical confrontation data between the virtual character and the player at the historical moment of the simulation, the method further includes:
[0011] In response to a scene generation instruction carrying scene image data, performing scene feature recognition processing on the scene image data using a preset recognition model to obtain scene features;
[0012] The virtual scene is generated using the scene features.
[0013] In the above implementation process, the virtual scene is generated by identifying the features of the scene image data, thereby increasing the customization and diversity of the scene.
[0014] Furthermore, before obtaining the historical confrontation data between the virtual character and the player at the historical moment of the simulation, the method further includes:
[0015] Input the preset character attributes, character behavior patterns, and character background stories into the character reasoning model to obtain basic character parameters, and use the basic character parameters to construct the virtual character; the basic character parameters include character description information, character dialogue text, and character behavior script; wherein, the character description information includes the virtual character personality label; the character dialogue text includes the sentence text of the virtual character that conforms to the virtual character personality label, the character behavior script is used to indicate a variety of personalized behaviors that conform to the virtual character personality label, and the reaction action is any one or more of the multiple personalized behaviors.
[0016] In the above implementation process, by inputting character attributes, behavior patterns, and background stories into the character reasoning model, a virtual character with rich personality traits and personalized behaviors can be constructed, enhancing the immersion and realism of the simulation exercise.
[0017] Furthermore, after constructing the virtual character using the basic character parameters, the method further includes:
[0018] Obtaining preset confrontation rules for the virtual character, the preset confrontation rules including attack range calculation rules, damage calculation rules, dialogue content generation rules, dialogue mode selection rules, decision process generation rules, and strategy selection rules;
[0019] The step of inputting the player's historical behavior data and the virtual character's personality tag into a behavior generation model to obtain the virtual character's reaction action to the player includes:
[0020] The player's historical behavior data, the virtual character's personality label, and the preset confrontation rules are input into the behavior generation model to obtain the reaction action that meets the preset confrontation rules.
[0021] In the above implementation process, by introducing preset confrontation rules, it is ensured that the reaction actions of the virtual characters are consistent with their personality labels and the exercise logic and rules, thereby improving the fairness and playability of the simulation exercise.
[0022] Furthermore, the virtual character historical behavior data includes virtual character historical position change data and virtual character historical action data; the player historical behavior data includes player historical position change data and player historical action data; the historical layout includes historical environment parameters, historical obstacle layout, and historical prop distribution;
[0023] The analyzing the virtual character historical behavior data, the player historical behavior data, and the virtual scene historical layout data to determine an evaluation result of the virtual scene's confrontation authenticity and confrontation difficulty at the historical moment includes:
[0024] Analyzing the virtual character's historical position change data and the player's historical position change data to determine a confrontation authenticity result, analyzing the virtual character's historical action data and the virtual character's historical action data to determine a confrontation difficulty result, and obtaining the evaluation result including the confrontation authenticity result and the confrontation difficulty result;
[0025] The adjusting the historical layout of the virtual scene based on the evaluation result to obtain a target virtual scene includes:
[0026] The historical environment parameters are adjusted based on the comparison result of the confrontation authenticity result and the preset authenticity threshold, and the historical obstacle layout and the historical prop distribution are adjusted based on the comparison result of the confrontation difficulty result and the preset difficulty threshold to obtain the target virtual scene.
[0027] In the above implementation process, the authenticity and difficulty of the virtual scene's confrontation are determined by analyzing historical confrontation data, and the virtual scene layout is adjusted accordingly, thereby achieving dynamic optimization of the virtual scene.
[0028] Furthermore, the method further comprises:
[0029] Clustering the historical behavior data of the virtual character at the historical moment to obtain a plurality of first clusters, each of the first clusters being used to represent a type of virtual character behavior;
[0030] Clustering the player's historical behavior data at the historical moment to obtain a plurality of second clusters, each of the second clusters being used to represent a category of player character behavior;
[0031] Clustering the virtual scene historical layout data at the historical moment to obtain a plurality of third clusters, each of the third clusters being used to represent a type of scene;
[0032] Determining a cluster set time series based on the association relationship between each of the first clusters, each of the second clusters, and each of the third clusters; the cluster set time series includes a plurality of cluster sets arranged in time; each of the cluster sets includes a type of the virtual character behavior, a category of the player character behavior, and a type of the scene that are mutually associated;
[0033] Determining a conversion rule between at least two of the cluster sets that are consecutive in time from the cluster set time series;
[0034] determining the reaction weaknesses of the virtual character from the conversion rules;
[0035] The behavior generation model is updated based on the reaction weakness to obtain an updated behavior generation model.
[0036] In the above implementation process, by performing cluster analysis on historical confrontation data and scene layout data, the associations and conversion patterns between virtual characters, player behaviors, and virtual scenes were determined, thereby identifying the reaction weaknesses of virtual characters and updating the behavior generation model accordingly, thereby improving the intelligence level and reaction ability of virtual characters, and being able to continuously improve the overall quality and playability of simulation exercises.
[0037] Furthermore, the behavior generation model includes a behavior strategy decision layer and a behavior generation layer connected in sequence;
[0038] The adjusting the behavior generation model based on the reaction weakness to obtain an updated behavior generation model includes:
[0039] When the reaction weakness indicates that the accuracy of the virtual character behavior generated by the behavior generation layer does not exceed a first preset threshold, dividing the behavior generation layer into a plurality of behavior sub-generation layers according to a plurality of behavior types, each of the behavior sub-generation layers is used to generate a corresponding type of behavior; the plurality of behavior types include attack, defense, and movement;
[0040] When the reaction weakness indicates that the accuracy of the virtual character behavior strategy generated by the behavior strategy decision layer does not exceed a second preset threshold, the behavior strategy decision layer is divided into a plurality of behavior strategy sub-decision layers according to a plurality of strategy types, each of the behavior strategy sub-decision layers being used to generate a corresponding type of behavior strategy; the plurality of strategy types including path planning strategy, competitive confrontation strategy, task execution strategy, and patrol and standby strategy;
[0041] Determine the updated behavior generation model including a plurality of the behavior sub-generation layers or a plurality of the behavior strategy sub-decision layers.
[0042] In the above implementation process, hierarchical optimization is performed for each reaction weakness. When the behavioral accuracy of the virtual character in the behavior generation layer is insufficient, it is subdivided into multiple behavioral sub-generation layers focusing on specific behavior types such as attack, defense, and movement to improve the accuracy and pertinence of behavior generation. Similarly, when the behavioral strategy accuracy of the behavioral strategy decision layer does not meet the requirements, it is subdivided into multiple behavioral strategy sub-decision layers responsible for specific strategy types such as path planning and competitive confrontation to enhance the rationality and effectiveness of strategy formulation. Utilizing this hierarchical optimization strategy can significantly improve the intelligence level of the virtual character and its ability to cope with complex exercise environments, providing players with a richer, more varied, and challenging exercise experience.
[0043] According to a second aspect of an embodiment of the present application, an electronic device is provided, comprising:
[0044] processor;
[0045] a memory for storing processor-executable instructions;
[0046] Wherein, when the processor calls the executable instruction, any method described in the first aspect is implemented.
[0047] A third aspect of an embodiment of the present application provides a computer-readable storage medium having computer instructions stored thereon, which, when executed by a processor, implement the steps of any of the methods described in the first aspect.
[0048] A fourth aspect of the embodiments of the present application provides a computer program product, which includes a computer program. When the computer program is executed by a processor, it implements any method described in the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments of the present application. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other relevant drawings can be obtained based on these drawings without creative work.
[0050] Figure 1 A schematic flow chart of a method for controlling virtual elements in a large-scale model-based simulation provided in an embodiment of the present application;
[0051] Figure 2 A schematic diagram of the overall process of a control system provided in an embodiment of the present application;
[0052] Figure 3 A schematic diagram of a scene dynamic adjustment process provided in an embodiment of the present application;
[0053] Figure 4 This is a structural block diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0054] The technical solutions in the embodiments of the present application will be described below in conjunction with the drawings in the embodiments of the present application.
[0055] It should be noted that similar reference numerals and letters represent similar items in the following drawings. Therefore, once an item is defined in one drawing, it does not need to be further defined or explained in subsequent drawings. At the same time, in the description of this application, the terms "first", "second", etc. are only used to distinguish the description and should not be understood as indicating or implying relative importance.
[0056] In competitive games, military training, emergency drills, and various simulated confrontation exercises, the generation of virtual enemy characters and the design of training scenarios play a vital role in improving training effectiveness and enhancing players' response capabilities and strategic planning. Traditional methods for generating virtual enemy characters and setting scenarios often rely on manually preset rules and scripts. This not only limits the behavioral diversity and intelligence of virtual enemy characters, but also makes it difficult to dynamically adjust scenarios based on the actual progress of the simulation, thus affecting the authenticity and effectiveness of the training.
[0057] The rapid development of artificial intelligence (AI), particularly the widespread application of large-scale language and image recognition models, has opened up new possibilities for the intelligent generation of virtual enemy characters and the dynamic adaptation of training scenarios. However, effectively integrating these large-scale model technologies into simulation systems to achieve autonomous generation, behavior prediction, dynamic adaptation, and real-time adjustment of training scenarios for virtual enemy characters has become a pressing technical challenge.
[0058] In other words, in related technologies, simulation systems rely on preset rules and are often unable to dynamically adjust and optimize based on players' actual reactions and changes in the exercise process. This significantly reduces training effectiveness and the ability to fully demonstrate the complexity and variability of the real battlefield environment, thereby reducing the authenticity of the simulation exercises. Furthermore, due to the lack of effective prediction and adaptation mechanisms when handling the behavior of virtual enemy characters, the behavior of virtual enemy characters often appears monotonous and mechanical, failing to truly reflect the strategies and behavioral patterns of enemy characters in actual confrontations. This limitation not only reduces the fun and challenge of simulation exercises but also restricts players' understanding and mastery of tactical strategies during training exercises. Therefore, there is an urgent need for a method for controlling virtual elements in simulations, including virtual enemy characters and virtual scenes, that can dynamically adjust and optimize the behavior or properties of virtual elements based on players' actual reactions and changes in the exercise process, thereby more realistically simulating the actual confrontation environment and providing players with a more immersive and challenging exercise experience.
[0059] In response to any of the above-mentioned problems, the present application provides a method for controlling virtual elements in simulation deduction based on a large model, referring to Figure 1 , Figure 1 A flowchart of a method for controlling virtual elements in a large-model-based simulation provided in an embodiment of the present application.
[0060] In this embodiment, the virtual elements include virtual characters and virtual scenes; the method includes:
[0061] Step S10: Acquire historical confrontation data between the virtual character and the player at a historical moment in the simulation; the historical confrontation data includes historical behavior data of the virtual character, historical behavior data of the player, and historical layout data of the virtual scene; wherein the historical behavior data of the virtual character carries a personality tag of the virtual character;
[0062] It should be noted that this embodiment provides a method for regulating virtual elements in simulation deduction based on a large model, which is suitable for an exercise training application scenario that requires dynamic adjustment of virtual scenes and virtual character behaviors, including confrontation games, military training, emergency drills and various simulated confrontation exercise application scenarios, so as to achieve the effect of comprehensively improving the quality of exercises.
[0063] This embodiment does not limit the time length of the historical moment. The historical moment may refer to a period of time in the past, such as the past hour, or a certain time point in the past, such as the previous minute.
[0064] In addition to historical avatar behavior data, player behavior data, and virtual scene layout data, historical combat data can also include the avatar and player's respective positions in the virtual scene, their respective health status (including health, energy, and stamina, which reflect the avatar and player's survival or combat capabilities), their respective equipment status (equipment, weapons, and items used), their respective skill status (the avatar and player's learned skills, their cooldowns, and durations), their respective emotional states (which can include anger, fear, excitement, etc., and these emotional states influence their behavioral choices), their respective resource status (the amount of resources owned, such as gold, materials, and experience points), and the status of their respective team members. The avatar's historical behavior data reflects the avatar's past behavior in the simulation system, which can reflect the avatar's personality and strategies. The avatar's historical behavior data carries the avatar's personality tag, which helps understand the avatar's behavioral patterns. Player historical behavior data also reflects the player's past behavior in the simulation system, such as movement, attack, and defense. This data helps analyze the player's combat style and strategy. The historical layout data of the virtual scene records the layout of the exercise scene at past moments, including historical terrain, historical obstacle distribution, historical prop resource distribution, etc.
[0065] Step S20: analyzing the virtual character historical behavior data, the player historical behavior data, and the virtual scene historical layout data to determine an evaluation result of the virtual scene's confrontation authenticity and confrontation difficulty at the historical moment;
[0066] As an example, machine learning or statistical models can be used, combined with historical confrontation data, to analyze whether the virtual scene in which the player and the virtual character are located is natural and realistic, and to determine whether the current confrontation difficulty is consistent with the exercise difficulty selected by the player before entering the exercise. Ultimately, an evaluation result of the confrontation authenticity and difficulty can be obtained. This evaluation result can be used to indicate which aspects of the virtual exercise scene need to be improved or optimized.
[0067] Step S30: adjusting the historical layout of the virtual scene based on the evaluation result to obtain a target virtual scene;
[0068] For example, based on the evaluation results, the scene layout is adjusted, such as changing the terrain, adding or reducing obstacles, adjusting the distribution of prop resources, etc., to generate a target virtual scene that better meets the realism and difficulty requirements of the confrontation.
[0069] Step S40: Inputting the player's historical behavior data and the virtual character's personality tag into a behavior generation model to obtain the virtual character's reaction action to the player; the reaction action is used to instruct the virtual character to use the reaction action to fight against the player in the target virtual scene.
[0070] It should be noted that the behavior generation model can be a deep learning model or a large language model. Leveraging its generative capabilities, the behavior generation model can generate responses for the virtual character that are consistent with the character's personality traits and the current exercise scenario. As an example, a behavior generation model is used to generate responses for the large language model. Before deploying the large language model, it is fine-tuned to better adapt it to the language and data characteristics of the corresponding application domain (e.g., competitive gaming, military training, emergency drills, etc.). This example uses the competitive gaming domain as an example. Based on the language patterns and knowledge learned during training, the fine-tuned large language model can generate outputs related to the input data. The outputs of the fine-tuned large language model can be narrative response instructions (e.g., "The virtual character should launch a surprise attack on the player to demonstrate their bravery") or specific action descriptions (e.g., "The virtual character should move to position X and then perform attack action Y"). These outputs need to be parsed into instructions or actions that can be executed by the game engine. After deploying the fine-tuned large language model, players' historical behavior data is collected and organized, and converted into a format understandable by the large language model. Specifically, this can be done by encoding behavior sequences into textual descriptions or serialized data formats. This historical player behavior data can include players' actions, decisions, and interaction patterns. Simultaneously, the character's personality label is determined and similarly converted into a format understandable by the large language model, such as a textual description or embedding vector. The converted player historical behavior data and the character's personality label are then fed into the large language model, which generates reaction commands or action descriptions based on these inputs. The output generated by the large language model is then parsed and converted into commands or actions executable by the game engine. These commands or actions are then executed in the game engine, allowing the character to interact with the player based on the generated reactions. This results in a more intelligent and natural behavior of the character in the game, consistent with their personality traits, and adapted to the current game scenario and difficulty level.
[0071] In this embodiment, by collecting and analyzing confrontation data and optimizing virtual scene layout and avatar behavior, the goal is to enhance the realism and difficulty of the simulation exercises, while also making them more interesting and challenging. Furthermore, by incorporating avatar personality tags and behavioral generation models, more intelligent and personalized avatar reactions can be generated, thereby enhancing the player's experience.
[0072] Based on any of the above embodiments, a method for controlling virtual elements in a large-scale model-based simulation includes the following steps:
[0073] Acquire historical confrontation data between the virtual character and the player at a historical moment in the simulation; the historical confrontation data includes historical behavior data of the virtual character, historical behavior data of the player, and historical layout data of the virtual scene;
[0074] Analyzing the virtual character historical behavior data, the player historical behavior data, and the virtual scene historical layout data to determine an evaluation result of the confrontation authenticity and confrontation difficulty of the virtual scene at the historical moment;
[0075] The historical layout of the virtual scene is adjusted based on the evaluation result to obtain a target virtual scene.
[0076] It should be noted that this embodiment provides a method for regulating scenes in a simulation deduction system, which is applicable to a simulated confrontation exercise application scenario that requires dynamic adjustment of the virtual exercise scene to adapt to different player levels or exercise stages, thereby achieving the effect of improving the playability of the simulated confrontation. Specifically, first, historical confrontation data between virtual characters and players are collected. Then, by analyzing these historical data, the evaluation results of the confrontation authenticity and confrontation difficulty of the virtual scene at the historical moment are determined. Then, based on the above evaluation results, the historical layout of the virtual scene is adjusted to ensure that the exercise scene can provide players with a realistic and challenging experience.
[0077] In this embodiment, the virtual scene layout is optimized through data analysis to optimize the confrontational authenticity and difficulty of the simulation exercise.
[0078] Based on any of the above embodiments, a method for controlling virtual elements in a large-scale model-based simulation includes the following steps:
[0079] Acquiring historical confrontation data between the virtual character and the player at a historical moment in the simulation; the historical confrontation data includes historical behavior data of the virtual character, historical behavior data of the player, and historical layout data of the virtual scene; wherein the historical behavior data of the virtual character carries a personality tag of the virtual character; and the historical layout data of the virtual scene is used to represent the virtual scene in which the virtual character and the player are located;
[0080] The player's historical behavior data and the virtual character's personality tag are input into a behavior generation model to obtain a reaction action of the virtual character to the player; the reaction action is used to instruct the virtual character to use the reaction action to fight against the player in the virtual scene.
[0081] It should be noted that this embodiment provides a method for regulating the behavior of virtual characters in a simulation deduction system, which is applicable to a simulated confrontation exercise application scenario that requires the virtual character to have highly intelligent and personalized behavior, thereby achieving the effect of enhancing the immersion and interactivity of the confrontation exercise. Specifically, first, historical confrontation data is collected, wherein the historical confrontation data includes the personality labels of the virtual characters. Then, the player's historical behavior data and the virtual character's personality label are input into the behavior generation model, and artificial intelligence technology is used to predict and generate the virtual character's reaction action to the player at the next moment. The reaction action needs to be consistent with the personality characteristics of the virtual character and generate meaningful interaction with the player's behavior to improve the quality of the player's interactive experience.
[0082] In this embodiment, by introducing a behavior generation model and combining the player's historical behavior data with the virtual character's personality tags, the generation of intelligent and personalized reaction actions of the virtual character in the exercise is achieved, thereby enhancing the immersion and interactivity of the simulation exercise.
[0083] Based on any of the above embodiments, before step S10, the method further includes:
[0084] In response to a scene generation instruction carrying scene image data, performing scene feature recognition processing on the scene image data using a preset recognition model to obtain scene features;
[0085] The virtual scene is generated using the scene features.
[0086] It should be noted that the scene image data can be picture data or video data input by the exercise developer or obtained by calling the exercise library.
[0087] Specifically, first, after receiving the scene generation instruction, the instruction needs to be parsed to identify the scene image data carried by the instruction. Then, the scene image data is processed using a recognition model that has been trained to identify key features in the scene image to extract key scene features in the scene image data. These features can be topography, buildings, vegetation, lighting conditions, etc. In addition, the extracted key scene features can be further processed by denoising, enhancement, classification, etc. to ensure the accuracy and efficiency of the subsequent steps of generating exercise scenes using scene features. Then, a virtual scene is constructed based on the identified and processed scene features. Optionally, in a competitive game application scenario, the scene feature data is mapped to the corresponding module of the game engine to generate a realistic virtual scene.
[0088] In this embodiment, scene features are extracted through the recognition model, and the scene features are used to generate a virtual scene, thereby improving the efficiency and accuracy of scene generation.
[0089] Based on any of the above embodiments, before step S10, the method further includes:
[0090] Input the preset character attributes, character behavior patterns, and character background stories into the character reasoning model to obtain basic character parameters, and use the basic character parameters to construct the virtual character; the basic character parameters include character description information, character dialogue text, and character behavior script; wherein, the character description information includes the virtual character personality label; the character dialogue text includes the sentence text of the virtual character that conforms to the virtual character personality label, the character behavior script is used to indicate a variety of personalized behaviors that conform to the virtual character personality label, and the reaction action is any one or more of the multiple personalized behaviors.
[0091] It should be noted that character attributes refer to the basic attributes of a virtual character, such as age, gender, appearance characteristics, skills, etc.
[0092] Character behavior patterns describe how a character might behave in different situations. For example, a brave warrior might charge ahead in a combat exercise, while a cunning thief might prefer to sneak around and steal.
[0093] A character's backstory provides information about the character's history, motivations, and relationships with other characters. The backstory helps enrich the character's personality and behavior.
[0094] A character reasoning model is a model that can generate the basic parameters of a character based on input information. Specifically, a character reasoning model can be any one of a variety of large language models with reasoning capabilities, or a combination of any number of them. Examples include DeepMind's AlphaCode model (which builds characters by understanding their programming logic and behavioral patterns), OpenAI's Codex model, Meta's Code Llama (which is primarily used to generate behaviors and dialogues that match the character's professional background), and models that combine general large models with reasoning modules (some general large models, such as the GPT series and BERT, although they do not have dedicated reasoning modules themselves, can enhance their character reasoning capabilities by combining additional reasoning algorithms or modules).
[0095] The character description information includes the character's personality tags, such as: brave, cunning, kind, etc.
[0096] Character dialogue text refers to the sentence text that conforms to the character's personality label. These texts can be used for character dialogue and interaction in exercises.
[0097] A character behavior script refers to a script of various personalized behaviors that conform to the character's personality label. These behaviors may include the character's actions, reactions, decisions, etc.
[0098] As an example, using technical means such as 3D modeling, animation production and interactive system design, the basic parameters of virtual characters are transformed into virtual character entities with vivid appearance, personalized dialogue and rich behavior patterns.
[0099] In this embodiment, by inputting preset character attributes, behavior patterns, and background stories into the character reasoning model, basic character parameters are generated, and based on this, a virtual character with distinct personality traits, personalized dialogues, and diverse behaviors is constructed, thereby providing players with a more vivid, realistic, and interesting confrontation exercise interactive experience.
[0100] On the basis of any of the above embodiments, after constructing the virtual character using the character basic parameters, the method further includes:
[0101] Obtaining preset confrontation rules for the virtual character, the preset confrontation rules including attack range calculation rules, damage calculation rules, dialogue content generation rules, dialogue mode selection rules, decision process generation rules, and strategy selection rules;
[0102] It should be noted that the pre-set confrontation rules serve as the basis for guiding the avatar's behavior and decision-making when interacting with the player. These rules include, but are not limited to, attack range calculation rules, damage calculation rules, dialogue content generation rules, dialogue method selection rules, decision-making process generation rules, and strategy selection rules.
[0103] The attack range calculation rule is used to characterize the spatial range in which the virtual character can launch an attack; the damage calculation rule is used to characterize the damage value that the virtual character can cause when attacking; the dialogue content generation rule is used to instruct the generation of dialogue content that conforms to the current situation; the dialogue method selection rule is used to instruct the selection of one or more dialogue methods that conform to the personality label of the virtual character from a variety of dialogue methods; the decision process generation rule is used to instruct the generation of a series of decision steps to guide the behavior of the virtual character; the strategy selection rule is used to instruct the selection of a strategy that conforms to the current state of the virtual character to deal with the player.
[0104] Specifically, the attack range calculation rules define the range that the virtual character can reach when attacking.
[0105] Damage calculation rules: Determine how to calculate the damage value when the virtual character attacks or is attacked.
[0106] Dialogue content generation rules: specify how the virtual character should generate dialogue content that is consistent with its personality and situation when talking to the player.
[0107] Dialogue method selection rules: Determine the method (such as direct, indirect, humorous, etc.) used by the virtual character when communicating with the player.
[0108] Decision-making process generation rules: define the process of how virtual characters make decisions when faced with different situations.
[0109] Strategy selection rules: stipulate how the virtual character should choose the appropriate strategy to deal with the player when confronting the player.
[0110] The step of inputting the player's historical behavior data and the virtual character's personality tag into a behavior generation model to obtain the virtual character's reaction action to the player includes:
[0111] The player's historical behavior data, the virtual character's personality label, and the preset confrontation rules are input into the behavior generation model to obtain the reaction action that meets the preset confrontation rules.
[0112] It should be noted that, in addition to inputting the player's historical behavior data and virtual character personality labels into the behavior generation model, this embodiment also adds preset confrontation rules as input. This is to ensure that the generated virtual character's reaction actions not only conform to its personality label, but also conform to the preset confrontation rules, thereby making the virtual character's behavior more reasonable and controllable.
[0113] Specifically, the player's historical behavior data (such as past actions, decisions, conversations, etc.) and the virtual character's personality labels (such as bravery, cunningness, kindness, etc.) are used as input and sent to the behavior generation model. The behavior generation model can generate virtual character reaction actions that conform to the preset confrontation rules based on the input data and labels. The generated reaction action can be an action, a sentence, a decision, etc. of the virtual character.
[0114] In this embodiment, by setting preset confrontation rules for the virtual character and using the behavior generation model to generate reaction actions based on the player's historical behavior data and the virtual character's personality label, the controllability and rationality of the virtual character's behavior are achieved, making the virtual character's behavior more in line with the player's expectations and the logic of the simulated confrontation exercise.
[0115] Based on any of the above embodiments, the virtual character historical behavior data includes virtual character historical position change data and virtual character historical action data; the player historical behavior data includes player historical position change data and player historical action data; the historical layout includes historical environmental parameters, historical obstacle layout, and historical prop distribution;
[0116] The analyzing the virtual character historical behavior data, the player historical behavior data, and the virtual scene historical layout data to determine an evaluation result of the virtual scene's confrontation authenticity and confrontation difficulty at the historical moment includes:
[0117] Analyzing the virtual character's historical position change data and the player's historical position change data to determine a confrontation authenticity result, analyzing the virtual character's historical action data and the virtual character's historical action data to determine a confrontation difficulty result, and obtaining the evaluation result including the confrontation authenticity result and the confrontation difficulty result;
[0118] It should be noted that historical position change data records the movement trajectories of avatars and players within the simulated combat exercise scenario. This data may include the avatars' and players' coordinate information, movement speed, and movement direction within the simulated combat exercise scenario. Historical action data, on the other hand, records the various actions performed by avatars and players, such as attacking, defending, and picking up items. Historical layout describes the physical environment and resource distribution of the simulated combat exercise scenario.
[0119] In a specific implementation, using a competitive game scenario as an example, by analyzing the historical position change data of the virtual character and the player, the respective positions of both parties can be determined. In competitive games, the scene needs to dynamically change based on the player's behavior and position. For example, when the player and the virtual character enter a new area, the game scene needs to be updated accordingly to display the new environment, obstacles, and props. Therefore, by determining whether the current game scene is appropriate for the current positions of both parties, the authenticity of the virtual scene's confrontation can be determined. Furthermore, confrontation authenticity can be used to characterize not only whether the scene, the virtual character, and the player's positions are appropriate, but also whether the interactive confrontation between the virtual character and the player is sufficiently plausible and realistic. Specifically, by comparing the movement trajectories of the player and the virtual character, it can be determined whether there is sufficient interaction and conflict between them. If the movement trajectories of the two parties in the game intersect and there is frequent interaction and confrontation, the confrontation is considered authentic. Conversely, if the movement trajectories of the two parties in the game are independent and lack interaction and confrontation, the confrontation is considered unrealistic. For example, historical position change data can also be used to assess the difficulty balance of a game. Specifically, by comparing the relative position and movement speed of the player and the avatar, it can be determined whether the game is too easy or too difficult. If the player can easily avoid the avatar's attacks and defeat them, the game may be too easy. Conversely, if the player has difficulty approaching the avatar and is under constant attack, the game may be too difficult. The game's difficulty can be balanced by adjusting the scene environment, obstacles, and prop distribution, allowing players to enjoy a more balanced and interesting gaming experience.
[0120] By comparing the action data of the virtual character and the player, we can analyze the behavioral patterns and strategies of both parties in the game, and then determine the difficulty of the confrontation. That is, whether the two sides' actions are balanced and whether one side has a clear advantage or disadvantage. Combining the results of the confrontation's realism and difficulty, we can obtain a comprehensive evaluation result, which reflects the quality of the confrontation in the current game scene and the player's gaming experience.
[0121] The adjusting the historical layout of the virtual scene based on the evaluation result to obtain a target virtual scene includes:
[0122] The historical environment parameters are adjusted based on the comparison result of the confrontation authenticity result and the preset authenticity threshold, and the historical obstacle layout and the historical prop distribution are adjusted based on the comparison result of the confrontation difficulty result and the preset difficulty threshold to obtain the target virtual scene.
[0123] It should be noted that this embodiment does not impose any restrictions on the preset authenticity threshold and the preset difficulty threshold. Specifically, if the authenticity of the confrontation is insufficient, it can be improved by adjusting the environmental parameters, for example, increasing the light intensity or changing the weather conditions to increase the realism and immersion of the simulation exercise. If the difficulty of the confrontation is too high or too low, it can be balanced by adjusting the obstacle layout and prop distribution, for example, increasing or reducing the number and position of obstacles, changing the type and quantity of props, to adjust the challenge and fun of the simulation exercise. After the above adjustments, a target virtual scene that better meets the preset requirements can be obtained, and the preset requirements can be selected by the player. The target virtual scene not only has a higher confrontation authenticity and difficulty balance, but also provides a better player exercise experience.
[0124] In this embodiment, through data analysis and scene layout adjustment, accurate evaluation and optimization of the authenticity and difficulty of virtual scene confrontation are achieved, making the simulation exercise scene more in line with the player's expectations and the logic of real exercises.
[0125] Based on any of the above embodiments, the method further includes:
[0126] Clustering the historical behavior data of the virtual character at the historical moment to obtain a plurality of first clusters, each of the first clusters being used to represent a type of virtual character behavior;
[0127] Clustering the player's historical behavior data at the historical moment to obtain a plurality of second clusters, each of the second clusters being used to represent a category of player character behavior;
[0128] Clustering the virtual scene historical layout data at the historical moment to obtain a plurality of third clusters, each of the third clusters being used to represent a type of scene;
[0129] Determining a cluster set time series based on the association relationship between each of the first clusters, each of the second clusters, and each of the third clusters; the cluster set time series includes a plurality of cluster sets arranged in time; each of the cluster sets includes a type of the virtual character behavior, a category of the player character behavior, and a type of the scene that are mutually associated;
[0130] Determining a conversion rule between at least two of the cluster sets that are consecutive in time from the cluster set time series;
[0131] determining the reaction weaknesses of the virtual character from the conversion rules;
[0132] The behavior generation model is updated based on the reaction weakness to obtain an updated behavior generation model.
[0133] It should be noted that, first, cluster analysis is performed on the virtual character behavior data at historical moments, resulting in multiple first clusters. Each cluster represents a type of virtual character behavior, such as attacking, defending, and moving. Cluster analysis groups similar virtual character behaviors together, facilitating subsequent analysis of their correlations with player behavior and the virtual scene. Next, cluster analysis is performed on the player behavior data at historical moments, resulting in multiple second clusters. Each cluster represents a type of player behavior, such as offensive, defensive, and exploratory. Clustering similar player behaviors together through cluster analysis helps understand players' styles and strategies in combat. Finally, cluster analysis is performed on the virtual scene layout data at historical moments, resulting in multiple third clusters. Each cluster represents a type of scene, such as a forest scene, a desert scene, or a city scene. Clustering similar virtual scene layouts together through cluster analysis helps understand the impact of different scenes on combat exercises and facilitates subsequent analysis of the correlations between scenes and virtual character and player behavior. Based on the associations between each of the first, second, and third clusters, a cluster set time series is determined. This series includes multiple cluster sets arranged in time, each cluster set including a type of interrelated virtual character behavior, a category of player behavior, and a type of scene. By constructing a cluster set time series, the evolution of different behavioral patterns and scene layouts during the exercise can be reflected, and the dynamic interactions between virtual characters, players, and virtual scenes can be clearly demonstrated. It should be understood that certain virtual character behaviors may trigger specific reactions from players, which in turn may change the layout of the virtual scene. In some cases, virtual characters or players, due to their unfamiliarity with a particular scene, are prone to engaging in confrontational reactions that are detrimental to their chances of victory. Transition patterns between at least two temporally consecutive cluster sets are then determined from the cluster set time series. These transition patterns describe the behavioral changes and scene transitions of the virtual characters, players, and virtual scenes at different time points. By identifying transition patterns, we can gain deeper insights into the dynamics of the exercise confrontation, uncovering the avatar's primary reaction patterns in different scenarios and player behaviors, and / or identifying the player's secondary reaction patterns in different scenarios and avatar behaviors. In other words, by analyzing transition patterns between temporally consecutive clusters, we can reveal the dynamics of exercise behavior patterns, such as when the avatar switches from attack to defense, or when the player switches from exploration to combat. Subsequently, after determining the avatar's primary reaction patterns in different scenarios and player behaviors based on the transition patterns, we can identify weaknesses in the avatar's reactions based on these primary reaction patterns. Furthermore, we can identify weaknesses in the player's reactions based on these secondary reaction patterns.A virtual character's reaction weaknesses can refer to mistakes or deficiencies that the virtual character is prone to in specific scenarios or when faced with specific player behaviors. Similarly, a player's reaction weaknesses can also refer to mistakes or deficiencies that the player is prone to in specific scenarios or when faced with specific virtual character behaviors. By determining the virtual character's reaction weaknesses, exercise developers can be provided with a basis for improving the virtual character behavior generation model, making the virtual character's behavior more realistic and challenging. In addition, by determining the player's reaction weaknesses, a weakness analysis report can be provided to the player, allowing the player to perform targeted combat power enhancement based on the data shown in the weakness analysis report. In one embodiment, the behavior generation model can be adjusted based on the player's reaction weaknesses so that the virtual character's behavior can more effectively trigger the player's reaction errors, thereby achieving the purpose of increasing the challenge of the exercise. Finally, based on the determined virtual character reaction weaknesses, the behavior generation model for the virtual character is updated. This can be achieved by adjusting the model's parameters and algorithms, so that the behavior generation model can generate virtual character behaviors that are more consistent with the actual exercise confrontation situation.
[0134] In the specific implementation, first, the raw data from virtual characters, players, and scene changes are received and preliminarily processed in real time. The preliminary processing includes data cleaning (to remove duplicate, invalid, and abnormal data records) and data format conversion (to convert real-time data into a unified data format). Then, the preliminarily processed data is stored in the database in timestamp order. Then, the principal component analysis feature extraction algorithm is used to extract key features from the stored data. The features include the behavior patterns of virtual characters, the reaction time of players, and the frequency of scene changes. Then, the cluster analysis K-means algorithm is used to analyze the extracted features and mine the hidden patterns, association rules, and anomalies in the data; wherein, the algorithm formula of cluster analysis is expressed as: for a given data set D={x1, x2, ..., x n}, through iterative optimization, the similarity of data points in the same cluster is high, and the similarity between different clusters is low. The specific algorithm is as follows:
[0135] ;
[0136] In formula 1, represents the center of the jth cluster at the t+1th iteration, represents the set of data points of the jth cluster, is the data point, is the number of data points within the cluster. Finally, based on the analysis results, potential patterns and regularities between avatar behavior, player reactions, and scene changes are identified. Furthermore, the analysis results and identified patterns can be compiled into a report that includes an overview of the data analysis, key findings, pattern recognition results, weaknesses in avatar reactions, weaknesses in player reactions, and recommended improvement measures for these weaknesses.
[0137] In this embodiment, cluster analysis is used to divide the historical behavioral data of virtual characters, players, and virtual scenes into multiple clusters, each representing a specific type of behavior or scene. Clustering not only simplifies the complexity of the data but also makes subsequent analysis more efficient and accurate. On this basis, a cluster set time series is further constructed, which chronologically arranges multiple cluster sets containing interrelated virtual character behaviors, player character behaviors, and virtual scene types. By analyzing the temporal continuity and transition patterns of these cluster sets, the reaction weaknesses of the virtual characters under specific scenes and player behaviors can be revealed. Based on these reaction weaknesses, the behavior generation model is then updated to improve the model's accuracy and adaptability, ensuring that the virtual character's behavior better conforms to the player's expectations and the logic of the exercise.
[0138] Based on any of the above embodiments, the behavior generation model includes a behavior strategy decision layer and a behavior generation layer connected in sequence;
[0139] The adjusting the behavior generation model based on the reaction weakness to obtain an updated behavior generation model includes:
[0140] When the reaction weakness indicates that the accuracy of the virtual character behavior generated by the behavior generation layer does not exceed a first preset threshold, dividing the behavior generation layer into a plurality of behavior sub-generation layers according to a plurality of behavior types, each of the behavior sub-generation layers is used to generate a corresponding type of behavior; the plurality of behavior types include attack, defense, and movement;
[0141] It should be noted that the weakness of the virtual character's response is a concrete manifestation of the poor performance of the behavior generation model at a specific level.
[0142] By dividing the behavior generation model into a behavior strategy decision layer and a behavior generation layer, and optimizing and adjusting these two layers based on the reaction weaknesses of the virtual character, the prediction accuracy and adaptability of the virtual character's behavior can be improved.
[0143] The behavior strategy decision layer is responsible for generating the behavior strategy of the virtual character, that is, deciding what kind of behavior the virtual character should take to achieve its goal. These strategies may include path planning strategies (used to instruct the virtual character how to move to the target location effectively), competitive confrontation strategies (used to instruct the virtual character how to compete with other players), task execution strategies (used to instruct the virtual character how to complete specific exercise tasks), and patrol and standby strategies (used to instruct the virtual character how to act when there is no specific task).
[0144] The behavior generation layer is responsible for generating specific behaviors of the virtual character based on the strategies generated by the behavior strategy decision layer. These behaviors may include attack, defense, movement, etc.
[0145] The first preset threshold is a pre-set value or range, which is used to determine whether the behavior generated by the virtual character behavior generation layer is accurate and whether it has reached the expected level and confrontation effect. When the accuracy of the behavior generated by the behavior generation layer is lower than this threshold, it is considered that the generated behavior is not accurate enough, and further adjustment and optimization are required. This embodiment does not limit the first preset threshold. The first preset threshold can be determined by analyzing a large amount of historical data. For example, the accuracy data of the virtual character's behavior generation in the past is analyzed, and then a threshold that can reflect these data characteristics is set. In addition, as the simulation exercise develops and the needs of players change, the first preset threshold can be dynamically adjusted.
[0146] It should be understood that the initial behavior generation layer can be a comprehensive layer used to generate various behaviors for virtual characters. However, when the accuracy of the behaviors generated by this layer fails to meet preset standards, it needs to be divided to improve the accuracy and professionalism of the generated behaviors. Virtual character behaviors include a variety of types, not limited to attack, defense, and movement. The behavior generation layer can be divided into a corresponding number of behavior sub-generation layers based on the number of actual behavior types. For example, based on the three behavior types of virtual characters, attack, defense, and movement, the behavior generation layer can be divided into an offensive behavior sub-generation layer (responsible for generating the virtual character's offensive behaviors, such as attacking, casting spells, and using props), a defensive behavior sub-generation layer (responsible for generating the virtual character's defensive behaviors, such as dodging, blocking, and counterattacking), and a movement behavior sub-generation layer (responsible for generating the virtual character's movement behaviors, such as walking, running, and jumping). By dividing the behavior generation layer into multiple behavior sub-generation layers, it is possible to manage and generate different behavior types, helping to improve the accuracy and authenticity of virtual character behaviors.
[0147] When the reaction weakness indicates that the accuracy of the virtual character behavior strategy generated by the behavior strategy decision layer does not exceed a second preset threshold, the behavior strategy decision layer is divided into a plurality of behavior strategy sub-decision layers according to a plurality of strategy types, each of the behavior strategy sub-decision layers being used to generate a corresponding type of behavior strategy; the plurality of strategy types including path planning strategy, competitive confrontation strategy, task execution strategy, and patrol and standby strategy;
[0148] It is understandable that the purpose of subdividing the behavior strategy decision layer into multiple behavior strategy sub-decision layers is to enable each sub-decision layer to focus on generating a specific type of behavior strategy, thereby improving the accuracy and pertinence of behavior strategy generation.
[0149] The second preset threshold is used to measure the accuracy and rationality of the behavioral strategies generated by the behavioral strategy decision layer. This embodiment does not impose any restrictions on the second preset threshold. It can be set based on the requirements of the exercise design, the player's expectations, and the behavioral characteristics of the virtual character. It can also be determined based on historical data, test results, or the experience of the exercise developer to ensure that the generated behavioral strategies both conform to the exercise logic and provide an interesting and challenging exercise experience. When the accuracy of the behavioral strategies generated by the behavioral strategy decision layer falls below the second preset threshold, the behavioral strategy decision layer needs to be divided. When the behavioral strategy decision layer is divided into multiple sub-decision layers, each sub-decision layer focuses on generating behavioral decisions of a corresponding type. There are many types of strategies. Although path planning strategies, competitive confrontation strategies, task execution strategies, and patrol and standby strategies already cover most of the behavioral requirements of virtual characters in exercises and can ensure that virtual characters can respond appropriately according to different situations and scenarios, this embodiment does not impose any restrictions on the number or types of strategies.
[0150] It should be understood that the path planning strategy is responsible for planning a reasonable movement path for the virtual character to ensure that it can reach the target location efficiently. The path planning strategy involves multiple aspects such as obstacle avoidance, finding the shortest path, and optimizing the movement speed. Competitive confrontation strategy: During the exercise, the virtual character needs to compete with other players or enemies. The competitive confrontation strategy is responsible for providing the virtual character with effective attack, defense and counterattack strategies to ensure that it gains an advantage in the battle. Task execution strategy: The virtual character needs to complete various tasks during the exercise, such as finding items, defeating enemies, protecting teammates, etc. The task execution strategy is responsible for providing the virtual character with the strategies and methods needed to complete the task to ensure that it can successfully complete the task. Patrol and standby strategy: In some cases, the virtual character needs to patrol or stand by in a specific area. The patrol and standby strategy is responsible for providing the virtual character with reasonable patrol routes and standby behaviors to ensure that it can respond correctly when needed.
[0151] Determine the updated behavior generation model including a plurality of the behavior sub-generation layers or a plurality of the behavior strategy sub-decision layers.
[0152] It should be noted that the reason for not dividing each model layer into multiple sub-layers before the behavior generation model is deployed, but rather only dividing the sub-layers after the accuracy of the virtual character's reaction movements has reached a preset threshold, is to consider the challenges and uncertainties before model deployment. Specifically, before model deployment, exercise developers often find it difficult to fully predict all possible scenarios and player behaviors in the exercise. The behavioral requirements of the virtual character are likely to change continuously as the exercise content is updated and expanded. Second, dividing the model into too many sub-layers in advance may lead to overly complex model structures, increasing the difficulty and cost of technical implementation. Exercise developers need to strike a balance between model complexity and flexibility. Third, before model deployment, there is often a lack of sufficient historical adversarial data to support the division and optimization of sub-layers. The collection and analysis of historical adversarial data usually requires actual exercise execution to ensure the authenticity and validity of the data. In addition, dividing the sub-layers after the generated virtual character's reaction movement accuracy is insufficient has the following advantages: First, by observing the virtual character's behavior during actual exercise execution, exercise developers can more accurately identify the behavior types that need optimization. This makes the division of sub-layers more targeted and can more effectively improve the accuracy and professionalism of behavior generation. Second, the subsequent division into sub-levels allows exercise developers to make dynamic adjustments based on changes in virtual scenarios and player behavior, which enhances the intelligence and adaptability of virtual characters, enabling them to better cope with various challenges in exercises.
[0153] In this embodiment, by subdividing the behavior generation layer into multiple behavior sub-generation layers, each sub-generation layer focuses on generating a specific type of behavior, improving behavior generation efficiency and ensuring both accuracy and diversity. Furthermore, by subdividing the behavior strategy decision layer into multiple behavior strategy sub-decision layers, virtual characters can make more reasonable and efficient decisions in different situations, improving their behavioral performance, enhancing the fun and challenge of simulation exercises, and providing players with a richer and more realistic simulation experience.
[0154] In addition, the embodiment of the present application provides a control system for virtual elements in a counter-game, such as Figure 2 As shown, Figure 2 This is a schematic diagram of the overall flow of a control system provided in an embodiment of the present application. Figure 2 The enemy character generation module is the following virtual character generation module.
[0155] In this embodiment, the system includes:
[0156] Large model loading module, used to load pre-trained large language models and image recognition models as the basis for generating virtual character behaviors and scenes;
[0157] The virtual character generation module uses a large model to generate virtual characters with specific attributes, skills, and behaviors based on exercise requirements and scenario settings;
[0158] The dynamic scene construction module adjusts the training scene's environmental parameters, obstacle layout, and prop distribution in real time based on the exercise progress and the behavior of the virtual character;
[0159] Interaction logic processing module, used to handle the interaction logic between virtual characters and players, including combat, dialogue, and strategy formulation;
[0160] The behavior prediction and adaptation module uses the predictive power of large models to predict the likely behavior of virtual characters and dynamically adjusts based on the player's response;
[0161] The data recording and analysis module records all data during the exercise, including the behavior of the virtual character, the player's reaction and the scene changes, for subsequent analysis and evaluation;
[0162] The feedback and optimization module adjusts the parameters of the large model based on the results of the data recording and analysis module to optimize the generation of virtual characters and the dynamic adaptation of the scene;
[0163] User interface module, which provides an intuitive operation interface, allowing players to easily control the exercise process and view relevant information;
[0164] The multimodal output module provides output in various forms including text, images, and sounds to enhance the realism and immersion of training.
[0165] Optionally, the step of generating a virtual character by the virtual character generating module includes:
[0166] Receive input on exercise requirements and scenario settings, including the number, type, and difficulty level of virtual characters;
[0167] Leverage the text generation capabilities of large language models to generate background stories, personality traits, and combat styles for virtual characters;
[0168] Assign corresponding skills and behavior patterns to the large language model based on the generated background story and personality traits;
[0169] The generated virtual character information is stored in the database for subsequent call and modification.
[0170] Optionally, the step of adjusting the training scene by the scene dynamic construction module includes:
[0171] Monitor the progress of the exercise in real time to obtain the position, behavior and player reaction of the virtual character;
[0172] Based on monitoring data, analyze whether the current scenario meets the exercise requirements, including difficulty, challenge, and realism;
[0173] If the requirements are not met, the image recognition or generation capabilities of the large model are used to adjust the environmental parameters of the scene, including lighting, weather, and terrain;
[0174] According to the behavior of the virtual character and the player's strategy, the obstacle layout and prop distribution are dynamically changed to increase the complexity and uncertainty of the scene.
[0175] Optionally, the step of the interaction logic processing module processing the interaction logic includes:
[0176] Define the rules of interaction between virtual characters and players, including combat rules, dialogue rules, and strategy formulation rules;
[0177] During the exercise, the interaction events between the virtual character and the player are judged in real time;
[0178] Based on the interaction rules and event types, the large model is called to make behavioral decisions or generate dialogues;
[0179] Provide real-time feedback to players on decision-making results or conversation content to promote the development of the exercise process.
[0180] Optionally, the step of predicting the behavior of the virtual character by the behavior prediction and adaptation module includes:
[0181] Leverage the predictive power of large models to analyze the current state, skills, and combat style of virtual characters;
[0182] Combine the player's historical reactions and current behavior to predict the virtual character's likely next move;
[0183] Dynamically adjust the behavior strategy of the virtual character based on the prediction results;
[0184] Monitor players' reactions and fine-tune the behavior prediction model if the predicted results do not match the actual reactions.
[0185] Optionally, the detailed steps of recording and analyzing data by the data recording and analysis module include:
[0186] Data preprocessing: receiving and initially processing raw data from virtual characters, players, and scene changes in real time. This includes data cleaning to remove duplicate, invalid, or abnormal data records, and data format conversion to convert raw data into a unified data format.
[0187] Data storage: store the pre-processed data in the database in timestamp order;
[0188] Feature extraction, using principal component analysis feature extraction algorithm to extract key features from the stored data, including the behavior patterns of virtual characters, player reaction time and scene change frequency;
[0189] Data analysis uses the K-means clustering algorithm to analyze the extracted features and mine hidden patterns, association rules, and anomalies in the data. The clustering algorithm formula is expressed as follows: For a given data set D={x1,x2, ..., x n}, through iterative optimization, the similarity of data points in the same cluster is high, and the similarity between different clusters is low. The specific algorithm is shown in Formula 1 above.
[0190] Pattern recognition, based on the analysis results, identifies the underlying patterns and regularities between virtual character behaviors, player reactions, and scene changes;
[0191] Report generation: organizes the analysis results and identified patterns into a report that includes an overview of the data analysis, key findings, pattern recognition results, and recommended improvement measures.
[0192] Optionally, the step of adjusting the large model parameters by the feedback and optimization module includes:
[0193] Receive the evaluation report generated by the data recording and analysis module and analyze the problems and deficiencies therein;
[0194] Determine the large model parameters or structures that need to be adjusted based on the problem type;
[0195] Use optimization algorithms to iteratively train large models until the expected optimization effect is achieved;
[0196] The optimized large model is reloaded into the system for subsequent exercise tasks.
[0197] Optionally, the operation interface provided by the user interface module includes:
[0198] Exercise control area, used to control the start, pause, end and progress adjustment of the exercise;
[0199] Avatar information display area, used to display the attributes, skills and status of the avatar;
[0200] Player information display area, used to display the player's health, equipment and position;
[0201] The scene display area displays the current status of the training scene in real time in the form of two-dimensional or three-dimensional images;
[0202] The interactive operation area provides function buttons or input boxes for dialogue and combat interactions with virtual characters.
[0203] Optionally, the output formats supported by the multimodal output module include:
[0204] Text output, used to display the dialogue content and combat prompts of virtual characters;
[0205] Image output, used to display two-dimensional or three-dimensional images of training scenes and images of virtual characters;
[0206] Sound output, used to play the virtual character's voice and combat sound effects;
[0207] Tactile output, including vibration and force feedback to simulate physical collisions or impacts in combat.
[0208] Optionally, the system further comprises:
[0209] Compatibility adaptation modules are used to integrate with existing exercise systems by providing standard API interfaces or data exchange formats.
[0210] It should be understood that by loading pre-trained large language models and image recognition models, intelligent generation and behavior prediction of virtual characters are achieved, giving them greater intelligence and behavioral diversity. This highly realistic simulation environment can more accurately reflect the complexity and variability of real battlefield environments, significantly improving the authenticity and effectiveness of various exercises and combat, such as military training, emergency drills, and simulated confrontation exercises.
[0211] The dynamic scenario construction module adjusts the training scenario's environmental parameters, obstacle layout, and prop distribution in real time based on the exercise progress and the virtual character's behavior. This dynamic adaptability ensures that the training scenario closely follows the actual development of the exercise, providing players with a richer and more varied challenging environment, thereby enhancing their response and strategic planning capabilities.
[0212] The Behavior Prediction and Adaptation module leverages the powerful predictive capabilities of large models to accurately predict the likely behavior of virtual characters and make instant adjustments based on player responses. This not only ensures that the virtual character's behavior more closely matches the strategies and behavioral patterns of virtual enemy characters in actual combat, but also significantly improves the relevance and effectiveness of training.
[0213] The Data Recording and Analysis module comprehensively records all data from the exercise, including the avatar's behavior, the player's reactions, and scene changes. This data provides valuable resources for subsequent in-depth analysis and evaluation, helping to identify deficiencies and areas for improvement, thereby optimizing training plans and improving training effectiveness.
[0214] The feedback and optimization module dynamically adjusts the parameters of the large model based on the results of data recording and analysis, continuously optimizing the prediction and generation of virtual character behavior and dynamic adaptation to scenarios. This continuous optimization process makes the system more flexible and intelligent, enabling it to better adapt to different training needs and scenario settings.
[0215] The multimodal output module provides output in various forms, including text, images, and sound, creating a comprehensive, multi-dimensional training environment for players. This immersive training experience can greatly stimulate player enthusiasm and participation, improving training effectiveness.
[0216] It's important to note that the large model loading module is responsible for loading pre-trained large language models and image recognition models. First, select a large language model suitable for the exercise, such as the GPT or BERT series, and an image recognition model, such as the ResNet or YOLO series, from the model library. These models are loaded into the system through the model loading interface, providing the foundation for subsequent generation of virtual character behaviors and scenarios.
[0217] Virtual Character Generation Module: Based on the specific needs and scenario of the exercise, this module uses a loaded master model to generate a virtual character. By inputting the character's attributes (such as military class, equipment, and skills), behavioral patterns (such as attack, defense, and retreat), and background story, the master model generates a virtual character with specific characteristics and behavioral logic. The generated character data includes text descriptions, image features, and behavioral scripts.
[0218] Dynamic Scenario Construction: This module adjusts the training scenario in real time based on the exercise progress and the behavior of the avatar. By monitoring real-time data from the exercise, such as the player's position, the avatar's movements, and combat status, the module dynamically adjusts environmental parameters (such as weather and lighting), obstacle layout (such as bunkers and traps), and prop distribution (such as weapons and supplies). Adjustments are made by invoking the scenario editor, ensuring that the scenario is closely aligned with the exercise progress.
[0219] Interaction Logic Processing Module: This module handles the interaction logic between the avatar and the player. By defining combat rules, dialogue mechanisms, and strategy development processes, the module enables combat interaction, information exchange, and strategic confrontation between the avatar and the player. This interaction logic leverages the predictive capabilities of the large model, enabling the avatar to respond to player behavior.
[0220] Behavior Prediction and Adaptation Module: Leveraging the predictive power of the large-scale model, this module predicts the likely behavior of the virtual character. By analyzing the historical data and current status of the virtual character and the player, the module predicts the virtual character's next move and dynamically adjusts it based on the player's response. Adjustments include modifying the virtual character's behavioral strategy, adjusting the combat pacing, and altering the dialogue content to ensure the authenticity and challenge of the simulation.
[0221] Data Recording and Analysis Module: This module records all data from the exercise, including avatar behavior, player reactions, and scene changes. This data is stored in a database and processed using data analysis algorithms to generate detailed exercise reports and evaluation metrics. These reports are used for subsequent training effectiveness analysis and system optimization.
[0222] Feedback and Optimization Module: Based on the results of the Data Recording and Analysis Module, this module adjusts the parameters of the large model to optimize the generation of virtual characters and dynamic adaptation to scenarios. Using machine learning algorithms, the module analyzes exercise data, identifies model performance bottlenecks, and adjusts model parameters to improve prediction accuracy and scenario adaptability.
[0223] User Interface Module: This module provides an intuitive interface, allowing players to easily control the exercise process and view relevant information. The interface includes features such as map display, character status monitoring, task list, and exercise progress control. User interaction with the system is achieved through a graphical interface and interactive controls.
[0224] Multimodal Output Module: To enhance the realism and immersion of training, this module provides multiple output formats, including text, images, and sound. By integrating text synthesis technology, an image rendering engine, and a sound effects library, the module enables the output of virtual character dialogue, real-time rendering of scene images, and playback of combat sounds, providing players with a comprehensive sensory experience.
[0225] Specific implementation of the virtual character generation module:
[0226] Receive input parameters: The system receives input from exercise planners or game developers. Input data includes the number of virtual characters, their types (e.g., infantry, tanks, scouts), and difficulty levels (e.g., beginner, intermediate, advanced). These parameters are used to guide the subsequent character generation process.
[0227] Generate background stories and personality traits: Leveraging the large model's text generation capabilities, a unique background story, personality traits, and combat style are generated for each virtual character based on the input type and difficulty level. For example, a high-level scout might possess extensive battlefield experience, keen insight, and cunning combat strategies.
[0228] Assigning skills and behavior patterns: Based on the generated background story and personality traits, the virtual character is assigned corresponding skills (such as sniping, demolition, and stealth) and behavior patterns (such as active attack, defensive counterattack, and retreat and escape). These skills and behavior patterns are represented by predefined labels or vectors and associated with the output layer of the large model.
[0229] Storing character information: The generated virtual character information, including background story, personality traits, skills and behavior patterns, as well as related images and text descriptions, is stored in a database. This information can be called up and modified during subsequent exercises to meet different exercise requirements.
[0230] like Figure 3 As shown, Figure 3 A schematic diagram of a scene dynamic adjustment process provided by an embodiment of the present application. Specific implementation of the scene dynamic construction module:
[0231] Real-time drill monitoring: Integrated sensors and data processing modules monitor the progress of drills in real time, capturing the virtual character's position, behavior, and player reactions. This data is used to analyze the current state and effectiveness of the scene.
[0232] Scenario Requirements Analysis: Based on monitoring data, the current scenario is analyzed to determine whether it meets the exercise requirements, including whether it is moderately difficult, sufficiently challenging, and realistic. This step is achieved through pre-set evaluation metrics and algorithms, such as difficulty assessment based on combat intensity and authenticity assessment based on player feedback.
[0233] Adjusting environmental parameters: If the current scene doesn't meet your requirements, leverage the image recognition or generation capabilities of the image recognition model to adjust the scene's environmental parameters. For example, you can alter lighting conditions (such as sunrise, sunset, or cloudy skies) to affect combat visibility; alter weather conditions (such as rain or snow) to increase combat difficulty; and alter terrain features (such as mountains or deserts) to influence combat strategy.
[0234] Dynamically change obstacles and props: Based on the avatar's behavior and the player's strategy, dynamically change the layout of obstacles (such as adding cover and setting traps) and the distribution of props (such as placing weapons and supplies). This step aims to increase the complexity and uncertainty of the scene, enhancing the realism and challenge of the simulation exercise.
[0235] Specific implementation of the interactive logic processing module:
[0236] Define interaction rules: Before the exercise begins, define the interaction rules between the virtual character and the player, including combat rules (such as attack range and damage calculation), dialogue rules (such as dialogue content and dialogue method), and strategy formulation rules (such as decision-making process and strategy selection). These rules are implemented through predefined scripts or algorithms.
[0237] Determining interactive events: During the exercise, interactive events between the virtual character and the player, such as combat contact, dialogue requests, and strategic negotiations, are determined in real time. This step is achieved through event monitoring and triggering mechanisms.
[0238] Invoking the big model for decision-making or dialogue: Based on the interaction rules and event type, the big model is invoked to make behavioral decisions or generate dialogue. For example, in a combat event, the big model selects the most appropriate attack method based on the avatar's fighting style and current state; in a dialogue event, the big model generates realistic dialogue content based on the avatar's personality traits and dialogue rules.
[0239] Feedback on decision results or conversation content: The large model's decision results or conversation content are fed back to the player in real time to advance the exercise. This step is achieved through the user interface module and multimodal output module, ensuring that the player can clearly perceive and understand the virtual character's actions and intentions.
[0240] Behavior Prediction and Adaptation Module: This module aims to dynamically adjust the behavior strategy of virtual characters through the predictive capabilities of the large model to more closely match the behavior of virtual characters in actual battlefields. The specific steps are as follows:
[0241] Analyze the virtual character status:
[0242] By leveraging the deep learning capabilities of large models, we conduct a comprehensive analysis of the virtual character's current status (such as position, health, and ammunition), skills (such as shooting accuracy and movement speed), and combat style (such as offensiveness and defensiveness), forming a comprehensive assessment of the virtual character's current capabilities.
[0243] Predicting the next move:
[0244] By combining the player's historical reactions (such as common strategies in combat and reaction time to specific situations) and current behaviors (such as movement direction and attack targets), the predictive capabilities of the large model are used to predict the virtual character's possible next counterattack action, such as attack, retreat, seeking cover, etc.
[0245] Dynamically adjust behavioral strategies:
[0246] Based on the prediction results, the avatar's behavior strategy is dynamically adjusted to better align with actual battlefield behavior. For example, if the avatar predicts that the player is about to attack, the avatar might retreat or seek cover; if the avatar predicts that the player is at a disadvantage, the avatar might attack.
[0247] Monitor and fine-tune the forecast model:
[0248] Monitor players' actual reactions in real time and compare them with the predicted results. If the predicted results don't match the actual reactions, it indicates a bias in the prediction model. Fine-tuning the prediction model is necessary to improve its accuracy. This can be achieved by adjusting the parameters of the larger model, increasing training data, or improving the prediction algorithm.
[0249] Data recording and analysis module: This module is responsible for recording and analyzing various data during the exercise, providing a basis for subsequent feedback and optimization. The specific implementation steps are as follows:
[0250] Data preprocessing: Receives raw data from virtual characters, players, and scene changes in real time and performs data cleaning to remove duplicate, invalid, or abnormal data records. It also converts the data into a unified format for subsequent processing and analysis.
[0251] Data storage: Preprocessed data is stored in a database in timestamp order to ensure data integrity and traceability. The database design should support efficient data query and retrieval to meet the needs of subsequent analysis.
[0252] Feature extraction: Using feature extraction algorithms such as principal component analysis (PCA), key features are extracted from the stored data. These features include the avatar's behavior patterns (e.g., attack frequency, movement paths), the player's reaction time (e.g., decision-making speed, operational accuracy), and scene change frequency (e.g., obstacle appearance frequency, weather change speed).
[0253] Data analysis: The K-means clustering algorithm is used to analyze the extracted features and mine the hidden patterns, association rules and anomalies in the data. The clustering analysis algorithm formula is expressed as follows: For a given data set D={x1, x2, ...,x n}, through iterative optimization, the similarity of data points within the same cluster is high, and the similarity between different clusters is low. The specific algorithm is shown in Equation 1 above.
[0254] Pattern Recognition: Based on the analysis results, potential patterns and regularities between virtual character behaviors, player reactions, and scene changes are identified. These patterns and regularities can provide strong support for subsequent exercise design, training strategy formulation, and large-scale model optimization.
[0255] Report Generation: Organize the analysis results and identified patterns into a report that includes an overview of the data analysis, key findings, pattern recognition results, and recommended improvement measures. The report should be presented in a clear and intuitive manner that is easy for exercise planners and players to understand and use.
[0256] Feedback and Optimization Module: This module is responsible for providing feedback and optimizing the large model based on the evaluation report generated by the data recording and analysis module. The specific steps are as follows:
[0257] Receive the evaluation report: Receive the evaluation report generated by the data recording and analysis module, and carefully read and understand the contents, especially the problems and deficiencies.
[0258] Determine the adjustment plan: Based on the problem type, determine the parameters or structure of the large model that need to be adjusted. For example, if the problem lies in prediction accuracy, you may need to adjust the prediction layer of the large model or add relevant features. If the problem lies in the behavioral strategy, you may need to adjust the behavioral decision layer of the large model or add new behavioral patterns.
[0259] Iterative training optimization: Large models are iteratively trained using optimization algorithms (such as gradient descent and genetic algorithms). During training, model parameters are continuously adjusted until the desired optimization effect is achieved. The optimization effect can be evaluated by comparing metrics such as prediction accuracy and behavioral strategy rationality before and after training.
[0260] Reload the model: Reload the optimized large model into the system for subsequent exercises. Before reloading, sufficient testing should be performed to ensure the model's stability and reliability in actual operation.
[0261] Specific implementation of the user interface module:
[0262] The user interface module is an important window for players to interact with the system. Its design should be intuitive, easy to use, and able to fully display key information during the exercise. The specific implementation method is as follows:
[0263] Exercise Control Area: This area provides a series of control buttons, such as "Start," "Pause," and "End," as well as a progress slider. Players can control the progress of the exercise by clicking these buttons, such as starting a new exercise, pausing the current one to adjust strategy, or ending the exercise to review the results. The progress slider allows players to quickly jump to specific stages of the exercise for review and analysis.
[0264] Avatar Information Display Area: This area displays the avatar's attributes (e.g., health, defense), skills (e.g., special attacks, movement speed), and current status (e.g., whether it's in combat or injured). This information is presented as charts, progress bars, or text descriptions, helping players quickly understand the avatar's strength and status, allowing them to formulate effective combat strategies.
[0265] Player Information Display Area: This area displays key player information, including health, equipment (such as weapons and armor), and current location. Health is represented by numbers or progress bars, equipment is displayed by icons or text descriptions, and location is indicated by a map or coordinate system. This information allows players to keep track of their combat status and position at all times, allowing them to make appropriate adjustments.
[0266] Scene Display Area: This area displays the current state of the training scene in real time using 2D or 3D graphics, including terrain, obstacles, avatars, and player positions. 2D images are suitable for simple scene presentations, while 3D images provide more realistic spatial perception and depth information. Players can rotate, zoom, and pan the camera to fully observe the training scene, enabling a better understanding of the battlefield environment and strategic planning.
[0267] Interactive Operation Area: This area provides a series of function buttons or input boxes for interacting with virtual characters during conversations and combat. For example, players can initiate an attack by clicking the "Attack" button or enter commands into the input box to engage in conversation with the virtual character. These interactions make the training process more interactive and realistic, helping to improve training effectiveness.
[0268] Specific implementation of the multimodal output module: The multimodal output module aims to provide players with a rich sensory experience through multiple output forms, enhancing the immersion and realism of the simulation exercise. The specific implementation method is as follows:
[0269] Text Output: This module displays the avatar's dialogue and combat prompts in text form. For example, when the avatar attacks, the system can prompt the player to dodge; when the player engages in a conversation with the avatar, the system can display the avatar's responses in text form. This concise and clear text output allows players to quickly access key information.
[0270] Graphics Output: This module displays 2D or 3D images of the training scene and the appearance of virtual characters. 2D images are suitable for simple scene and character presentation, while 3D images provide more realistic visuals and spatial perception. Through graphical output, players can more intuitively understand the battlefield environment and the appearance of the virtual characters.
[0271] Audio Output: This module plays the avatar's voice and combat sound effects. For example, when the avatar attacks, the system plays the corresponding attack sound effect; when the avatar speaks, the system plays the voice. Audio output enhances the immersion and realism of simulation exercises, making players more engaged in the process.
[0272] Haptic output: This module simulates physical collisions or impacts during combat through vibrations and force feedback. For example, when a player is hit by a virtual character, the system can use vibrations or force feedback to simulate the sensation of being hit. Haptic output can further enhance the realism and interactivity of simulations, allowing players to experience combat more deeply.
[0273] Specific implementation of the compatibility adaptation module: The compatibility adaptation module is designed to achieve seamless integration of this system with the existing exercise system, ensuring that this system can run smoothly in different environments and platforms. The specific implementation method is as follows:
[0274] Providing Standard APIs: This module features a series of standard APIs for data exchange and communication with other exercise systems. These APIs adhere to common data formats and communication protocols, ensuring smooth data and information transfer between different systems. Through these APIs, this technology can be easily integrated with existing exercise systems, enabling data sharing and interaction.
[0275] Standardized data exchange formats: In addition to providing an API interface, this module also defines a standardized data exchange format. This format specifies details such as data structure, type, and encoding, ensuring that different systems can accurately understand and parse data. By standardizing the data exchange format, this technology can more efficiently exchange and share data with other systems.
[0276] Adaptation to Different Platforms and Environments: This module also considers the differences and compatibility between different platforms and environments. By adapting and optimizing these platforms and environments, we ensure that the system can run smoothly and achieve optimal performance in a variety of environments. This includes support and optimization for different operating systems, hardware configurations, and network environments.
[0277] In this embodiment, intelligent and diverse virtual characters are generated by loading a pre-trained large language model and image recognition model. Based on the exercise progress and player reactions, the environmental parameters, obstacle layout, and virtual character behavior strategies of the training scene are adjusted in real time to achieve dynamic scene construction and adaptation. At the same time, multiple modules such as interactive logic processing, behavior prediction and adaptation, data recording and analysis, feedback and optimization are utilized to ensure the authenticity and effectiveness of the training. A multimodal output module provides output in various forms, such as text, images, and sound, enhancing the realism and immersion of training. This system is suitable for military training, emergency drills, and various simulated confrontation exercises.
[0278] Based on the method described in any of the above embodiments, the present application also provides Figure 4 A schematic diagram of the structure of an electronic device is shown in FIG. Figure 4At the hardware level, the electronic device includes a processor, an internal bus, a network interface, memory, and non-volatile storage, and may also include other hardware required for its services. The processor reads the corresponding computer program from the non-volatile storage into the memory and then runs it to implement the method described in any of the above embodiments.
[0279] Based on the method described in any of the above embodiments, the present application also provides a computer storage medium, which stores a computer program. When the computer program is executed by a processor, it can be used to execute the method described in any of the above embodiments.
[0280] Based on the method described in any of the above embodiments, the present application further provides a computer program product comprising one or more computer programs or instructions. The computer program or instructions may be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another. When the computer program is executed by a processor, the method described in any of the above embodiments is implemented.
[0281] The foregoing is merely an embodiment of the present application and is not intended to limit the scope of protection of the present application. Various modifications and variations are possible for those skilled in the art. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included within the scope of protection of the present application. It should be noted that similar reference numerals and letters represent similar items in the following figures. Therefore, once an item is defined in one figure, it does not need to be further defined or explained in subsequent figures.
Claims
1. A method for controlling virtual elements in a large-scale model-based simulation, characterized in that: The virtual elements include virtual characters and virtual scenes; the method includes: Acquiring historical confrontation data between the virtual character and the player at a historical moment in the simulation; the historical confrontation data includes historical behavior data of the virtual character, historical behavior data of the player, and historical layout data of the virtual scene; wherein the historical behavior data of the virtual character carries a personality tag of the virtual character; Analyzing the virtual character historical behavior data, the player historical behavior data, and the virtual scene historical layout data to determine an evaluation result of the confrontation authenticity and confrontation difficulty of the virtual scene at the historical moment; Adjusting the historical layout of the virtual scene based on the evaluation result to obtain a target virtual scene; Inputting the player's historical behavior data and the virtual character's personality tag into a behavior generation model to obtain a reaction action of the virtual character to the player; the reaction action is used to instruct the virtual character to use the reaction action to confront the player in the target virtual scene; Clustering the virtual character historical behavior data to obtain a plurality of first clusters, each of the first clusters being used to characterize a type of virtual character behavior; Clustering the player historical behavior data to obtain a plurality of second clusters, each of the second clusters being used to represent a category of player character behavior; Clustering the virtual scene historical layout data to obtain a plurality of third clusters, each of the third clusters being used to represent a type of scene; Determining a cluster set time series based on the association relationship between each of the first clusters, each of the second clusters, and each of the third clusters; the cluster set time series includes a plurality of cluster sets arranged in time; each of the cluster sets includes a type of the virtual character behavior, a category of the player character behavior, and a type of the scene that are mutually associated; Determining a conversion rule between at least two temporally consecutive cluster sets from the cluster set time series; the conversion rule is used to characterize the behavior changes and scene transitions of the virtual character, the player, and the virtual scene at different time nodes; Determining a first reaction pattern of the virtual character in different virtual scenes and player character behaviors from the conversion rules, and determining a reaction weakness of the virtual character based on the first reaction pattern; updating the behavior generation model based on the reaction weaknesses of the virtual character to obtain an updated behavior generation model; A second reaction pattern of the player in different virtual scenes and virtual character behaviors is determined from the conversion rule, and the player's reaction weaknesses are determined based on the second reaction pattern, and a weakness analysis report generated according to the player's reaction weaknesses is output to the player.
2. The method according to claim 1, wherein Before obtaining the historical confrontation data between the virtual character and the player at the historical moment of the simulation, the method further includes: In response to a scene generation instruction carrying scene image data, performing scene feature recognition processing on the scene image data using a preset recognition model to obtain scene features; The virtual scene is generated using the scene features.
3. The method according to claim 1, wherein Before obtaining the historical confrontation data between the virtual character and the player at the historical moment of the simulation, the method further includes: Input the preset character attributes, character behavior patterns, and character background stories into the character reasoning model to obtain basic character parameters, and use the basic character parameters to construct the virtual character; the basic character parameters include character description information, character dialogue text, and character behavior script; wherein, the character description information includes the virtual character personality label; the character dialogue text includes the sentence text of the virtual character that conforms to the virtual character personality label, the character behavior script is used to indicate a variety of personalized behaviors that conform to the virtual character personality label, and the reaction action is any one or more of the multiple personalized behaviors.
4. The method according to claim 3, wherein After constructing the virtual character using the basic character parameters, the method further includes: Obtaining preset confrontation rules for the virtual character, the preset confrontation rules including attack range calculation rules, damage calculation rules, dialogue content generation rules, dialogue mode selection rules, decision process generation rules, and strategy selection rules; The step of inputting the player's historical behavior data and the virtual character's personality tag into a behavior generation model to obtain the virtual character's reaction action to the player includes: The player's historical behavior data, the virtual character's personality tag, and the preset confrontation rules are input into the behavior generation model to obtain the reaction action that meets the preset confrontation rules.
5. The method according to claim 1, wherein The virtual character historical behavior data includes the virtual character's historical position change data and the virtual character's historical action data; the player's historical behavior data includes the player's historical position change data and the player's historical action data; the historical layout includes historical environmental parameters, historical obstacle layout, and historical prop distribution; The analyzing the virtual character historical behavior data, the player historical behavior data, and the virtual scene historical layout data to determine an evaluation result of the virtual scene's confrontation authenticity and confrontation difficulty at the historical moment includes: Analyzing the virtual character's historical position change data and the player's historical position change data to determine a confrontation authenticity result, analyzing the virtual character's historical action data and the virtual character's historical action data to determine a confrontation difficulty result, and obtaining the evaluation result including the confrontation authenticity result and the confrontation difficulty result; The adjusting the historical layout of the virtual scene based on the evaluation result to obtain a target virtual scene includes: The historical environment parameters are adjusted based on the comparison result of the confrontation authenticity result and the preset authenticity threshold, and the historical obstacle layout and the historical prop distribution are adjusted based on the comparison result of the confrontation difficulty result and the preset difficulty threshold to obtain the target virtual scene.
6. The method according to claim 1, wherein The behavior generation model includes a behavior strategy decision layer and a behavior generation layer connected in sequence; The updating of the behavior generation model based on the reaction weakness of the virtual character to obtain an updated behavior generation model includes: When the virtual character's reaction weakness indicates that the accuracy of the virtual character behavior generated by the behavior generation layer does not exceed a first preset threshold, dividing the behavior generation layer into a plurality of behavior sub-generation layers according to a plurality of behavior types, each of the behavior sub-generation layers being used to generate a corresponding type of behavior; the plurality of behavior types including attack, defense, and movement; In a case where the reaction weakness of the virtual character indicates that the accuracy of the virtual character behavior strategy generated by the behavior strategy decision layer does not exceed a second preset threshold, dividing the behavior strategy decision layer into a plurality of behavior strategy sub-decision layers according to a plurality of strategy types, each of the behavior strategy sub-decision layers being used to generate a corresponding type of behavior strategy; the plurality of strategy types including path planning strategy, competitive confrontation strategy, task execution strategy, and patrol and standby strategy; Determine the updated behavior generation model including a plurality of the behavior sub-generation layers or a plurality of the behavior strategy sub-decision layers.
7. An electronic device, characterized in that: The electronic device comprises: processor; a memory for storing processor-executable instructions; Wherein, when the processor calls the executable instruction, it implements the method described in any one of claims 1-6.
8. A computer-readable storage medium, characterized in that Computer instructions are stored thereon, and when the computer instructions are executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
9. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Virtual character control method and device, electronic equipment and storage medium
CN111450531A
Game interaction simulation method and device, computer equipment and storage medium
CN116870479A
Virtual object control model generation method and device, virtual object interaction method and device and computer equipment
CN118593996A
Cited By
Intelligent battlefield situation analysis and generation method and system based on multi-modal semantic understanding and mcp cooperation
CN122527726A