Automatic testing and quality evaluation system for game development
By generating a combination of collision recovery coefficients and random seed values, a test case set with multi-dimensional disturbance characteristics is constructed, which solves the problems of limited coverage and insufficient detection of physical logic deviations in existing game testing systems, and realizes efficient automated testing and quality assessment.
Patent Information
- Application Number
- CN202510766507.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-10
- Publication Date
- 2025-09-19
AI Technical Summary
The existing automated testing and quality assessment systems for game development lack a random perturbation mechanism, resulting in limited coverage and an inability to accurately capture potential physical logic deviations. The overall testing performance needs to be optimized.
The physical parameter acquisition module collects game status information in real time, generates a collision recovery coefficient sequence and a random seed value, combines the perturbation rules to generate a test case set, and records scene data through a timing collector to identify physical logic errors. The optimization feedback module adjusts parameters to achieve closed-loop optimization.
The breadth and depth of test coverage have been significantly improved, enabling precise capture of abnormal performance fluctuations, accurate determination of physical and logical consistency, and adaptive adjustment by reversely locating the root cause of errors.
Smart Images

Figure CN120670304A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of game development, and in particular to an automated testing and quality assessment system for game development. Background Art
[0002] With the gradual development of the electronic game industry, the game development process has become increasingly complex, involving the collaboration of multiple modules, including graphics rendering, physics simulation, event-driven, network synchronization, etc. Especially in games with high interactivity and diverse scenarios, developers have put forward higher requirements for the consistency of physical logic, system stability and user interaction experience during the game operation. In order to ensure product quality, game testing has become an indispensable part.
[0003] However, the current automated testing and quality assessment systems used for game development still face some challenges in actual operation. First, the construction of existing game test scenarios often relies on fixed scripts or static inputs, and lacks an event perturbation mechanism based on initial random seeds, resulting in limited coverage; second, in the error identification link, existing methods mostly rely on surface performance or result comparison, and cannot accurately capture potential physical logic deviations based on frame-level timing information. The overall test system performance needs to be optimized. Summary of the Invention
[0004] In order to solve the technical problems mentioned in the current background technology, such as the lack of disturbance and randomness in test case generation and insufficient granularity in physical logic error detection in the existing automated testing and quality assessment systems for game development, the purpose of the present invention is to provide an automated testing and quality assessment system for game development with better overall testing performance.
[0005] In order to achieve the above object, the present invention adopts the following technical solutions:
[0006] An automated testing and quality assessment system for game development, comprising:
[0007] M1, a physical parameter acquisition module, collects the state information of the game in real time through the underlying interface of the physics engine, derives the collision restitution coefficient based on the state information and generates a collision restitution coefficient sequence, and simultaneously reads the initial random seed value of the game through the underlying interface of the random number generator; and composes a physical parameter set based on the collision restitution coefficient sequence and the initial random seed value;
[0008] M2, a test case generation module, which performs a numerical offset on the collision recovery coefficient using a preset perturbation rule to generate a perturbed collision recovery coefficient sequence, and simultaneously generates a random event trigger sequence based on the initial random seed value; and composes a test case set based on the perturbed collision recovery coefficient sequence and the random event trigger sequence;
[0009] M3, a physical logic error detection module, inputs the physical parameter set into the game engine to execute the original scene operation, and simultaneously inputs the test case set into the game engine to execute the test scene operation, and records the timing data of the original scene and the test scene respectively during operation through a timing collector; compares the timing data differences between the original scene and the test scene to identify physical logic errors; and forms a physical logic error set based on the physical logic errors;
[0010] M4, optimization feedback module, based on the physical logic error set, extracts the post-disturbance collision recovery coefficient in the disturbance collision recovery coefficient sequence and the event number in the random event trigger sequence; calculates the collision recovery coefficient correction value and the adjusted initial random seed value, and synchronously feeds back and updates them to the physical parameter set; generates a new round of the test case set based on the updated physical parameter set to continue executing M3 and M4 modules, and outputs the final optimization result after reaching the termination condition.
[0011] Furthermore, the state information includes the position of the entity before and after the collision and the time points before and after the collision;
[0012] Calculating a collision recovery coefficient based on the state information, wherein the calculation process of the collision recovery coefficient includes calculating a collision speed and calculating the collision recovery coefficient based on the collision speed;
[0013] Based on the i-th collision recovery coefficient e i Construct a collision recovery coefficient sequence E, and E={e1,e2,…,e k}, where k is the length of the collision restitution coefficient sequence;
[0014] The initial random seed value is recorded as s0, and s0∈[0,1,2,3,…];
[0015] Construct a standard physical parameter set based on the collision restitution coefficient sequence E and the initial random seed value s0 and
[0016] Furthermore, the steps of calculating the disturbance collision recovery coefficient sequence include calculating a disturbance offset, calculating a post-disturbance collision recovery coefficient based on the disturbance offset, and generating the disturbance collision recovery coefficient sequence based on the post-disturbance collision recovery coefficient;
[0017] The disturbance offset Δe i The calculation formula is:
[0018]
[0019] Among them, w iis the sensitivity weight of the i-th collision; ∈ i is the uniformly distributed disturbance term; δ is the maximum amplitude of the disturbance; It means uniform distribution on the interval [-δ,δ];
[0020] The disturbance offset Δe i Added to the original collision recovery coefficient e i Get the collision recovery coefficient e′ after disturbance i , and e′ i =clip(e i +Δe i ,0,1);
[0021] Based on the post-disturbance collision recovery coefficient e′ i The disturbance collision recovery coefficient sequence E′ is obtained, and E′={e′1, e′2,…, e′ k}, where k is the length of the collision recovery coefficient sequence after disturbance;
[0022] The step of generating the random event trigger sequence comprises: using the initial random seed value to generate a pseudo-random number sequence, performing a modulo operation on the pseudo-random integer in the pseudo-random number sequence to generate an event trigger number, and generating a random event trigger sequence based on the event trigger number;
[0023] Based on the initial random seed value s0, a pseudo-random number sequence Z of length k is generated by a pseudo-random function f:
[0024] Z={f(s0,1),f(s0,2),…,f(s0,i),…,f(s0,k)}
[0025] Where f(s0,i) represents the i-th pseudo-random integer generated with the initial random seed value s0 and index i as input;
[0026] Perform a modulo operation on the pseudo-random integer in the pseudo-random number sequence Z to generate the event trigger number r i , and r i =f(s0,i)mod M, where M is the total number of event types; mod is the modulo operator;
[0027] Based on the event trigger number r i The random event trigger sequence R is obtained, and R={r1,r2,…,r k}, where k is the length of the random event trigger sequence;
[0028] The disturbance collision recovery coefficient sequence E′ and the random event trigger sequence R are combined according to the index to construct a test case set T, and T={(e′1,r1),(e′2,r2),…,(e′ k ,r k )}.
[0029] Furthermore, the timing data includes a physics engine calculation cycle sequence, an event response timestamp sequence, and a frame rendering interval sequence;
[0030] The timing collector is an auxiliary monitoring module in the system and is integrated into the running path of the physics engine. The collection methods of the timing collector include function instrumentation collection method, event hook registration collection method and rendering scheduling monitoring collection method;
[0031] The function instrumentation acquisition method is used to acquire frame-level physics calculation time, and output the physics engine calculation cycle sequence based on the frame-level physics calculation time;
[0032] The physics engine calculation cycle sequence of the original scene is: Expressed as:
[0033]
[0034] The physics engine calculation cycle sequence of the test scenario is: Expressed as:
[0035]
[0036] Where n is the total number of frames, The physical calculation time of the i-th frame of the original scene; The physical calculation time of the i-th frame of the test scene;
[0037] The event hook registration and collection method is used to record the event response timestamp at the event triggering moment, and output the event response timestamp sequence based on the event response timestamp:
[0038] The event response timestamp sequence of the original scene is τ (ori) , expressed as:
[0039]
[0040] The event response timestamp sequence of the test scenario is τ (test) , expressed as:
[0041]
[0042] Where m is the number of events; is the trigger timestamp of the jth event in the original scene; is the trigger timestamp of the jth event in the test scenario;
[0043] The rendering scheduling monitoring acquisition method is used to record the graphics rendering timestamp of each frame, and obtain a rendering timestamp sequence based on the rendering timestamp;
[0044] The graphics rendering timestamp sequence of the original scene is: Expressed as:
[0045]
[0046] The graphics rendering timestamp sequence of the test scene is: Expressed as:
[0047]
[0048] Where n is the total number of frames; The timestamp of the graphics rendering of the i-th frame in the original scene; The timestamp of the graphics rendering of the i-th frame in the test scene;
[0049] Based on the rendering timestamp, calculate the rendering time interval between consecutive frames The calculation formula is:
[0050]
[0051] in, and is the rendering timestamp of the i-th frame and the i+1-th frame; *∈{ori,test}, represents the original scene or the test scene; n-1 is the total number of rendering intervals;
[0052] Based on the rendering time interval Constructing the frame rendering interval sequence;
[0053] The frame rendering interval sequence of the original scene is Δ (ori) , expressed as:
[0054]
[0055] The frame rendering interval sequence of the test scene is Δ (test) , expressed as:
[0056]
[0057] in, is the rendering interval of the i-th item in the original scene; Rendering interval for the i-th item in the test scene.
[0058] Furthermore, the average difference D of the periodic sequence is calculated based on the physical engine calculation. c , the calculation formula is:
[0059]
[0060] Where n is the total number of frames;
[0061] Calculate the average event response delay difference D based on the event response timestamp sequence e , the calculation formula is:
[0062]
[0063] Where m is the number of events;
[0064] Calculate the frame rendering interval standard deviation D based on the frame rendering interval sequence f , the calculation formula is:
[0065]
[0066] Among them, n-1 is the number of frames;
[0067] Based on the period average difference D c , average difference in incident response delay D e and frame rendering interval standard deviation D f Perform physical logic error judgment, the judgment formula is:
[0068]
[0069] Among them, θ c ,θ e ,θ f Calculate the average difference D of the period series respectively c , average difference in incident response delay D e and frame rendering interval standard deviation D f Tolerance threshold; D>θ means that a certain difference index exceeds its threshold, that is, there is a physical logic error;
[0070] Generate a physical logic error set ε based on the physical logic error e , and ε e ={T,i}, indicating that the test case set T has a physical logic error in the i-th frame.
[0071] Furthermore, for the physical logic error set ε e Each error record {T,i} in the corresponding perturbation collision recovery coefficient e′ is extracted from the perturbation collision recovery coefficient sequence i and the event number r in the random event trigger sequence i, then (e′ i ,r i ) is the target parameter point to be evaluated and corrected, wherein the disturbance collision recovery coefficient e′ i As the parameter to be modified, based on the corresponding event number r i Calculating the event frequency deviation for adjusting the initial random seed value;
[0072] Based on the post-disturbance collision recovery coefficient, a standard collision recovery coefficient e is obtained from the physical parameter set. i Based on the random event trigger sequence R = {r1, r2, ..., r k}Get the theoretical trigger frequency f of each event type r r ,and Wherein, k is the total number of sampling times, which is equivalent to the common length of the event trigger number sequence, the collision recovery coefficient sequence, and the post-disturbance collision recovery coefficient sequence;
[0073] According to the event r in the current test round i Number of occurrences n r Calculate its actual trigger frequency The calculation formula is:
[0074]
[0075] Where L is the number of events in all test cases;
[0076] Based on the post-disturbance collision recovery coefficient e′ i and the standard collision restitution coefficient e i The collision recovery coefficient deviation Δe′ is obtained i , and Δe′ i =e i -e′ i ; Based on the theoretical trigger frequency and the actual trigger frequency Event frequency deviation and
[0077] Based on the collision restitution coefficient deviation Δe′ i Deviation from the event frequency The correction conditions are:
[0078]
[0079] Among them, δ e and δ f is the preset deviation threshold.
[0080] Furthermore, when the correction condition is met, the collision recovery coefficient is corrected, and the initial random seed value is adjusted based on the event frequency deviation;
[0081] The correction formula of the collision restitution coefficient is:
[0082]
[0083] in, is the correction value of the collision recovery coefficient; η e is the learning rate of the collision recovery coefficient, which is used to control the correction amplitude;
[0084] The adjustment formula of the initial random seed value is:
[0085]
[0086] Among them, S new is the initial random seed value after adjustment; s0 is the initial random seed value; η s Update the step size coefficient for the seed;
[0087] The corrected collision recovery coefficient correction value and the adjusted initial random seed value S new Update the physical parameter set in M1 to obtain the updated physical parameter set Expressed as:
[0088]
[0089] Continuing the test process based on the updated physical parameter set, the termination condition is that the number of physical logic errors detected in N consecutive iterations is lower than a preset threshold or the maximum number of iterations is reached;
[0090] The final optimization result includes the finally optimized collision recovery coefficient, the random event triggering weight and the physical logic error detection report.
[0091] Compared with the prior art, the advantages of the present invention are:
[0092] 1. The present invention introduces a mechanism that combines collision restitution coefficient perturbations with random event trigger sequences to construct a test case set with multi-dimensional perturbation characteristics. It not only introduces perturbations in the parameter dimension to simulate physical anomalies, but also drives event sequence generation through random seeds, so that each round of testing can automatically construct a dynamic operation path that is different from the previous one. This overcomes the problems of single coverage and poor reproducibility brought about by traditional test systems that rely on fixed scripts, and significantly improves the breadth and depth of test coverage.
[0093] 2. The present invention establishes a frame-level physical logic consistency criterion by introducing three types of data: periodic sequence, event response timestamp sequence, and frame rendering interval sequence. Through the combined judgment mechanism of difference index and tolerance threshold, it can achieve fine capture of abnormal performance fluctuations, event delays, and frame imbalance problems. At the same time, the system reversely locates the specific disturbance parameters and event numbers through errors, and drives the optimization feedback module to adjust the disturbance strategy and seed value, thereby forming a closed-loop correction system, which solves the problem that traditional test systems cannot locate the root cause of errors and cannot make adaptive adjustments. BRIEF DESCRIPTION OF THE DRAWINGS
[0094] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0095] Figure 1 Schematic diagram of the system workflow of the present invention;
[0096] Figure 2 This is a schematic diagram of the physical parameter set composition process of the present invention;
[0097] Figure 3 The figure is a flow chart of the test case set composition process of the present invention. DETAILED DESCRIPTION
[0098] To make the purpose, technical solutions, and advantages of the embodiments of this application more clear, the technical solutions in the embodiments of this application will be clearly and completely described below in conjunction with the drawings in the embodiments of this application. Obviously, the described embodiments are part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0099] To achieve the above objectives, the present invention is implemented through the following technical solutions: the present invention provides an automated testing and quality assessment system for game development, such as Figure 1-Figure 3 As shown, the system includes:
[0100] M1, physical parameter acquisition module, collects the status information of the game running in real time through the underlying interface of the physical engine, derives the collision recovery coefficient based on the status information and generates a collision recovery coefficient sequence, and at the same time reads the initial random seed value of the game running through the underlying interface of the random number generator; and forms a physical parameter set based on the collision recovery coefficient sequence and the initial random seed value.
[0101] The state information includes the position of the entity before and after the collision and the time points before and after the collision;
[0102] Calculating a collision recovery coefficient based on the state information, wherein the calculation process of the collision recovery coefficient includes calculating a collision speed and calculating the collision recovery coefficient based on the collision speed;
[0103] Define that in the i-th collision event, entity A and entity B come into contact, and the reference time of the collision is t i (in seconds), the collision normal direction is the unit vector The time point before the collision is t i -Δt, the time point after the collision is t i +Δt, where Δt is the sampling interval, then the position information of the entity A and entity B before and after the collision are respectively expressed as:
[0104] The position information of entity A and entity B before the collision are respectively expressed as:
[0105]
[0106] The position information of the entity A and entity B after the collision are respectively expressed as:
[0107]
[0108] Based on the four sets of position information, the velocity calculation formula for the front-to-back collision of the entities A and B in the i-th collision is:
[0109] 1) The velocity of entity A before collision is and
[0110] 2) The velocity of entity B before collision is and
[0111] 3) The speed of entity A after collision is and
[0112] 4) The speed of entity B after collision is and
[0113] Based on the fact that the velocity of entity A before collision is The velocity of entity B before collision is The speed of entity A after collision is After colliding with the entity B, the speed is The coefficient of recovery for the i-th collision is obtained using the following formula:
[0114]
[0115] Among them, e i is the coefficient of restitution for the ith collision (dimensionless), and e i ∈[0,1], where 0 represents a completely inelastic collision and 1 represents a completely elastic collision;
[0116] Based on the i-th collision recovery coefficient e i Construct a collision recovery coefficient sequence E, and E={e1,e2,…,e k}, where k is the length of the collision restitution coefficient sequence;
[0117] The initial random seed value is recorded as s0, and s0∈[0,1,2,3,…];
[0118] Construct a standard physical parameter set based on the collision restitution coefficient sequence E and the initial random seed value s0 and
[0119] M2, a test case generation module, performs a numerical offset on the collision recovery coefficient through a preset perturbation rule to generate a perturbation collision recovery coefficient sequence, and generates a random event trigger sequence based on the initial random seed value; and forms a test case set based on the perturbation collision recovery coefficient sequence and the random event trigger sequence.
[0120] The steps of calculating the disturbance collision recovery coefficient sequence include calculating a disturbance offset, calculating a post-disturbance collision recovery coefficient based on the disturbance offset, and generating the disturbance collision recovery coefficient sequence based on the post-disturbance collision recovery coefficient;
[0121] The disturbance offset Δe i The calculation formula is:
[0122]
[0123] Among them, w i is the sensitivity weight of the i-th collision, and w i ∈[0,1];∈ i is a uniformly distributed disturbance term used to simulate human bias; δ is the maximum amplitude of the disturbance, and δ = 0.1; It means uniform distribution on the interval [-δ,δ];
[0124] The disturbance offset Δe i Added to the original collision recovery coefficient e i and use the tailoring function to define the perturbation offset Δe i and the collision restitution coefficient e iThe accumulated value is within the legal range [0,1], and the post-disturbance collision recovery coefficient e′ is obtained. i , and e′ i =clip(e i +Δe i ,0,1);
[0125] Based on the post-disturbance collision recovery coefficient e′ i The disturbance collision recovery coefficient sequence E′ is obtained, and E′={e′1, e′2,…, e′ k}, where k is the length of the collision recovery coefficient sequence after disturbance;
[0126] The step of generating the random event trigger sequence comprises: using the initial random seed value to generate a pseudo-random number sequence, performing a modulo operation on the pseudo-random integer in the pseudo-random number sequence to generate an event trigger number, and generating a random event trigger sequence based on the event trigger number;
[0127] Based on the initial random seed value s0, a pseudo-random number sequence Z of length k is generated by a pseudo-random function f:
[0128] Z={f(s0,1),f(s0,2),…,f(s0,i),…,f(s0,k)}
[0129] Where f(s0,i) represents the i-th pseudo-random integer generated with the initial random seed value s0 and index i as input;
[0130] Perform a modulo operation on the pseudo-random integer in the pseudo-random number sequence Z to generate the event trigger number r i , and r i =f(s0,i)mod M, where M is the total number of event types; mod is the modulo operator, limiting the output to [0,M-1];
[0131] Based on the event trigger number r i The random event trigger sequence R is obtained, and R={r1,r2,…,r k}, where k is the length of the random event trigger sequence;
[0132] The disturbance collision recovery coefficient sequence E′ and the random event trigger sequence R are combined according to the index to construct a test case set T, and T={(e′1,r1),(e′2,r2),…,(e′ k ,r k )}.
[0133] M3, physical logic error detection module, inputs the physical parameter set into the game engine to execute the original scene operation, and at the same time inputs the test case set into the game engine to execute the test scene operation, and records the timing data of the original scene and the test scene during operation through a timing collector; compares the timing data differences between the original scene and the test scene to identify physical logic errors; and composes a physical logic error set based on the physical logic errors.
[0134] The timing data includes a physics engine calculation cycle sequence, an event response timestamp sequence, and a frame rendering interval sequence;
[0135] The timing collector is an auxiliary monitoring module in the system and is integrated into the running path of the physics engine. The collection methods of the timing collector include function instrumentation collection method, event hook registration collection method and rendering scheduling monitoring collection method;
[0136] The timing collector adopts a function instrumentation acquisition method to implant timing logic at the computation entry and exit of each frame of the physics engine to acquire frame-level physics computation time, and outputs the physics engine computation cycle sequence based on the frame-level physics computation time;
[0137] The physics engine calculation cycle sequence of the original scene is: Expressed as:
[0138]
[0139] The physics engine calculation cycle sequence of the test scenario is: Expressed as:
[0140]
[0141] Where n is the total number of frames, The physical calculation time of the i-th frame of the original scene; The physical calculation time of the i-th frame of the test scene;
[0142] The timing collector adopts the event hook registration collection method to register monitoring hooks in all event processing functions in the physical engine to record the event response timestamp at the time of event triggering, and output the event response timestamp sequence based on the event response timestamp:
[0143] The event response timestamp sequence of the original scene is τ (ori) , expressed as:
[0144]
[0145] The event response timestamp sequence of the test scenario is τ (test) , expressed as:
[0146]
[0147] Where m is the number of events; is the trigger timestamp of the jth event in the original scene; is the trigger timestamp of the jth event in the test scenario;
[0148] The timing collector adopts the rendering scheduling monitoring collection method, accesses the frame scheduling point of the graphics rendering module to record the graphics rendering timestamp of each frame, and obtains the rendering timestamp sequence based on the rendering timestamp:
[0149] The graphics rendering timestamp sequence of the original scene is: Expressed as:
[0150]
[0151] The graphics rendering timestamp sequence of the test scene is: Expressed as:
[0152]
[0153] Where n is the total number of frames; The timestamp of the graphics rendering of the i-th frame in the original scene; The timestamp of the graphics rendering of the i-th frame in the test scene;
[0154] Based on the rendering timestamp, calculate the rendering time interval between consecutive frames The calculation formula is:
[0155]
[0156] in, and is the rendering timestamp of the i-th frame and the i+1-th frame; *∈{ori,test}, represents the original scene or the test scene; n-1 is the total number of rendering intervals;
[0157] Based on the rendering time interval Constructing the frame rendering interval sequence;
[0158] The frame rendering interval sequence of the original scene is Δ (ori) , expressed as:
[0159]
[0160] The frame rendering interval sequence of the test scene is Δ (test) , expressed as:
[0161]
[0162] in, is the rendering interval of the i-th item in the original scene; The rendering interval for the i-th item in the test scene;
[0163] The physics engine calculates the periodic sequence and calculates the periodic average difference D c , the calculation formula is:
[0164]
[0165] Where n is the total number of frames;
[0166] Calculate the average event response delay difference D based on the event response timestamp sequence e , the calculation formula is:
[0167]
[0168] Where m is the number of events;
[0169] Calculate the frame rendering interval standard deviation D based on the frame rendering interval sequence f , the calculation formula is:
[0170]
[0171] Among them, n-1 is the number of frames;
[0172] Based on the period average difference D c , average difference in incident response delay D e and frame rendering interval standard deviation D f Perform physical logic error judgment, the judgment formula is:
[0173]
[0174] Among them, θ c ,θ e ,θ f Calculate the average difference D of the period series respectively c , average difference in incident response delay D e and frame rendering interval standard deviation D f Tolerance threshold; D>θ means that a certain difference index exceeds its threshold, that is, there is a physical logic error;
[0175] Generate a physical logic error set ε based on the physical logic error e , and ε e ={T,i}, indicating that the test case set T has a physical logic error in the i-th frame.
[0176] M4, optimization feedback module, based on the physical logic error set, extracts the post-disturbance collision recovery coefficient in the disturbance collision recovery coefficient sequence and the event number in the random event trigger sequence; calculates the collision recovery coefficient correction value and the adjusted initial random seed value, and synchronously feeds back and updates them to the physical parameter set; generates a new round of the test case set based on the updated physical parameter set to continue executing M3 and M4 modules, and outputs the final optimization result after reaching the termination condition.
[0177] For the physical-logical error set ε e Each error record {T,i} in the corresponding perturbation collision recovery coefficient e′ is extracted from the perturbation collision recovery coefficient sequence i and the event number r in the random event trigger sequence i , then (e′ i ,r i ) is the target parameter point to be evaluated and corrected, wherein the disturbance collision recovery coefficient e′ i As the parameter to be modified, based on the corresponding event number r i Calculating the event frequency deviation for adjusting the initial random seed value;
[0178] Based on the post-disturbance collision recovery coefficient, a standard collision recovery coefficient e is obtained from the physical parameter set. i Based on the random event trigger sequence R = {r1, r2, ..., r k}Get the theoretical trigger frequency of each event type r and Wherein, k is the total number of sampling times, which is equivalent to the common length of the event trigger number sequence, the collision recovery coefficient sequence, and the post-disturbance collision recovery coefficient sequence;
[0179] According to the event r in the current test round i Number of occurrences n r Calculate the actual trigger frequency of the event r The calculation formula is:
[0180]
[0181] Where L is the number of events in all test cases;
[0182] Based on the post-disturbance collision recovery coefficient e′ i and the standard collision restitution coefficient e i The collision recovery coefficient deviation Δe′ is obtained i , and Δe′ i =e i -e′ i ; Based on the theoretical trigger frequency and the actual trigger frequency Event frequency deviation and
[0183] Based on the collision restitution coefficient deviation Δe′ i Deviation from the event frequency The correction conditions are:
[0184]
[0185] Among them, δ e and δ f is a preset deviation threshold;
[0186] When the above correction conditions are met, the collision recovery coefficient is corrected, and the initial random seed value is adjusted based on the event frequency deviation;
[0187] The correction formula of the collision restitution coefficient is:
[0188]
[0189] in, is the correction value of the collision recovery coefficient; η e is the learning rate of the collision recovery coefficient, which is used to control the correction amplitude;
[0190] The adjustment formula of the initial random seed value is:
[0191]
[0192] Among them, S new is the initial random seed value after adjustment; s0 is the initial random seed value; η s Update the step size coefficient for the seed;
[0193] The corrected collision recovery coefficient correction value and the adjusted initial random seed value S new Update the physical parameter set in M1 to obtain the updated physical parameter set Expressed as:
[0194]
[0195] Continuing the test process based on the updated physical parameter set, the termination condition is that the number of physical logic errors detected in N consecutive iterations is lower than a preset threshold or the maximum number of iterations is reached;
[0196] The final optimization result includes the finally optimized collision recovery coefficient, the random event triggering weight and the physical logic error detection report.
[0197] The above description is merely a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in this application should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.
[0198] Finally: The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. An automated testing and quality assessment system for game development, characterized in that: include: M1, a physical parameter acquisition module, collects the state information of the game in real time through the underlying interface of the physics engine, derives the collision restitution coefficient based on the state information and generates a collision restitution coefficient sequence, and simultaneously reads the initial random seed value of the game through the underlying interface of the random number generator; and composes a physical parameter set based on the collision restitution coefficient sequence and the initial random seed value; M2, a test case generation module, which performs a numerical offset on the collision recovery coefficient according to a preset perturbation rule to generate a perturbation collision recovery coefficient sequence, and simultaneously generates a random event trigger sequence based on the initial random seed value; Composing a test case set based on the disturbance collision recovery coefficient sequence and the random event trigger sequence; M3, a physical logic error detection module, inputs the physical parameter set into the game engine to execute the original scene operation, and simultaneously inputs the test case set into the game engine to execute the test scene operation, and uses a timing collector to record the timing data of the original scene and the test scene when they are executed; compares the timing data differences between the original scene and the test scene to identify physical logic errors; forming a physical logic error set based on the physical logic errors; M4, an optimization feedback module, which extracts the post-disturbance collision recovery coefficient in the disturbance collision recovery coefficient sequence and the event number in the random event trigger sequence based on the physical logic error set; Calculate the collision restitution coefficient correction value and the adjusted initial random seed value, and synchronously feed back and update them to the physical parameter set; generate a new round of the test case set based on the updated physical parameter set to continue executing the M3 and M4 modules, and output the final optimization result after reaching the termination condition.
2. The automated testing and quality assessment system for game development according to claim 1, characterized in that: The state information includes the position of the entity before and after the collision and the time points before and after the collision; Calculating a collision recovery coefficient based on the state information, wherein the calculation process of the collision recovery coefficient includes calculating a collision speed and calculating the collision recovery coefficient based on the collision speed; Based on the i-th collision recovery coefficient e i Construct a collision recovery coefficient sequence E, and E={e1,e2,…,e k }, where k is the length of the collision restitution coefficient sequence; The initial random seed value is recorded as s0, and s0∈[0, 1, 2, 3, ...]; Construct a standard physical parameter set based on the collision restitution coefficient sequence E and the initial random seed value s0 and 3. The automated testing and quality assessment system for game development according to claim 1, characterized in that: The steps of calculating the disturbance collision recovery coefficient sequence include calculating a disturbance offset, calculating a post-disturbance collision recovery coefficient based on the disturbance offset, and generating the disturbance collision recovery coefficient sequence based on the post-disturbance collision recovery coefficient; The disturbance offset Δe i The calculation formula is: Among them, w i is the sensitivity weight of the i-th collision; ∈ i is the uniformly distributed disturbance term; δ is the maximum amplitude of the disturbance; It means uniform distribution on the interval [-δ, δ]; The disturbance offset Δe i Added to the original collision recovery coefficient e i Get the collision recovery coefficient e′ after disturbance i , and e′ i =clip(e i +Δe i , 0, 1); Based on the post-disturbance collision recovery coefficient e′ i The disturbance collision recovery coefficient sequence E′ is obtained, and E′={e′1,e′2,...,e′ l }, where k is the length of the collision recovery coefficient sequence after disturbance; The step of generating the random event trigger sequence comprises: using the initial random seed value to generate a pseudo-random number sequence, performing a modulo operation on the pseudo-random integer in the pseudo-random number sequence to generate an event trigger number, and generating a random event trigger sequence based on the event trigger number; Based on the initial random seed value s0, a pseudo-random number sequence Z of length k is generated by a pseudo-random function f: Z={f(s0,1),f(s0,2),...,f(s0,i),...,f(s0,k)} Where f(s0, i) represents the i-th pseudo-random integer generated with the initial random seed value s0 and index i as input; Perform a modulo operation on the pseudo-random integer in the pseudo-random number sequence Z to generate the event trigger number r i , and r i =f(s0,i)mod M, where M is the total number of event types; mod is the modulo operator; Based on the event trigger number r i The random event trigger sequence R is obtained, and R={r1,r2,...,r k }, where k is the length of the random event trigger sequence; The disturbance collision recovery coefficient sequence E′ and the random event trigger sequence R are combined according to the index to construct a test case set T, and T = {(e′1, r1), (e′2, r2), ..., (e′ l , r k )}.
4. The automated testing and quality assessment system for game development according to claim 1, wherein: The timing data includes a physics engine calculation cycle sequence, an event response timestamp sequence, and a frame rendering interval sequence; The timing collector is an auxiliary monitoring module in the system and is integrated into the running path of the physics engine. The collection methods of the timing collector include function instrumentation collection method, event hook registration collection method and rendering scheduling monitoring collection method; The function instrumentation acquisition method is used to acquire frame-level physics calculation time, and output the physics engine calculation cycle sequence based on the frame-level physics calculation time; The physics engine calculation cycle sequence of the original scene is: Expressed as: The physics engine calculation cycle sequence of the test scenario is: Expressed as: Where n is the total number of frames, The physical calculation time of the i-th frame of the original scene; The physical calculation time of the i-th frame of the test scene; The event hook registration and collection method is used to record the event response timestamp at the event triggering moment, and output the event response timestamp sequence based on the event response timestamp: The event response timestamp sequence of the original scene is τ (ori) , expressed as: The event response timestamp sequence of the test scenario is τ (test) , expressed as: Where m is the number of events; is the trigger timestamp of the jth event in the original scene; is the trigger timestamp of the jth event in the test scenario; The rendering scheduling monitoring acquisition method is used to record the graphics rendering timestamp of each frame, and obtain a rendering timestamp sequence based on the rendering timestamp; The graphics rendering timestamp sequence of the original scene is: Expressed as: The graphics rendering timestamp sequence of the test scene is: Expressed as: Where n is the total number of frames; The timestamp of the graphics rendering of the i-th frame in the original scene; The timestamp of the graphics rendering of the i-th frame in the test scene; Based on the rendering timestamp, calculate the rendering time interval between consecutive frames The calculation formula is: in, and is the rendering timestamp of the i-th frame and the i+1-th frame; *∈{ori,test}, represents the original scene or the test scene; n-1 is the total number of rendering intervals; Based on the rendering time interval Constructing the frame rendering interval sequence; The frame rendering interval sequence of the original scene is Δ (ori) , expressed as: The frame rendering interval sequence of the test scene is Δ (test ), expressed as: in, is the rendering interval of the i-th item in the original scene; Rendering interval for the i-th item in the test scene.
5. The automated testing and quality assessment system for game development according to claim 4, characterized in that: The physics engine calculates the periodic sequence and calculates the periodic average difference D c , the calculation formula is: Where n is the total number of frames; Calculate the average event response delay difference D based on the event response timestamp sequence e , the calculation formula is: Where m is the number of events; Calculate the frame rendering interval standard deviation D based on the frame rendering interval sequence f , the calculation formula is: Among them, n-1 is the number of frames; Based on the period average difference D c , average difference in incident response delay D e and frame rendering interval standard deviation D f Perform physical logic error judgment, the judgment formula is: Among them, θ c ,θ e ,θ f Calculate the average difference D of the period series respectively c , average difference in incident response delay D e and frame rendering interval standard deviation D f Tolerance threshold; D>θ means that a certain difference index exceeds its threshold, that is, there is a physical logic error; Generate a physical logic error set ε based on the physical logic error e , and ε e ={T,i}, indicating that the test case set T has a physical logic error in the i-th frame.
6. The automated testing and quality assessment system for game development according to claim 5, characterized in that: For the physical-logical error set ε e Each error record {T,i} in the corresponding perturbation collision recovery coefficient e is extracted from the perturbation collision recovery coefficient sequence i ' and the event number r in the random event trigger sequence i , then (e i ′, r i ) is the target parameter point to be evaluated and corrected, wherein the disturbance collision recovery coefficient e i ' as the parameter to be modified, and based on the corresponding event number r i Calculating the event frequency deviation for adjusting the initial random seed value; Based on the post-disturbance collision recovery coefficient, a standard collision recovery coefficient ei is obtained from the physical parameter set; based on the random event trigger sequence R={r1, r2, ..., r k }Get the theoretical trigger frequency f of each event type r r ,and Wherein, k is the total number of sampling times, which is equivalent to the common length of the event trigger number sequence, the collision recovery coefficient sequence, and the post-disturbance collision recovery coefficient sequence; According to the number of times event ri appears in the current test round n r Calculate its actual trigger frequency The calculation formula is: Where L is the number of events in all test cases; Based on the post-disturbance collision recovery coefficient e i and the standard collision restitution coefficient e i Obtain the collision recovery coefficient deviation Δe i ′, and Δe i ′=e i -e i '; Based on the theoretical trigger frequency and the actual trigger frequency Event frequency deviation and Based on the collision restitution coefficient deviation Δe i ' and the event frequency deviation The correction conditions are: Among them, δ e and δ f is the preset deviation threshold.
7. The automated testing and quality assessment system for game development according to claim 6, characterized in that: When the correction condition is met, the collision recovery coefficient is corrected, and the initial random seed value is adjusted based on the event frequency deviation; The correction formula of the collision restitution coefficient is: in, is the correction value of the collision recovery coefficient; η e is the learning rate of the collision recovery coefficient, which is used to control the correction amplitude; The adjustment formula of the initial random seed value is: Among them, S new is the initial random seed value after adjustment; s0 is the initial random seed value; η s Update the step size coefficient for the seed; The corrected collision recovery coefficient correction value and the adjusted initial random seed value S new Update the physical parameter set in M1 to obtain the updated physical parameter set Expressed as: Continuing the test process based on the updated physical parameter set, the termination condition is that the number of physical logic errors detected in N consecutive iterations is lower than a preset threshold or the maximum number of iterations is reached; The final optimization result includes the finally optimized collision recovery coefficient, the random event triggering weight and the physical logic error detection report.
Citation Information
Cited By
Entertainment information transmission system and method fusing multi-terminal real-time interactive pushing
CN121334431A
