Game performance parameter obtaining method and device, equipment, medium and product
By recording and copying the virtual object status of the game, it solves the problem of long retest time and inconsistent games after game performance optimization, and improves the efficiency of performance parameter acquisition and optimization verification.
Patent Information
- Application Number
- CN202310337030.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-30
- Publication Date
- 2024-10-01
AI Technical Summary
After the game performance is optimized, it is necessary to organize players to conduct retests multiple times to obtain performance data, resulting in high manpower consumption and low data acquisition efficiency, especially in multi-player games, and the random game settings lead to inconsistent game processes. Unified, it is difficult to effectively verify the optimization effect.
By recording the status information of virtual objects in game matches, generating status files, rendering the same scene in new matches, copying and updating virtual object status, and recording performance parameters, it is possible to obtain performance data without repeating the game.
It saves resource consumption, improves the efficiency and effectiveness of performance parameter acquisition, reduces manpower consumption, realizes the unification of the game process, and simplifies the performance optimization verification process.
Smart Images

Figure CN118718408A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a method, device, electronic device, computer-readable storage medium, and computer program product for obtaining performance parameters in a game. Background Art
[0002] In the related art, after the development of various game resources is completed, multiple people will be organized to run the related games on the terminal, and the performance data of the terminal running the related games will be inspected and accepted, so that if performance problems are found, targeted performance optimization will be carried out. However, after each performance optimization, multiple people need to be reorganized to retest, so as to obtain performance data again, and evaluate the optimized performance based on the re-obtained performance data. In this way, when a large number of players need to participate in the game, it will be very manpower-consuming, resulting in low efficiency in obtaining performance data. At the same time, since many games have random game settings at the beginning, the game process in multiple games is not uniform, which will further reduce the efficiency of obtaining performance data. Summary of the invention
[0003] The embodiments of the present application provide a method, device, electronic device, computer-readable storage medium, and computer program product for obtaining performance parameters in a game, which can improve the efficiency of obtaining performance parameters in a game.
[0004] The technical solution of the embodiment of the present application is implemented as follows:
[0005] The present application provides a method for obtaining performance parameters in a game, the method comprising:
[0006] receiving a start instruction for a second game match of a target game, and acquiring a status file of a first game match of the target game in response to the start instruction;
[0007] The state file records, at each time point in the first game match, state information of each virtual object in the target game, the scene of the second game match is the same as that of the first game match, and the value of at least one performance parameter of the target game in the second game match is different from that in the first game match;
[0008] Rendering the scene of the second game match based on the state file, and creating a virtual object corresponding to the starting time point of the first game match in the scene of the second game match as the virtual object corresponding to the starting time point of the second game match;
[0009] Based on the state information of the virtual object at each time point of the first game match and the created virtual object, sequentially updating the state of the virtual object at each time point in the time point sequence of the second game match;
[0010] In the process of updating the state of the virtual object in the second game match, the values of each performance parameter of the target game are recorded.
[0011] The present application provides a device for obtaining performance parameters in a game, the device comprising:
[0012] an acquisition module, configured to receive a start instruction for a second game match of a target game, and in response to the start instruction, acquire a state file of a first game match of the target game; wherein the state file records, at each time point of the first game match, state information of each virtual object in the target game, the scene of the second game match is the same as that of the first game match, and the value of at least one performance parameter of the target game in the second game match is different from that of the first game match;
[0013] a rendering module, configured to render the scene of the second game match based on the state file, and create a virtual object corresponding to the starting time point of the first game match in the scene of the second game match as the virtual object corresponding to the starting time point of the second game match;
[0014] An updating module, configured to sequentially update the state of the virtual object at each time point in the time point sequence of the second game game based on the state information of the virtual object at each time point of the first game game and the created virtual object;
[0015] The recording module is used to record the values of various performance parameters of the target game during the process of updating the state of the virtual object in the second game match.
[0016] An embodiment of the present application provides an electronic device, including:
[0017] A memory for storing executable instructions;
[0018] The processor is used to implement the method for obtaining performance parameters in the game provided in the embodiment of the present application when executing the executable instructions stored in the memory.
[0019] An embodiment of the present application provides a computer-readable storage medium, in which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, the processor will execute the method for obtaining performance parameters in the game provided in the embodiment of the present application.
[0020] The embodiment of the present application provides a computer program product, which includes a computer program or a computer executable instruction, and the computer program or the computer executable instruction is stored in a computer-readable storage medium. The processor of the electronic device reads the computer executable instruction from the computer-readable storage medium, and the processor executes the computer executable instruction, so that the electronic device executes the method for obtaining performance parameters in the game provided in the embodiment of the present application.
[0021] The embodiments of the present application have the following beneficial effects:
[0022] When the second game match of the target game starts, a state file for recording the state information of each virtual object at each time point in the first game match is obtained, and then the scene of the second game match is rendered based on the state file, and in the scene of the second game match, a virtual object corresponding to the starting time point of the first game match is created as the virtual object corresponding to the starting time point of the second game match, thereby based on the state information of the virtual objects at each time point of the first game match and the created virtual objects, the states of the virtual objects at each time point in the time point sequence of the second game match are sequentially updated, and in the process of updating the states of the virtual objects in the second game match, the values of the performance parameters of the target game are recorded. In this way, by recording the state file of the virtual object in the previous game, the same game scene as in the previous game is rendered in the new game, and the game process of the previous game is copied and replayed in the new game, so as to record the values of various performance parameters in the new game process. In this way, there is no need to organize players to repeat the game many times, which saves resource consumption and improves the efficiency of obtaining performance parameters. At the same time, it ensures the uniformity of the game process in different game games, which not only improves the efficiency of obtaining performance parameters, but also improves the effectiveness of the obtained performance parameters. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] Figure 1 1 is a schematic diagram of the architecture of a system 100 for acquiring performance parameters in a game provided in an embodiment of the present application;
[0024] Figure 2 is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application;
[0025] Figure 3 It is a flowchart of a method for obtaining performance parameters in a game provided in an embodiment of the present application;
[0026] Figure 4 is a schematic diagram of a process in which a server according to an embodiment of the present application generates a state file for a first game match of a target game;
[0027] Figure 5is a schematic diagram of the values of various performance parameters of different game matches of the target game provided by an embodiment of the present application;
[0028] Figure 6 It is a flowchart of a method for obtaining performance parameters in a game provided in an embodiment of the present application;
[0029] Figure 7 It is a schematic diagram of the process of game performance test optimization in the related art;
[0030] Figure 8 is a schematic diagram of a recording file provided in an embodiment of the present application;
[0031] Fig. 9 It is a schematic diagram of the process of starting the recording phase provided in an embodiment of the present application;
[0032] Fig.10 is a schematic diagram of recorded global status information provided by an embodiment of the present application;
[0033] Fig.11 It is a schematic diagram of the process of ending recording and generating a recording file provided in an embodiment of the present application;
[0034] Fig.12 This is a schematic diagram of the process of a client playing back a recorded file provided in an embodiment of the present application;
[0035] Fig.13 It is a schematic diagram of the process of starting the playback phase provided in an embodiment of the present application;
[0036] Fig.14 It is a schematic diagram of the process of skipping the broadcasting according to the time point provided by the embodiment of the present application;
[0037] Fig.15 It is a schematic diagram of the process of playing back global state information provided by an embodiment of the present application;
[0038] Fig.16 It is a process diagram of the stage of ending playback provided in an embodiment of the present application. DETAILED DESCRIPTION
[0039] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of this application.
[0040] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0041] In the following description, the terms "first\second\third" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second\third" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0042] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
[0043] Before further describing the embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application are explained. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations.
[0044] 1) Client, also known as the user end, refers to the program corresponding to the server that provides local services to users. Except for some applications that can only run locally, it is generally installed on an ordinary client and needs to cooperate with the server to run, that is, it requires corresponding servers and service programs in the network to provide corresponding services. In this way, specific communication connections need to be established on the client and server sides to ensure the normal operation of the application.
[0045] 2) In response, it is used to indicate the conditions or states on which the executed operations depend. When the dependent conditions or states are met, one or more operations executed may be in real time or have a set delay. Unless otherwise specified, there is no restriction on the order of execution of the multiple operations executed.
[0046] 3) Performance acceptance refers to the process of accepting various performance indicators of the system by simulating various normal, peak and abnormal load conditions through test tools.
[0047] 4) Frames Per Second (FPS) is a definition in the field of imaging. It refers to the number of frames transmitted per second. Generally speaking, it refers to the number of frames of animation or video within one second. It is a measure of the amount of information used to save and display dynamic videos. The more frames per second, the smoother the displayed action will be.
[0048] 5) Central Processing Unit (CPU) is the CPU usage occupied by running programs, which indicates the status of running programs on the machine at a certain point in time.
[0049] See also Figure 1 , Figure 1 1 is a schematic diagram of the architecture of a system 100 for acquiring performance parameters in a game provided by an embodiment of the present application. To realize an application scenario of acquiring performance parameters in a game (for example, an application scenario of acquiring performance parameters in a game may be that after optimizing the performance based on the performance parameters acquired in a first game match, when retesting the optimized performance based on a second game match, a state file for recording the state information of each virtual object at each time point in the first game match is acquired, and then based on the state file, a game scene identical to that in the first game match is rendered in the second game match, and the game process of the first game match is copied and replayed in the second game match, thereby recording the values of each performance parameter in the second game match), a terminal (terminal 400 is shown as an example) is connected to server 200 via network 300, network 300 may be a wide area network or a local area network, or a combination of the two, terminal 400 is used for users to use client 401, and display on a display interface (display interface 401-1 is shown as an example), and terminal 400 and server 200 are connected to each other via a wired or wireless network.
[0050] The terminal 400 is used to send a request for obtaining a status file of a first game match of a target game to the server 200;
[0051] The server 200 is used to receive a request for obtaining a status file of a first game match of a target game sent by the terminal 400, and send the status file of the first game match of the target game to the terminal 400 in response to the request;
[0052] The terminal 400 is used to receive a state file for a first game match of a target game and store the state file; receive a start instruction for a second game match of the target game, and in response to the start instruction, obtain a state file for the first game match of the target game; wherein the state file records, at each time point of the first game match, state information of each virtual object in the target game, the scene of the second game match is the same as the first game match, and the value of at least one performance parameter of the target game in the second game match is different from that of the first game match; based on the state file, render the scene of the second game match, and create a virtual object corresponding to the starting time point of the first game match in the scene of the second game match as the virtual object corresponding to the starting time point of the second game match; based on the state information of the virtual object at each time point of the first game match and the created virtual object, sequentially update the state of the virtual object at each time point in the time point sequence of the second game match; in the process of updating the state of the virtual object in the second game match, record the value of each performance parameter of the target game.
[0053] In some embodiments, the server 200 may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content distribution networks (CDN, Content Deliver Network), and big data and artificial intelligence platforms. The terminal 400 may be a smart phone, a tablet computer, a laptop computer, a desktop computer, a set-top box, an intelligent voice interaction device, a smart home appliance, a vehicle-mounted terminal, an aircraft, and a mobile device (e.g., a mobile phone, a portable music player, a personal digital assistant, a dedicated messaging device, a portable gaming device, an intelligent speaker, and a smart watch), etc., but is not limited thereto. The terminal device and the server may be directly or indirectly connected via wired or wireless communication, which is not limited in the embodiments of the present application.
[0054] See also Figure 2 , Figure 2 is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. In practical applications, the electronic device can be Figure 1 The server 200 or the terminal 400 shown in FIG. 4 is a terminal. Figure 2 , Figure 2The electronic device shown includes: at least one processor 410, a memory 450, at least one network interface 420 and a user interface 430. The various components in the terminal 400 are coupled together via a bus system 440. It is understood that the bus system 440 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 440 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, the bus system 440 is not shown in FIG. Figure 2 Various buses are labeled as bus system 440 .
[0055] Processor 410 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc., where the general-purpose processor can be a microprocessor or any conventional processor, etc.
[0056] The user interface 430 includes one or more output devices 431 that enable presentation of media content, including one or more speakers and / or one or more visual display screens. The user interface 430 also includes one or more input devices 432, including user interface components that facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.
[0057] The memory 450 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state memory, hard disk drives, optical disk drives, etc. The memory 450 may optionally include one or more storage devices that are physically remote from the processor 410.
[0058] The memory 450 includes a volatile memory or a non-volatile memory, and may also include both volatile and non-volatile memories. The non-volatile memory may be a read-only memory (ROM), and the volatile memory may be a random access memory (RAM). The memory 450 described in the embodiments of the present application is intended to include any suitable type of memory.
[0059] In some embodiments, memory 450 can store data to support various operations, examples of which include programs, modules, and data structures, or a subset or superset thereof, as exemplarily described below.
[0060] Operating system 451, including system programs for processing various basic system services and performing hardware-related tasks, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks;
[0061] A network communication module 452, used to reach other electronic devices via one or more (wired or wireless) network interfaces 420, exemplary network interfaces 420 include: Bluetooth, Wireless Compatibility Certification (WiFi), and Universal Serial Bus (USB), etc.;
[0062] a presentation module 453 for enabling presentation of information via one or more output devices 431 (e.g., display screen, speaker, etc.) associated with the user interface 430 (e.g., a user interface for operating peripherals and displaying content and information);
[0063] The input processing module 454 is used to detect one or more user inputs or interactions from one of the one or more input devices 432 and translate the detected inputs or interactions.
[0064] In some embodiments, the device provided in the embodiments of the present application can be implemented in software. Figure 2 The device 455 for acquiring performance parameters in the game stored in the memory 450 is shown, which can be software in the form of a program or a plug-in, and includes the following software modules: an acquisition module 4551, a rendering module 4552, an update module 4553, and a recording module 4554. These modules are logical, and thus can be arbitrarily combined or further split according to the functions implemented. The functions of each module will be described below.
[0065] In other embodiments, the device provided in the embodiments of the present application can be implemented in hardware. As an example, the device for obtaining performance parameters in the game provided in the embodiments of the present application can be a processor in the form of a hardware decoding processor, which is programmed to execute the method for obtaining performance parameters in the game provided in the embodiments of the present application. For example, the processor in the form of a hardware decoding processor can adopt one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field programmable gate arrays (FPGAs), or other electronic components.
[0066] In some embodiments, the terminal or server can implement the method for obtaining performance parameters in the game provided by the embodiments of the present application by running a computer program. For example, the computer program can be a native program or software module in the operating system; it can be a native application (APP, Application), that is, a program that needs to be installed in the operating system to run, such as an instant messaging APP, a web browser APP; it can also be a small program, that is, a program that can be run only by downloading it to a browser environment; it can also be a small program that can be embedded in any APP. In short, the above-mentioned computer program can be an application, module or plug-in in any form.
[0067] Based on the above description of the system and electronic device for obtaining performance parameters in a game provided by the embodiment of the present application, the following describes the method for obtaining performance parameters in a game provided by the embodiment of the present application. In actual implementation, the method for obtaining performance parameters in a game provided by the embodiment of the present application can be implemented by a terminal or a server alone, or by a terminal and a server in collaboration, so that Figure 1 The method for obtaining performance parameters in a game provided by an embodiment of the present application is described by taking the terminal 400 alone as an example. Figure 3 , Figure 3 is a flow chart of a method for obtaining performance parameters in a game provided by an embodiment of the present application. Figure 3 The steps shown are explained.
[0068] Step 101, the terminal receives a start instruction for a second game match of a target game, and in response to the start instruction, obtains a status file of a first game match of the target game; wherein the status file records, at each time point of the first game match, status information of each virtual object in the target game, the scene of the second game match is the same as that of the first game match, and the value of at least one performance parameter of the target game in the second game match is different from that of the first game match.
[0069] In actual implementation, an application corresponding to the target game is installed on the terminal. The application can be any one of a multiplayer online role-playing game, a first-person shooter game, a third-person shooter game, a multiplayer online tactical competitive game, a virtual reality application, a three-dimensional map program, or a multiplayer gunfight survival game. The user can use the terminal to play a game in the application. When the user opens the application on the terminal and the terminal runs the application, the terminal presents a virtual page of the target game. Here, the virtual page of the target game can be a game preparation interface in the game, and then based on the virtual page of the target game, a start instruction for the second game of the target game is received, and in response to the start instruction, the state file of the first game of the target game is obtained.
[0070] It should be noted that each time point indicated in the state file corresponds to each game screen scene, i.e., a game screen frame, in the first game match; at the same time, the state file here may be pre-stored locally in the terminal. Specifically, after the server completes recording the state information of the virtual object at each time point of the first game match of the target game, the server generates a state file for the first game match of the target game, and then sends the state file to the terminal, so that the terminal stores the state file, and then, when receiving the start instruction of the second game match of the target game, the terminal directly obtains the state file of the first game match of the target game from the local storage space in response to the start instruction. Alternatively, the state file may be pre-stored in the server. Specifically, after the server completes recording the state information of the virtual object at each time point of the first game match of the target game, the server generates a state file for the first game match of the target game, and then stores the state file. When the terminal receives the start instruction of the second game match of the target game, the terminal sends a request to obtain the state file of the first game match of the target game to the server, so that the server responds to the acquisition request and sends the state file of the first game match of the target game to the terminal, so that the terminal obtains the state file. In addition, the value of the performance parameter of the target game in the second game match or the first game match may be a CPU usage rate, an FPS average, or the like.
[0071] In actual implementation, for the process in which the server records the state information of the virtual object at each time point of the first game match of the target game and generates the state file of the first game match of the target game, see Figure 4 , Figure 4 is a schematic diagram of a process in which a server generates a state file for a first game match of a target game according to an embodiment of the present application, based on Figure 4, the process of the server generating a status file for the first game match of the target game includes four stages. Specifically, in the stage of starting recording, the server first establishes a connection with the terminal of the first game match running the target game, and then starts a corresponding recording thread for each virtual object in the first game match, so that in the process of recording global state information, the state information of each virtual object is recorded in a parallel processing manner; in the process of recording global state information, according to the recording thread started for each virtual object in the first game match, the first recording information, the second recording information and the third recording information for the first game match are recorded, wherein the first recording information at least includes each virtual object, each scene element and one of the state information corresponding to each virtual object and the state information of each scene element in each frame of the game scene image of the first game match, and the second recording information at least includes each virtual object within the target time period of the first game match, such as five minutes or ten minutes. , status information of each scene element and the corresponding virtual object, one of the status information of each scene element, the third record information at least includes attribute information of the status information of each virtual object and one of the scene elements, the attribute information here is used to indicate whether the status information of the corresponding virtual object or scene element is associated with the user's operation instruction, that is, whether it is generated based on the user's operation instruction. When it is related to the user's operation instruction, it represents that the corresponding status information is generated based on the user's operation instruction. When it is not related to the user's operation instruction, it represents that the corresponding status information is generated based on the system's preset instructions; in the process of ending the recording, the recording of the first game game is stopped, and then in the process of generating the status file, the first record information, the second record information and the third record information are serialized to obtain the serialization result, and then the serialization result is compressed to obtain the status file of the first game game for the target game.
[0072] In actual implementation, for the process of receiving the start instruction of the second game match for the target game based on the virtual page of the target game, before receiving the start instruction of the second game match for the target game, it is also possible to display the start control for the second game match in the virtual page of the target game; and then display the name of the input status file in response to the input operation triggered by the start control; thereby, the process of receiving the start instruction for the second game match for the target game can be, in response to the confirmation operation on the name of the input status file, receiving the start instruction for the second game match for the target game.
[0073] It should be noted that the confirmation operation for the name of the input status file here may be a triggering operation of a confirmation control for the name of the input status file. Specifically, a confirmation control for the name of the input status file will also be displayed in the virtual page of the target game. Thus, in response to the confirmation operation for the name of the input status file, the process of receiving the start instruction of the second game match for the target game may be receiving the start instruction of the second game match for the target game in response to the triggering operation of the confirmation control.
[0074] In some embodiments, the opening control may be an input field, and the process of displaying the name of the input state file in response to an input operation on the opening control may be to display the name of the input state file in response to an input operation on the input field.
[0075] It should be noted that the name of the status file can be set by the server when generating the status file, or it can be set by the terminal when storing the status file locally, and this embodiment of the present application does not limit this.
[0076] Step 102, based on the state file, render the scene of the second game game, and in the scene of the second game game, create a virtual object corresponding to the starting time point of the first game game as the virtual object corresponding to the starting time point of the second game game.
[0077] In actual implementation, before rendering the scene of the second game game based on the state file, the state file will also be verified. Specifically, after obtaining the state file of the first game game of the target game, the state file can also be parsed to obtain file header information of the state file, where the file header information includes version information of the state file; based on the file header information, the version information of the state file is verified to obtain a verification result; thus, the process of rendering the scene of the second game game based on the state file specifically includes, when the verification result indicates that the version information of the state file has passed the verification, rendering the scene of the second game game based on the state file.
[0078] It should be noted that, since most target games will perform resource updates, there are multiple versions of the target games. At the same time, for different versions of target games, there are status files corresponding to different versions when performing performance optimization. Based on this, the version information of the status file is verified based on the file header information to obtain the verification result. That is, the game version of the current target game is obtained, and the game version of the current target game is compared with the version information of the status file included in the file header information. When the comparison result indicates that the game version of the current target game is consistent with the version information of the status file included in the file header information, a verification result indicating that the version information of the status file has passed the verification is obtained; when the comparison result indicates that the game version of the current target game is inconsistent with the version information of the status file included in the file header information, a verification result indicating that the version information of the status file has not passed the verification is obtained. At this time, it means that the obtained status file is not the same version as the current target game.
[0079] In actual implementation, the state file also includes scene information of each time point of the first game game scene. Therefore, the process of rendering the second game game scene based on the state file specifically includes parsing the state file to obtain the scene information of each time point of the first game game corresponding to the state file; and rendering the second game game scene based on the scene information of each time point of the first game game.
[0080] It should be noted that the scene information here is used to indicate the game scene screen at each time point in the first game game. The process of rendering the scene of the second game game based on the scene information at each time point of the first game game can be, during the second game game, based on the scene information at each time point of the first game game, real-time rendering of the game scene screen at the corresponding time point in the second game game. Exemplarily, when the second game game reaches the 300th second, the game scene screen at the 300th second of the first game game is rendered in real time.
[0081] In actual implementation, when rendering the scene of the second game game based on the state file, virtual objects participating in the second game game can also be created based on the state file. Specifically, starting from the starting time point of the second game game, a virtual object corresponding to the starting time point of the first game game is created in the scene of the second game game as the virtual object corresponding to the starting time point of the second game game. The process can be to obtain object information of each time point of the first game game recorded in the state file, and determine the virtual object corresponding to the starting time point of the first game game from the object information of each time point; based on the determined virtual object, a virtual object identical to the determined virtual object is created in the scene of the second game game as the virtual object corresponding to the starting time point of the second game game.
[0082] It should be noted that by obtaining the object information at each time point of the first game game recorded in the status file, the object information is parsed to obtain the virtual object participating in the first game game, and then based on the determined virtual object, in the scene of the second game game, a virtual object identical to the determined virtual object is created as the virtual object participating in the second game game.
[0083] Step 103, based on the state information of the virtual objects at each time point of the first game match and the created virtual objects, the state of the virtual objects at each time point in the time point sequence of the second game match is sequentially updated.
[0084] In actual implementation, after rendering the scene of the second game game and creating the virtual object corresponding to the starting time point of the second game game, that is, in the scene at each time point in the second game game, based on the state information of the virtual object at the corresponding time point of the first game game in the state file, the same state can be set for the virtual object created in the scene. Specifically, for the state information of the virtual object at each time point of the first game game and the virtual object created, the state of the virtual object at each time point in the time point sequence of the second game game is sequentially updated. This process can be based on the virtual object at each time point of the first game game. The state information of the virtual object at each time point in the time point sequence of the first game game is obtained, starting from the starting time point of the first game game; when the obtained state information is the state information of the virtual object at the starting time point of the first game game, the state of the virtual object at the starting time point of the first game game is determined as the state of the virtual object at the starting time point of the second game game; when the obtained state information is not the state information of the virtual object at the starting time point of the first game game, the state of the virtual object at the previous time point in the second game game is updated based on the state information of the virtual object at this time point of the first game game.
[0085] Exemplarily, when the acquired state information is the state information of the virtual object at the start time point of the first game match, and the state information is used to indicate that the virtual object at the start time point of the first game match is in a standing state, the state of the virtual object at the start time point of the second game match is determined to be a standing state; when the acquired state information is the state information of the virtual object at a time point after the start time point of the first game match, and the state information is used to indicate that the virtual object at a time point after the start time point of the first game match is in a prone state, the standing state of the virtual object at the previous time point, i.e., the start time point, in the second game match is updated, i.e., the state of the virtual object at that time point in the second game match is updated from a standing state to a prone state. In this way, based on the state information of the virtual object at each time point of the first game match and the created virtual object, the state of the virtual object at each time point in the time point sequence of the second game match is sequentially updated, ensuring that the state of the virtual object at each time point in the first game match is the same as the state of the virtual object at the corresponding time point in the second game match, i.e., ensuring that the game process of the first game match is the same as the game process of the second game match.
[0086] Step 104, in the process of updating the state of the virtual object in the second game match, the values of various performance parameters of the target game are recorded.
[0087] In actual implementation, in the process of updating the state of the virtual object in the second game, the values of the performance parameters of the target game are recorded, that is, the performance of the terminal running the target game during the second game is recorded. Figure 5 , Figure 5 is a schematic diagram of the values of various performance parameters of different game matches of the target game provided by the embodiment of the present application, based on Figure 5, model is used to indicate the model of the terminal, version is used to indicate the version of the configuration parameters corresponding to the current terminal, image quality frame rate is used to indicate the frame rate of the configuration parameters corresponding to the corresponding version, and scene is used to indicate the game being played. After the terminal has finished running the first game of the target game, the tester adjusts the configuration parameters of the terminal based on the performance of the terminal recorded during the first game. For example, based on the performance of the terminal recorded during the first game, the tester finds that the game screen presented during the game is stuck or the CPU is slow due to the high configuration parameters of the terminal, such as the current frame rate of 50 frames. When the utilization rate, that is, the load, is too large, therefore, the current frame rate of the terminal is reduced, for example, to 30 frames, and then based on the current configuration parameters of the terminal, that is, the frame rate of 30 frames, and based on the status file of the first game game, a second game is performed, so that in the process of updating the state of the virtual object in the second game game, the values of various performance parameters of the target game are recorded, that is, the performance parameters of the terminal after the configuration parameters are adjusted when running the same game process, so as to determine the smoothness of the game screen or the CPU load presented during the game game, so as to determine whether the problem of game screen freeze or excessive CPU load is solved.
[0088] In some embodiments, in the process of updating the state of the virtual object in the second game match, after recording the values of each performance parameter of the target game, a performance file can also be generated based on the recorded values of each performance parameter of the target game; wherein the performance file is used to indicate the performance of the terminal of the second game match running the target game when running the second game match; the performance file is uploaded to the server so that the server stores the performance file. Here, after the performance file is generated, the performance file can also be stored locally in the terminal. In this way, by generating and storing the performance file, the performance files of different games can be compared, thereby facilitating performance optimization.
[0089] In some embodiments, in the process of updating the state of the virtual object in the second game game, after recording the values of each performance parameter of the target game, it is also possible to obtain the values of each performance parameter of the target game in the first game game; compare the values of each performance parameter of the target game in the first game game with the values of each performance parameter of the target game in the second game game to obtain comparison results; based on the comparison results, adjust the configuration parameters of the terminal running the target game when running the target game to obtain target configuration parameters; wherein, the terminal running the first game game is the same as the terminal running the second game game.
[0090] It should be noted that the value of the performance parameter may be the load of the CPU of the terminal, the smoothness of the game screen during the game, etc. Here, in the process of updating the state of the virtual object in the second game match, after recording the values of the performance parameters of the target game, the values of the performance parameters of the terminal in the first game match are compared with the values of the performance parameters in the second game match, and then, based on the comparison result, the configuration parameters of the terminal running the target game when running the target game are adjusted to obtain the target configuration parameters, so that the terminal runs the target game based on the target configuration parameters. Here, the performance of the terminal when running the target game based on the target configuration parameters is better than the performance when running the target game based on the configuration parameters before adjustment. For example, the CPU usage rate when the terminal runs the target game based on the configuration parameters before adjustment is greater than the CPU usage rate when the terminal runs the target game based on the target configuration parameters, or the FPS average when the terminal runs the target game based on the configuration parameters before adjustment is less than the FPS average when the terminal runs the target game based on the target configuration parameters, that is, the screen smoothness when the terminal runs the target game based on the configuration parameters before adjustment is lower than the screen smoothness when the terminal runs the target game based on the target configuration parameters.
[0091] In some embodiments, the game process of the second game game can also be jumped during the second game game. Specifically, in the process of updating the state of the virtual object in the second game game, a jump instruction carrying a jump time point for the second game game is received, and the jump instruction is used to indicate that the update time point of the state is jumped from the current time point to the jump time point; in response to the jump instruction, the state information of each virtual object after the jump time point is selected from the state information of each virtual object at each time point in the first game game recorded in the state file, and a target state file is generated based on the selected state information; thereby, based on the target state file, the scene of the second game game can be rendered starting from the jump time point indicated by the jump instruction.
[0092] It should be noted that after receiving a jump instruction carrying a jump time point for the second game match, the jump instruction is parsed to obtain the jump time point carried by the jump instruction. Here, the jump time point may be before the current time point when the jump instruction is received, or it may be after the current time point, and the embodiment of the present application does not limit this. After obtaining the jump time point carried by the jump instruction, the process of selecting the status information of each virtual object after the jump time point from the status information of each virtual object at each time point in the first game match recorded in the status file may be to filter the status information of each virtual object at each time point in the first game match recorded in the status file based on the jump time point, thereby selecting the status information of each virtual object after the jump time point, and then generating the target status file based on the selected status information.
[0093] In actual implementation, when the game process of the second game game is jumped during the second game game, the state information of the virtual objects at each time point in the first game game and the created virtual objects are used to sequentially update the states of the virtual objects at each time point in the time point sequence of the second game game. The process may be, based on the target state file, obtaining the state information of the virtual objects at each time point after the jump time point; and sequentially updating the states of the virtual objects at each time point in the time point sequence of the second game game after the jump time point based on the state information of the virtual objects at each time point after the jump time point and the created virtual objects.
[0094] In actual implementation, the process of sequentially updating the status of virtual objects at each time point after the jump time point in the time point sequence of the second game game based on the status information of virtual objects at each time point after the jump time point and the created virtual objects may be, starting from the jump time point, sequentially obtaining the status information of virtual objects at each time point in the time point sequence of the first game game; when the acquired status information is the status information of the virtual object at the jump time point of the first game game, determining the status of the virtual object at the jump time point of the first game game as the status of the virtual object at the jump time point of the second game game; when the acquired status information is not the status information of the virtual object at the jump time point of the first game game, updating the status of the virtual object at the previous time point in the second game game based on the status information of the virtual object at that time point of the first game game.
[0095] Exemplarily, when the jump time point is used to indicate the 300th second in the second game match, based on the target state file, the state information of the virtual object at each time point after the 300th second is obtained; when the obtained state information is the state information of the virtual object at the 300th second of the first game match, and the state information is used to indicate that the virtual object at the 300th second of the first game match is in a standing state, the state of the virtual object at the 300th second of the second game match is determined to be a standing state; when the obtained state information is the state information of the virtual object at a time point after the 300th second of the first game match, and the state information is used to indicate that the virtual object at a time point after the 300th second of the first game match is in a prone state, the standing state of the virtual object at the previous time point in the second game match, i.e., the 300th second, is updated, that is, the state of the virtual object at that time point in the second game match is updated from a standing state to a prone state.
[0096] In actual implementation, the target state file also includes scene information at each time point after the jump time point in the first game game; thus, the process of rendering the scene of the second game game based on the target state file, that is, the process of rendering the scene of the second game game based on the target state file, starting from the jump time point indicated by the jump instruction, specifically includes parsing the target state file to obtain the scene information and virtual object information of each time point of the first game game corresponding to the target state file; wherein the scene information includes at least one of a fixed scene element and a temporary scene element, the fixed scene element being a scene element that continuously appears in the scene of the first game game, and the temporary scene element being a scene element that appears before the jump time point. A scene element that appears in the scene of the first game match and does not appear in the scene of the first game match after the jump time point; virtual object information includes at least one of a fixed virtual object and a temporary virtual object, the fixed virtual object is a virtual object that continuously appears in the scene of the first game match, and the temporary virtual object is a virtual object that appears in the scene of the first game match before the jump time point and does not appear in the scene of the first game match after the jump time point; when there is temporary information including at least one of a temporary scene element and a temporary virtual object in the scene information, the temporary information in the scene information is deleted to obtain target scene information; based on the target scene information, the scene of the second game match is rendered.
[0097] It should be noted that the continuously appearing scene elements are used to indicate the scene elements that appear before the jump time point and also appear after the jump time point, and the scene elements that do not appear before the jump time point and appear after the jump time point, and the continuously appearing virtual objects are used to indicate the virtual objects that appear before the jump time point and also appear after the jump time point, and the virtual objects that do not appear before the jump time point and appear after the jump time point. Exemplarily, the fixed scene elements in the scene information can be buildings or landscapes in the scene of the first game match, and the temporary scene elements can be elements that appear at the beginning of the first game match, such as airplanes; and the virtual object information includes fixed virtual objects that can be virtual objects controlled by the user, or interactive objects that appear in the scene after the jump time point for the user to perform interactive operations, such as NPCs, and the temporary virtual objects can be interactive objects that appear in the scene before the jump time point for the user to perform interactive operations.
[0098] In actual implementation, during the process of updating the state of the virtual object in the second game match, a jump instruction carrying a jump time point for the second game match is received. Before receiving the jump instruction carrying the jump time point for the second game match, a time point setting control for setting the jump time point may be displayed in the virtual page of the target game. Thus, the process of receiving the jump instruction carrying the jump time point for the second game match may be, in response to a setting operation triggered by the time point setting control, displaying the set jump time point. In response to a confirmation operation for the set jump time point, a jump instruction carrying the jump time point for the second game match is received.
[0099] It should be noted that the confirmation operation for the set jump time point here may be a trigger operation for the confirmation control for the set jump time point. Specifically, a confirmation control for the set jump time point will also be displayed in the virtual page of the target game. Thus, in response to the confirmation operation for the set jump time point, a process of receiving a jump instruction for the second game game carrying the jump time point may be, in response to the trigger operation for the confirmation control, receiving a jump instruction for the second game game carrying the jump time point.
[0100] It should be noted that the time point setting control can be a time point input bar or a time point adjustment roller, etc. When the time point setting control is a time point input bar, the setting operation triggered by the time point setting control can be an input operation of the user on the time input box presented by the terminal, and when the time point setting control is a time point adjustment roller, the setting operation triggered by the time point setting control can be a sliding operation of the user on the time point adjustment roller presented by the terminal. The embodiment of the present application does not limit the style of the time point setting control and the setting operation triggered by the time point setting control.
[0101] In some embodiments, the game process of the second game can also be jumped when the second game starts. Specifically, the start instruction carries the jump time point, so that the process of obtaining the state file of the first game of the target game in response to the start instruction can be, in response to the start instruction, obtaining the target state file of the first game of the target game after the jump time point; thus, the process of rendering the scene of the second game based on the state file can be, based on the target state file, rendering the scene of the second game. Here, the process of obtaining the target state file of the first game of the target game after the jump time point can be, from the state information of each virtual object at each time point in the first game recorded in the state file, selecting the state information of each virtual object after the jump time point, and generating the target state file based on the selected state information, and the process of rendering the scene of the second game based on the target state file is similar to the process of rendering the scene of the second game based on the target state file when the game process of the second game is jumped during the second game, and this embodiment of the application will not be repeated.
[0102] In actual implementation, when the second game game starts and the game process of the second game game is jumped, the scene of the second game game is rendered based on the state file, and a virtual object corresponding to the starting time point of the first game game is created in the scene of the second game game as the virtual object corresponding to the starting time point of the second game game. The process may be to render the scene of the second game game based on the target state file, and create a virtual object corresponding to the jump time point of the first game game in the scene of the second game game as the virtual object corresponding to the jump time point of the second game game.
[0103] It should be noted that, when the second game game starts and the game process of the second game game is jumped, the state information of the virtual objects based on each time point of the first game game and the created virtual objects, and the state of the virtual objects at each time point in the time point sequence of the second game game are sequentially updated. This is similar to the process in the previous article where when the game process of the second game game is jumped during the second game game, the state information of the virtual objects based on each time point of the first game game and the created virtual objects, and the state of the virtual objects at each time point in the time point sequence of the second game game are sequentially updated. This will not be elaborated in the embodiments of the present application.
[0104] Next, the method for obtaining performance parameters in the game provided by the embodiment of the present application is further introduced. Figure 6 , Figure 6 It is a flow chart of the method for obtaining performance parameters in the game provided in the embodiment of the present application. Here, the method for obtaining performance parameters in the game provided in the embodiment of the present application is implemented collaboratively by the terminal and the server.
[0105] Step 201: When a first game match of a target game is started, the client receives a trigger operation for a recording control for recording state information of each virtual object in the first game match of the target game.
[0106] In actual implementation, the client may be a client that supports in-game performance parameters and is located on a terminal, that is, an application corresponding to the target game. The recording control may be presented based on the human-computer interaction interface of the client at the start of the first game match of the target game. The triggering operation of the recording control may be a click operation performed by the user on the human-computer interaction interface of the client on the recording control.
[0107] Step 202, in response to a trigger operation on a record control, sending a record request for state information of each virtual object in a first game match of a target game to a server.
[0108] Step 203, in response to the received request to record the status information of each virtual object in the first game match of the target game, the server records the status information of each virtual object at each time point in the first game match during the progress of the first game match.
[0109] Step 204: When the first game is finished, a state file for the first game is generated based on the recorded state information of each virtual object at each time point in the first game.
[0110] Step 205: The server sends the status file to the client.
[0111] Step 206: The client stores the received state file and receives a start instruction for the second game match of the target game that carries a jump time point.
[0112] It should be noted that during the first game, the performance of the terminal, that is, the configuration parameters, will be adjusted, so that after the adjustment, based on the terminal with the adjusted performance, the second game with the same game process as the first game can be replayed.
[0113] In actual implementation, before receiving the start instruction carrying the jump time point for the second game match of the target game, the start control for the second game match, the time point setting control for setting the jump time point, and the confirmation control for confirming the second game match and the set jump time point are displayed in the virtual page of the target game, so that in response to the input operation triggered by the start control, the name of the input status file is displayed, and in response to the setting operation triggered by the time point setting control, the set jump time point is displayed; and then in response to the trigger operation of the confirmation control, the jump instruction carrying the jump time point for the second game match is received.
[0114] Step 207, in response to the start instruction, obtain the state file of the first game match of the target game, and determine the target state file based on the jump time point and the state file.
[0115] In actual implementation, after obtaining the status file of the first game match of the target game, the status information of each virtual object after the jump time point is selected from the status information of each virtual object at each time point in the first game match recorded in the status file, and the target status file is generated based on the selected status information.
[0116] Step 208, based on the target state file, render the scene of the second game game, and in the scene of the second game game, create a virtual object corresponding to the jump time point of the first game game as the virtual object corresponding to the jump time point of the second game game.
[0117] Step 209 : based on the target state file, obtaining the state information of the virtual object at each time point after the jump time point.
[0118] Step 210, based on the state information of the virtual objects at each time point after the jump time point and the created virtual objects, the states of the virtual objects at each time point after the jump time point in the time point sequence of the second game game are sequentially updated.
[0119] Step 211, in the process of updating the state of the virtual object in the second game match, the values of various performance parameters of the target game are recorded.
[0120] In actual implementation, while recording the values of the performance parameters of the target game, the values of the performance parameters of the target game will also be displayed in the human-computer interaction interface of the client, and the values of the performance parameters of the target game can also be sent to other devices connected to the terminal communication. In this way, by displaying the values of the performance parameters of the target game, the tester can determine the performance of the terminal running the second game match, and then compare the values of the performance parameters of the terminal in the first game match with the values of the performance parameters in the second game match, so as to adjust the configuration parameters of the terminal running the target game based on the comparison results when running the target game, and obtain the target configuration parameters, so that the terminal runs the target game based on the target configuration parameters.
[0121] Step 212, generating a performance file based on the recorded values of each performance parameter of the target game.
[0122] Step 213, sending the performance file to the server.
[0123] Step 214: The server receives the performance file and stores the performance file.
[0124] By applying the above-mentioned embodiment of the present application, when the second game match of the target game starts, a status file for recording the status information of each virtual object at each time point in the first game match is obtained, and then based on the status file, the scene of the second game match is rendered, and in the scene of the second game match, a virtual object corresponding to the starting time point of the first game match is created as the virtual object corresponding to the starting time point of the second game match, thereby based on the status information of the virtual object at each time point of the first game match and the created virtual object, the status of the virtual object at each time point in the time point sequence of the second game match is sequentially updated, and in the process of updating the status of the virtual object in the second game match, the value of each performance parameter of the target game is recorded. In this way, by recording the state file of the virtual object in the previous game, the same game scene as in the previous game is rendered in the new game, and the game process of the previous game is copied and replayed in the new game, so as to record the values of various performance parameters in the new game process. In this way, there is no need to organize players to repeat the game many times, which saves resource consumption and improves the efficiency of obtaining performance parameters. At the same time, it ensures the uniformity of the game process in different game games, which not only improves the efficiency of obtaining performance parameters, but also improves the effectiveness of the obtained performance parameters.
[0125] The following is an explanation of an exemplary application of the embodiments of the present application in a practical application scenario.
[0126] The inventor discovered that after the development of various game resources is completed, multiple people will be organized to conduct extreme battles with various gear models to simulate the multiplayer extreme operations of players as much as possible. Figure 7 , Figure 7 This is a schematic diagram of the process of game performance test optimization in related technologies, based on Figure 7 During the game, performance data will be collected. If performance problems are found, targeted optimization will be carried out. After the optimization is completed, relevant personnel will be organized to conduct simulation tests and acceptance of extreme scenarios until the multiplayer gameplay can meet the performance standards. However, after each performance optimization, multiple people need to be organized for retesting. For some scenarios where a large number of players need to participate in the game, such as a 100-player team battle, it will take 1 day to organize 100 people for extreme stress testing each time, which will be very labor-intensive. In addition, many games will have random game settings at the beginning, such as routes in the game, item drop settings, etc. This will make it impossible to conduct effective comparisons between multiple tests, and it is difficult to verify whether the optimization is effective.
[0127] Based on this, the embodiment of the present application provides a performance acceptance technology based on a jumpable recording and playback system, which can record the status information of all players in the entire game process, thereby obtaining a recording file (status file) containing various network synchronization objects and the status information of each player client, so that multi-person extreme stress testing only needs to be organized once, and when retesting after optimization, the recording file can be directly used to play back on the corresponding client. In this way, a single machine can achieve multi-person extreme stress testing, which is very time-saving and labor-saving. At the same time, due to the stability and consistency of the playback, it allows R&D personnel to efficiently complete the optimization iteration of the target model; and the playback process can also be jumped, allowing R&D personnel to play back the specified time in the recording file, without having to play back from the beginning of the recording file every time, so as to further focus on problem optimization and improve the efficiency of the optimization process.
[0128] Next, the technical solution of this application is described from the product side. Figure 8 , Figure 8 is a schematic diagram of a recording file provided in an embodiment of the present application, based on Figure 8 The server responds to the recording instruction triggered by the user based on the client (the trigger operation for the recording control), starts recording the game, and then generates the following Figure 8The replay recording file shown; when the game recording is completed, in response to the end instruction triggered by the user based on the client, the entire recording file is recorded, and finally the XX.replay file, i.e., the recording file (state file), is formed in the folder for caching the recording file on the server. Here, the server can also send the recording file to the terminal so that the terminal stores the recording file locally. When the game is played again (the second game of the target game is played), the control for starting the recording file, such as the input bar, is displayed on the game startup interface, so that in response to the input operation for the input bar, the name of the input recording file and the jump time point are displayed, and then the playback of the recording file is started, and it will jump to the jump time point to start, so as to perform jump playback. Here, when the recording file is played back, it can be seen that all kinds of operations and various enemy encounter scenes in the previous game process can be played back and displayed completely and stably, that is, they can be copied completely and stably in the new game, so as to achieve the effect of restoring the complete scene.
[0129] Next, the technical solution of the present application is described from the technical side. First, the recording process on the server side is described. Figure 4 As shown, the process of the server generating a recording file includes four stages, namely, the start recording (recording) stage, the stage of recording global status information, the stage of ending recording, and the stage of generating a recording file. Specifically, in the stage of starting recording, various pre-recording status settings and thread preparations will be performed; in the stage of recording global status information, various object information on the server will be copied, and various remote execution statuses will be saved; after the recording stage ends, various types of information will be serialized first, and then in the stage of generating a recording file, various types of serialized information will be compressed and saved to form a final file.
[0130] For the start of recording phase, see Fig. 9 , Fig. 9 is a schematic diagram of the process of starting the recording phase provided in an embodiment of the present application, based on Fig. 9 The recording start phase is implemented by steps 901 to 906. Specifically, after recording starts, a recording class file DemoNetDriver is created first, so as to record the game based on the recording class file. Then, a connection between the server and the client is established. At the same time, a stream file factory class is used to create a writer, so as to complete the writing of the recording file. Finally, the recording thread function is started to prepare for subsequent recording.
[0131] For the phase of recording global state information, see Fig.10 , Fig.10 is a schematic diagram of the recorded global status information provided by the embodiment of the present application, based on Fig.10In the stage of recording global status information, there are mainly three processing processes, namely the first recording process, the second recording process and the third recording process. Here, the first recording process is mainly used to record each game scene frame in the game game, so as to obtain the first recording information. The second recording process is mainly used to periodically record the state of all objects on the server, so as to obtain the second recording information, which is the key to realizing the subsequent playback jump broadcast. The third recording process mainly records the attribute changes of each character in the game game caused by the server, so as to obtain the third recording information.
[0132] It should be noted that if Fig.10 As shown, the first record information here includes the streamed level information (each scene element in each frame of the game scene image of the first game), the object information in the field of view (each virtual object in each frame of the game scene image of the first game), the newly created object information in the scene (each virtual object in each frame of the game scene image of the first game) and the corresponding attribute change value information of these objects (corresponding to the status information of each virtual object); the second record information includes all objects in the target time period and the status data of all objects; and the third record information includes the attribute change information of each object caused by the system pre-set instructions and other auxiliary information.
[0133] For the phase of ending recording and generating recording files, see Fig.11 , Fig.11 is a schematic diagram of the process of ending recording and generating a recording file provided in an embodiment of the present application, based on Fig.11 , the stage of ending recording and generating recording files is implemented by steps 1101 to 1106. Specifically, first, in response to the end instruction triggered by the user based on the client, the recording is stopped, and then the recorded states and objects are serialized, and the serialization results are assembled into various packets for file writing, and then compressed to form the final xx.replay file. In addition, the generated recording will be synchronously saved to the COS server. At the same time, after the recording is completed, DS cleans up temporary variables in various recordings. In this way, the server-side recording process of the game game is completed.
[0134] Next, the process of playing back the recorded file on the client is described. When the server completes the recording process, the server can send the generated recorded file to the terminal running the corresponding client, so that the terminal can store the received recorded file. When playback is required, refer to Fig.12 , Fig.12 This is a schematic diagram of the process of the client replaying the recorded file provided in the embodiment of the present application, based on Fig.12The process of client playing back recorded files includes four stages, namely, the stage of starting playback, the stage of jumping according to time points, the stage of playing back global status information, and the stage of ending playback. Specifically, the stage of starting playback will read the recorded file and create and load the local server; the stage of jumping according to time points will load the specified time point according to the instruction parameters during playback; the stage of playing back global status information will load the corresponding synchronization status information of each frame during the game, and perform continuous state synchronization superposition; the stage of ending playback is to end playback after the recording file is read.
[0135] For the stage of starting playback, see Fig.13 , Fig.13 is a schematic diagram of the process of starting the playback phase provided in an embodiment of the present application, based on Fig.13 , the playback phase is implemented by steps 1301 to 1309. Specifically, when the playback starts, DemoNetDriver is created first, then the connection between the local client and the server is completed, and then the replay file reading class is created to complete the reading of the replay file; then the recording file header information is read, and based on the file header information, the network version of the recording file is verified. After the verification is completed, the playback preparation state is entered. At this time, the client will assign values to various status information, so as to facilitate the determination of the status information of each object and complete the loading of each streaming level.
[0136] For stages that jump to a certain point in time, see Fig.14 , Fig.14 is a schematic diagram of the process of skipping the broadcast according to the time point provided by the embodiment of the present application, based on Fig.14 , the stage of jumping according to the time point is implemented by steps 1401 to 1405. Specifically, the state information of the objects at each time point after the jump time point is obtained according to the jump time point (jump time point) in the received playback instruction (jump instruction), and then all network channel inputs are paused, and the fixed Actors (fixed scene elements and fixed virtual objects) in the level are saved at the same time, and the temporarily created synchronous Actors (temporary scene elements and temporary virtual objects) are destroyed, that is, deleted; the objects and attributes of the objects corresponding to the scene at the jump time point are loaded, so as to complete the reconstruction of all network objects and the update of the corresponding attributes (states), and then the state superposition is performed on this basis, that is, based on the state information of the objects at each time point after the jump time point and the created objects, the states of the objects at each time point after the jump time point are sequentially updated, thereby completing the jump function.
[0137] For the phase of replaying global state information, see Fig.15 , Fig.15is a schematic diagram of the process of replaying global state information provided by an embodiment of the present application, based on Fig.15 The stage of replaying the global state information is implemented by steps 1501 to 1506. Specifically, during the entire replay process, according to the progress of the game, new state information will be continuously read from the replay file, and then the read state information will be processed into various global object update information, that is, based on the read state information, the state of each object will be superimposed (updated); at the same time, all objects in the scene will be updated or destroyed based on these update information, so as to complete the update of all objects; when the update is completed, the camera browser and the playback controller can also be calibrated to complete the state information update of the entire image rendering; and in the process of reading the playback state file, the performance data of the terminal when running the game will also be recorded.
[0138] For the stage of ending playback, see Fig.16 , Fig.16 is a schematic diagram of the process of ending playback provided by an embodiment of the present application, based on Fig.16 The stage of ending playback is implemented by steps 1601 to 1604. Specifically, when the recording file is read, the reading process of the status information will be stopped first, and then a performance file will be generated based on the recorded performance data, and the performance file will be uploaded to the server. Finally, all kinds of created playback files will be destroyed.
[0139] In this way, after the development of various game resources is completed, a single R&D personnel can complete multiple performance tests of multiple people, thereby reducing the manpower and time spent on performance optimization acceptance, greatly saving manpower and material resources; and because of the jump broadcast function, R&D personnel can compress the entire game into a specific period of time for playback verification, greatly improving the efficiency of performance acceptance.
[0140] By applying the above-mentioned embodiment of the present application, when the second game match of the target game starts, a status file for recording the status information of each virtual object at each time point in the first game match is obtained, and then based on the status file, the scene of the second game match is rendered, and in the scene of the second game match, a virtual object corresponding to the starting time point of the first game match is created as the virtual object corresponding to the starting time point of the second game match, thereby based on the status information of the virtual object at each time point of the first game match and the created virtual object, the status of the virtual object at each time point in the time point sequence of the second game match is sequentially updated, and in the process of updating the status of the virtual object in the second game match, the value of each performance parameter of the target game is recorded. In this way, by recording the state file of the virtual object in the previous game, the same game scene as in the previous game is rendered in the new game, and the game process of the previous game is copied and replayed in the new game, so as to record the values of various performance parameters in the new game process. In this way, there is no need to organize players to repeat the game many times, which saves resource consumption and improves the efficiency of obtaining performance parameters. At the same time, it ensures the uniformity of the game process in different game games, which not only improves the efficiency of obtaining performance parameters, but also improves the effectiveness of the obtained performance parameters.
[0141] The following continues to describe the exemplary structure of the device 455 for obtaining performance parameters in the game provided by the embodiment of the present application, which is implemented as a software module. In some embodiments, for example, Figure 2 As shown, the software modules stored in the device 455 for acquiring in-game performance parameters in the memory 450 may include:
[0142] The acquisition module 4551 is used to receive a start instruction for a second game match of a target game, and in response to the start instruction, acquire a state file of a first game match of the target game; wherein the state file records, at each time point of the first game match, state information of each virtual object in the target game, the scene of the second game match is the same as that of the first game match, and the value of at least one performance parameter of the target game in the second game match is different from that of the first game match;
[0143] A rendering module 4552 is used to render the scene of the second game game based on the state file, and create a virtual object corresponding to the starting time point of the first game game in the scene of the second game game as the virtual object corresponding to the starting time point of the second game game;
[0144] An updating module 4553 is used to sequentially update the state of the virtual object at each time point in the time point sequence of the second game game based on the state information of the virtual object at each time point of the first game game and the created virtual object;
[0145] The recording module 4554 is used to record the values of various performance parameters of the target game during the process of updating the status of the virtual object in the second game match.
[0146] In some embodiments, the device also includes a parsing module, which is used to parse the status file to obtain file header information of the status file, wherein the file header information includes version information of the status file; based on the file header information, the version information of the status file is verified to obtain a verification result; the rendering module 4552 is also used to render the scene of the second game game based on the status file when the verification result indicates that the version information of the status file has passed the verification.
[0147] In some embodiments, the rendering module 4552 is also used to obtain object information of each time point of the first game game recorded in the status file, and determine the virtual object corresponding to the starting time point of the first game game from the object information of each time point; based on the determined virtual object, in the scene of the second game game, create a virtual object identical to the determined virtual object as the virtual object corresponding to the starting time point of the second game game.
[0148] In some embodiments, the update module 4553 is also used to obtain, based on the status information of the virtual object at each time point in the first game game, the status information of the virtual object at each time point in the time point sequence of the first game game, starting from the starting time point of the first game game; when the status information obtained is the status information of the virtual object at the starting time point of the first game game, the status of the virtual object at the starting time point of the first game game is determined as the status of the virtual object at the starting time point of the second game game; when the status information obtained is not the status information of the virtual object at the starting time point of the first game game, based on the status information of the virtual object at the time point of the first game game, the status of the virtual object at the previous time point in the second game game is updated.
[0149] In some embodiments, the device also includes a jump module, which is used to receive a jump instruction carrying a jump time point for the second game game during the process of updating the state of the virtual object in the second game game, and the jump instruction is used to instruct to jump the update time point of the state from the current time point to the jump time point; in response to the jump instruction, the state information of each virtual object after the jump time point is selected from the state information of each virtual object at each time point in the first game game recorded in the state file, and a target state file is generated based on the selected state information; the rendering module 4552 is also used to render the scene of the second game game based on the target state file.
[0150] In some embodiments, the update module 4553 is also used to obtain the status information of the virtual objects at each time point after the jump time point based on the target status file; based on the status information of the virtual objects at each time point after the jump time point and the created virtual objects, the status of the virtual objects at each time point after the jump time point in the time point sequence of the second game game is sequentially updated.
[0151] In some embodiments, the target state file includes scene information of each time point after the jump time point in the first game game; the rendering module 4552 is also used to parse the target state file to obtain the scene information and virtual object information of each time point of the first game game corresponding to the target state file; wherein the scene information includes at least one of a fixed scene element and a temporary scene element, the fixed scene element being a scene element that continuously appears in the scene of the first game game, and the temporary scene element being a scene element that appears in the scene of the first game game before the jump time point and is in the scene of the first game game after the jump time point. the virtual object information includes at least one of a fixed virtual object and a temporary virtual object, the fixed virtual object being a virtual object that continuously appears in the scene of the first game match, and the temporary virtual object being a virtual object that appears in the scene of the first game match before the jump time point and does not appear in the scene of the first game match after the jump time point; when the scene information contains temporary information including at least one of the temporary scene element and the temporary virtual object, the temporary information in the scene information is deleted to obtain target scene information; based on the target scene information, the scene of the second game match is rendered.
[0152] In some embodiments, the device also includes a first display module, which is used to display a time point setting control for setting a jump time point; the jump module is also used to display the set jump time point in response to a setting operation triggered based on the time point setting control; in response to a confirmation operation for the set jump time point, a jump instruction carrying the jump time point is received for the second game match.
[0153] In some embodiments, the device also includes a storage module, which is used to generate a performance file based on the recorded values of various performance parameters of the target game; wherein the performance file is used to indicate the performance of a terminal running a second game match of the target game when running the second game match; and the performance file is uploaded to a server so that the server stores the performance file.
[0154] In some embodiments, the device also includes a parameter adjustment module, which is used to obtain the values of various performance parameters of the target game in the first game match; compare the values of various performance parameters of the target game in the first game match with the values of various performance parameters of the target game in the second game match to obtain comparison results; based on the comparison results, adjust the configuration parameters of the terminal running the target game when running the target game to obtain target configuration parameters.
[0155] In some embodiments, the device also includes a second display module, which is used to display the start controls for conducting the second game match in the virtual page of the target game; in response to an input operation triggered by the start controls, the name of the input status file is displayed; the acquisition module 4551 is also used to receive the start instructions for the second game match for the target game in response to a confirmation operation on the name of the input status file.
[0156] The embodiment of the present application provides a computer program product or a computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the electronic device executes the method for obtaining performance parameters in the game described in the embodiment of the present application, for example, Figure 3 A method for obtaining performance parameters in the game is shown.
[0157] The embodiment of the present application provides a computer-readable storage medium storing executable instructions, wherein the executable instructions are stored. When the executable instructions are executed by a processor, the processor will execute the method for obtaining performance parameters in the game provided by the embodiment of the present application, for example, Figure 3 A method for obtaining performance parameters in the game is shown.
[0158] In some embodiments, the computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), a flash memory, a magnetic surface memory, an optical disk, or a CD-ROM; or it may be various devices including one or any combination of the above memories.
[0159] In some embodiments, executable instructions may be in the form of a program, software, software module, script or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine or other unit suitable for use in a computing environment.
[0160] As an example, executable instructions may, but need not, correspond to a file in a file system, may be stored as part of a file that stores other programs or data, such as in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple coordinated files (e.g., files storing one or more modules, subroutines, or code portions).
[0161] As an example, the executable instructions may be deployed to be executed on one electronic device, or on multiple electronic devices located at one site, or on multiple electronic devices distributed at multiple sites and interconnected by a communication network.
[0162] It should be noted that in the embodiments of the present application, it involves obtaining relevant data such as status files. When the embodiments of the present application are applied to specific products or technologies, corresponding permissions or consents need to be obtained, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of relevant countries and regions.
[0163] In summary, the embodiments of the present application have the following beneficial effects:
[0164] (1) By recording the state file containing the state information of the virtual objects in the previous game, the same game scene as in the previous game is rendered in the new game, and the game process of the previous game is copied and replayed in the new game, thereby recording the values of various performance parameters in the new game process. In this way, there is no need to organize players to play repeated games multiple times, which saves resource consumption and improves the efficiency of obtaining performance parameters. At the same time, the uniformity of the game process in different game games is ensured, which not only improves the efficiency of obtaining performance parameters, but also improves the effectiveness of the obtained performance parameters.
[0165] (2) After the development of various game resources is completed, a single developer can complete multiple performance tests that were previously completed by multiple people, thereby reducing the time and effort required for performance optimization acceptance and greatly saving manpower and material resources. In addition, due to the ability to skip playback, developers can compress the entire game into a specific period of time for playback verification, greatly improving the efficiency of performance acceptance.
[0166] (3) It can record the status information of all players during the entire game, thereby obtaining a recording file (status file) containing the status information of various network synchronization objects and each player's client, so that multi-player extreme stress testing only needs to be organized once. When retesting after optimization, the recording file can be directly used to play back on the corresponding client. In this way, a single machine can achieve multi-player extreme stress testing, which is very time-saving and labor-saving. At the same time, due to the stability and consistency of the playback, R&D personnel can efficiently complete the optimization iteration of the target model; and during the playback process, jump playback can be performed, allowing R&D personnel to play back the specified time in the recording file without having to play back from the beginning of the recording file every time, thereby further focusing on problem optimization and improving the efficiency of the optimization process.
[0167] The above is only an embodiment of the present application and is not intended to limit the protection scope of the present application. Any modifications, equivalent substitutions and improvements made within the spirit and scope of the present application are included in the protection scope of the present application.
Claims
1. A method for obtaining performance parameters in a game, characterized in that: The method comprises: receiving a start instruction for a second game match of a target game, and acquiring a status file of a first game match of the target game in response to the start instruction; The state file records, at each time point in the first game match, state information of each virtual object in the target game, the scene of the second game match is the same as that of the first game match, and the value of at least one performance parameter of the target game in the second game match is different from that in the first game match; Rendering the scene of the second game match based on the state file, and creating a virtual object corresponding to the starting time point of the first game match in the scene of the second game match as the virtual object corresponding to the starting time point of the second game match; Based on the state information of the virtual object at each time point of the first game match and the created virtual object, sequentially updating the state of the virtual object at each time point in the time point sequence of the second game match; In the process of updating the state of the virtual object in the second game match, the values of each performance parameter of the target game are recorded.
2. The method according to claim 1, characterized in that After obtaining the status file of the first game match of the target game in response to the start instruction, the method further includes: Parsing the status file to obtain file header information of the status file, wherein the file header information includes version information of the status file; Based on the file header information, verify the version information of the status file to obtain a verification result; The rendering of the second game scene based on the state file includes: When the verification result indicates that the version information of the status file passes the verification, the scene of the second game game is rendered based on the status file.
3. The method according to claim 1, characterized in that The step of creating, in the scene of the second game match, a virtual object corresponding to the starting time point of the first game match as the virtual object corresponding to the starting time point of the second game match, includes: Obtaining object information at each time point of the first game match recorded in the state file, and determining a virtual object corresponding to a starting time point of the first game match from the object information at each time point; Based on the determined virtual object, in the scene of the second game, a virtual object identical to the determined virtual object is created as the virtual object corresponding to the starting time point of the second game.
4. The method according to claim 1, characterized in that The state of the virtual object at each time point in the time point sequence of the second game game is sequentially updated based on the state information of the virtual object at each time point of the first game game and the created virtual object, including: Based on the state information of the virtual object at each time point of the first game match, starting from the start time point of the first game match, sequentially obtain the state information of the virtual object at each time point in the time point sequence of the first game match; When the acquired state information is state information of the virtual object at the start time of the first game match, determining the state of the virtual object at the start time of the first game match as the state of the virtual object at the start time of the second game match; When the acquired status information is not the status information of the virtual object at the starting time point of the first game game, the status of the virtual object at the previous time point in the second game game is updated based on the status information of the virtual object at the time point of the first game game.
5. The method according to claim 1, characterized in that The method further comprises: In the process of updating the state of the virtual object in the second game match, a jump instruction carrying a jump time point for the second game match is received, wherein the jump instruction is used to instruct to jump the update time point of the state from the current time point to the jump time point; In response to the jump instruction, selecting the state information of each virtual object after the jump time point from the state information of each virtual object at each time point in the first game match recorded in the state file, and generating a target state file based on the selected state information; The rendering of the second game scene based on the state file includes: Based on the target state file, render a scene of the second game game.
6. The method according to claim 5, characterized in that The state of the virtual object at each time point in the time point sequence of the second game game is sequentially updated based on the state information of the virtual object at each time point of the first game game and the created virtual object, including: Based on the target state file, obtaining state information of the virtual object at each time point after the jump time point; Based on the state information of the virtual objects at each time point after the jump time point and the created virtual objects, the states of the virtual objects at each time point after the jump time point in the time point sequence of the second game match are sequentially updated.
7. The method according to claim 5, characterized in that The target state file includes scene information of each time point after the jump time point in the first game match; The rendering of the second game scene based on the target state file includes: Parsing the target state file to obtain scene information and virtual object information at each time point of the first game match corresponding to the target state file; The scene information includes at least one of a fixed scene element and a temporary scene element, wherein the fixed scene element is a scene element that continuously appears in the scene of the first game match, and the temporary scene element is a scene element that appears in the scene of the first game match before the jump time point and does not appear in the scene of the first game match after the jump time point; The virtual object information includes at least one of a fixed virtual object and a temporary virtual object, the fixed virtual object being a virtual object that continuously appears in the scene of the first game match, and the temporary virtual object being a virtual object that appears in the scene of the first game match before the jump time point and does not appear in the scene of the first game match after the jump time point; When there is temporary information including at least one of the temporary scene element and the temporary virtual object in the scene information, the temporary information in the scene information is deleted to obtain the target scene information; Based on the target scene information, render the scene of the second game.
8. The method according to claim 5, characterized in that The method further comprises: Display the time point setting controls for setting the jump time point; The receiving a jump instruction carrying a jump time point for the second game match includes: In response to a setting operation triggered by the time point setting control, displaying the set jump time point; In response to a confirmation operation on the set jump time point, a jump instruction carrying the jump time point for the second game match is received.
9. The method according to claim 1, characterized in that After recording the values of the performance parameters of the target game, the method further includes: Generate a performance file based on the recorded values of each performance parameter of the target game; The performance file is used to indicate the performance of a terminal running a second game match of the target game when running the second game match; The performance file is uploaded to a server so that the server stores the performance file.
10. The method according to claim 1, characterized in that After recording the values of the performance parameters of the target game, the method further includes: Obtaining values of various performance parameters of the target game in the first game match; Comparing the values of each performance parameter of the target game in the first game match with the values of each performance parameter of the target game in the second game match to obtain a comparison result; Based on the comparison result, the configuration parameters of the terminal running the target game when running the target game are adjusted to obtain target configuration parameters.
11. The method according to claim 1, characterized in that Before receiving the start instruction of the second game match for the target game, the method further includes: In the virtual page of the target game, displaying a start control for playing the second game; In response to an input operation triggered by the game start control, displaying the name of the input state file; The receiving of a start instruction for a second game match of the target game includes: In response to a confirmation operation on the input name of the state file, an opening instruction for a second game match of the target game is received.
12. A device for obtaining performance parameters in a game, characterized in that: The device comprises: an acquisition module, configured to receive a start instruction for a second game match of a target game, and in response to the start instruction, acquire a state file of a first game match of the target game; wherein the state file records, at each time point of the first game match, state information of each virtual object in the target game, the scene of the second game match is the same as that of the first game match, and the value of at least one performance parameter of the target game in the second game match is different from that of the first game match; a rendering module, configured to render the scene of the second game match based on the state file, and create a virtual object corresponding to the starting time point of the first game match in the scene of the second game match as the virtual object corresponding to the starting time point of the second game match; An updating module, configured to sequentially update the state of the virtual object at each time point in the time point sequence of the second game game based on the state information of the virtual object at each time point of the first game game and the created virtual object; The recording module is used to record the values of various performance parameters of the target game during the process of updating the state of the virtual object in the second game match.
13. An electronic device, characterized in that: include: A memory for storing executable instructions; A processor, configured to implement the method for obtaining performance parameters in a game as described in any one of claims 1 to 11 when executing executable instructions stored in the memory.
14. A computer-readable storage medium, characterized in that: Executable instructions are stored, which are used to cause the processor to execute and implement the method for obtaining performance parameters in the game as described in any one of claims 1 to 11.
15. A computer program product comprising a computer program or computer executable instructions, characterized in that: When the computer program or computer executable instruction is executed by a processor, the method for obtaining performance parameters in a game as described in any one of claims 1 to 11 is implemented.
