Game component editing method and apparatus and electronic device
By recording and applying the relative positions and attribute parameters of scene components in the game editor, target scene components are generated, solving the problem that existing technologies cannot copy the positions and arrangements of multiple objects, and realizing fast and accurate component copying and building.
Patent Information
- Application Number
- PCT/CN2025/079998
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-04-23
- Filing Date
- 2025-02-28
- Publication Date
- 2025-10-30
Smart Images

Figure CN2025079998_30102025_PF_FP_ABST
Abstract
Description
Game component editing methods, devices, and electronic devices
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS
[0002] This application claims priority to Chinese patent application filed on April 23, 2024, application number 202410494992.1, entitled “Method, apparatus and electronic device for editing components in a game”, the entire contents of which are incorporated herein by reference. Technical Field
[0003] This disclosure relates to the field of game interaction design technology, and in particular to a method, apparatus and electronic device for editing components in a game. Background Technology
[0004] Game editors or editing tools provide a function to copy object attributes. This function allows users to copy the attributes of one object to another, and it also supports copying the attributes of multiple objects. However, this function can only copy object attributes, resulting in limited content that cannot meet the personalized copying needs of players. Summary of the Invention
[0005] The purpose of this disclosure is to provide a method, apparatus, and electronic device for editing components in games to improve the richness of content copying, so that users can quickly copy and generate scene components with the same layout.
[0006] In a first aspect, this disclosure provides a component editing method in a game, the method comprising: displaying a graphical user interface by running a game program, the graphical user interface displaying a game editing scene, the game editing scene including multiple scene components, the scene components being components set in the game editing scene in response to editing operations; responding to a first selection operation for a scene component in the game editing scene, determining multiple first scene components selected in the game editing scene based on the first selection operation; responding to a combined editing operation for multiple first scene components, recording first arrangement information corresponding to the multiple first scene components, the first arrangement information including at least one of the following: the relative positional relationship between the multiple first scene components and component attribute parameters corresponding to the multiple first scene components respectively; responding to a second selection operation, determining at least one second scene component; determining at least one second scene component to be adjusted based on the at least one second scene component; adjusting the at least one second scene component to be adjusted based on the first arrangement information, generating at least one target second scene component; controlling the display of at least one target second scene component, wherein the arrangement of the at least one target second scene component in the game editing scene is at least partially the same as the arrangement of the multiple first scene components.
[0007] Secondly, this disclosure provides a component editing device for a game, comprising: an interface display module configured to display a graphical user interface by running a game program, the graphical user interface displaying a game editing scene, the game editing scene including multiple scene components, the scene components being components set in the game editing scene in response to editing operations; a first component selection module configured to perform a first selection operation in response to a scene component in the game editing scene, and determine multiple selected first scene components in the game editing scene based on the first selection operation; and a combination editing module configured to perform a combination editing operation in response to multiple first scene components, recording first arrangement information corresponding to the multiple first scene components, the first arrangement information including at least one of the following. Information includes: the relative positional relationships between multiple first scene components and the component attribute parameters corresponding to each of the multiple first scene components; a second component selection module configured to perform a second selection operation to determine at least one second scene component; a component determination module configured to determine at least one second scene component to be adjusted based on at least one second scene component; a component adjustment module configured to adjust at least one second scene component to be adjusted based on first arrangement information to generate at least one target second scene component; and a component arrangement display module configured to control the display of at least one target second scene component, wherein the arrangement of at least one target second scene component in the game editing scene is at least partially the same as the arrangement of the multiple first scene components.
[0008] Thirdly, this disclosure provides an electronic device including a processor and a memory, the memory storing machine-executable instructions that can be executed by the processor, the processor executing the machine-executable instructions to implement the component editing method in the above-mentioned game.
[0009] Fourthly, this disclosure provides a computer-readable storage medium storing computer-executable instructions that, when invoked and executed by a processor, cause the processor to implement the component editing method in the aforementioned game.
[0010] The embodiments disclosed herein bring the following beneficial effects:
[0011] This disclosure provides a method, apparatus, and electronic device for editing components in a game. First, it responds to a first selection operation on scene components in a game editing scene, determining multiple selected first scene components based on the first selection operation. Then, it responds to a combined editing operation on the multiple first scene components, recording first arrangement information corresponding to the multiple first scene components. The first arrangement information includes at least one of the following: the relative positional relationship between the multiple first scene components and component attribute parameters corresponding to each of the multiple first scene components. Next, it responds to a second selection operation, determining at least one second scene component. Based on the at least one second scene component, it determines at least one second scene component to be adjusted. Then, based on the first arrangement information, it adjusts the at least one second scene component to be adjusted, generating at least one target second scene component, and controls the display of the at least one target second scene component. The arrangement of the at least one target second scene component in the game editing scene is at least partially the same as the arrangement of the multiple first scene components. This method can migrate the layout information of multiple scene components to a specified scene component, allowing players to quickly copy and generate scene components with the same layout. This not only saves time and effort for manual layout but also reduces human error. At the same time, the layout information automatically recorded by the system ensures the accurate position and attribute information of the copied scene components, improving the quality and consistency of component building.
[0012] Other features and advantages of this disclosure will be set forth in the following description, or some features and advantages may be inferred from the description or determined without doubt, or may be learned by practicing the techniques described above.
[0013] To make the above-mentioned objects, features and advantages of this disclosure more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description
[0014] To more clearly illustrate the technical solutions in the specific embodiments or related technologies of this disclosure, the accompanying drawings used in the description of the specific embodiments or related technologies will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this disclosure. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0015] Figure 1 is a flowchart of a component editing method in a game provided by one embodiment of the present disclosure;
[0016] Figure 2 is a schematic diagram of a combined replication provided in one embodiment of this disclosure;
[0017] Figure 3 is a schematic diagram of the selection of a second scene component provided in one embodiment of the present disclosure;
[0018] Figure 4 is a schematic diagram of the arrangement of target scene components provided in one embodiment of this disclosure;
[0019] Figure 5 is a schematic diagram of the structure of a component editing device in a game provided in one embodiment of the present disclosure;
[0020] Figure 6 is a schematic diagram of the structure of an electronic device provided in one embodiment of this disclosure. Detailed Implementation
[0021] To make the objectives, technical solutions, and advantages of the embodiments of this disclosure clearer, the technical solutions of the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this disclosure, and not all embodiments. The components of the embodiments of this disclosure described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.
[0022] Therefore, the following detailed description of the embodiments of this disclosure provided in the accompanying drawings is not intended to limit the scope of the claimed disclosure, but merely to illustrate selected embodiments of the disclosure. All other embodiments obtained by those skilled in the art based on the embodiments of this disclosure without inventive effort are within the scope of protection of this disclosure.
[0023] User-generated content (UGC) editors, design software, or editing tools typically offer a function to copy object attributes, allowing users to copy the attributes of one object to another. However, this method has the following drawbacks: the function to copy object attributes can usually only copy the attribute values of a single object, and cannot copy the relative positions and arrangement information between multiple objects. This can cause inconvenience when it is necessary to copy specific positions or arrangements of objects, requiring users to manually adjust the positions and arrangements.
[0024] In view of the above problems, this disclosure provides a method, apparatus and electronic device for editing components in a game. This technology can be applied to game editing scenarios, especially in scenarios of copying component information in a game.
[0025] In one embodiment of this disclosure, the component editing method in a game can run on a local terminal device or a server. When the component editing method in a game runs on a server, the method can be implemented and executed based on a cloud interaction system, wherein the cloud interaction system includes a server and a client device.
[0026] In an optional implementation, various cloud applications, such as cloud gaming, can run under the cloud interaction system. Taking cloud gaming as an example, cloud gaming refers to a gaming method based on cloud computing. In the cloud gaming operating mode, the game program's execution and the game screen presentation are separated. The storage and execution of the game's component editing methods are completed on the cloud gaming server. The client device is used for data reception, transmission, and game screen presentation. For example, the client device can be a display device with data transmission capabilities located close to the user, such as a mobile terminal, television, computer, or PDA; however, the information processing is performed by the cloud gaming server in the cloud. When playing the game, the player operates the client device to send operation commands to the cloud gaming server. The cloud gaming server runs the game according to the operation commands, encodes and compresses the game screen and other data, returns it to the client device via the network, and finally, the client device decodes and outputs the game screen.
[0027] In an optional implementation, taking a game as an example, the local terminal device stores the game program and is used to display the game screen. The local terminal device is used to interact with the player through a graphical user interface (GUI), i.e., conventionally by downloading, installing, and running the game program via an electronic device. The local terminal device can provide the GUI to the player in various ways, such as rendering it on the terminal's display screen or providing it to the player via holographic projection. For example, the local terminal device can include a display screen for displaying the GUI, which includes game screens, and a processor for running the game, generating the GUI, and controlling the display of the GUI on the display screen.
[0028] In one possible implementation, this disclosure provides a component editing method in a game, as shown in Figure 1. The method includes the following specific steps:
[0029] Step S102: A graphical user interface is displayed by running the game program. The graphical user interface displays a game editing scene, which includes multiple scene components. The scene components are components set in the game editing scene in response to editing operations.
[0030] In practical implementation, the graphical user interface described above is displayed when the game program runs on the terminal device. This game program can be any game application, and the terminal device can be either the aforementioned local terminal device or a client device within the aforementioned cloud interaction system. For example, the terminal device can be a mobile phone, tablet, or personal computer. The game editing scene described above is a scene provided by the running game program; it can also be understood as a scene provided by the game editor during the game editing phase. In the game editing scene, editable components can be edited, and the edited components are designated as scene components within the game editing scene. In practical applications, when a player triggers a game editing command, the game editing scene can be displayed in the graphical user interface. This game editing command can be determined according to the game rules. For example, the editing command could be entering the game editor or selecting a scene map for editing.
[0031] In one specific embodiment, after the game editing scene is displayed in the graphical user interface, scene components can be set in the game editing scene in the following way: a component control window is displayed in the graphical user interface; wherein, the component control window includes multiple scene component controls; in response to an editing operation on a target scene component control in the component controls, a scene component corresponding to the target scene component control is generated in the game editing scene. The aforementioned target scene component control can be any scene component control included in the component control window. The specific operation of the aforementioned editing operation on the target scene component control can be determined according to development needs or according to user settings. For example, the editing operation can be an operation of dragging the target scene component control into the game editing scene, or an operation of clicking or long-pressing the target scene component control in the component control window, etc.
[0032] Specifically, the component types and forms of the scene component controls included in the aforementioned component control window can be set according to development needs. For example, the component control window can include multiple different types of scene component controls, including: terrain component controls, mechanism component controls, decoration component controls, and combination component controls, etc. Each type of scene component control also contains multiple scene component controls. For example, mechanism component controls also include motion mechanism component controls, functional mechanism component controls, logic component controls, object component controls, and floor component controls. Among them, motion mechanism component controls also include cylinders, gears, cross gears, clockwise turntables, etc.
[0033] Step S104: Respond to the first selection operation for scene components in the game editing scene, and determine multiple first scene components selected in the game editing scene based on the first selection operation.
[0034] In practical implementation, the specific operation corresponding to the aforementioned first selection operation can be determined based on player actions and development needs. For example, the first selection operation can be a selection operation, a click operation, or a long-press operation on any scene component among multiple scene components contained in the game editing scene. Players can select any scene component in the game editing scene through the first selection operation, and designate the selected scene component as the first scene component. Furthermore, multiple first scene components can be selected through the first selection operation. Specifically, the aforementioned first scene component can be any one scene component in the game editing scene.
[0035] Step S106: In response to the combined editing operation for multiple first scene components, record the first layout information corresponding to the multiple first scene components. The first layout information includes at least one of the following: the relative positional relationship between the multiple first scene components and the component attribute parameters corresponding to the multiple first scene components respectively.
[0036] After selecting multiple first scene components, these components become selected. At this point, the player can perform a combination editing operation to copy the components, thereby recording the first arrangement information corresponding to the multiple first scene components. Specifically, the specific operation corresponding to this combination copy operation can be determined according to development needs. For example, the combination copy operation can be a trigger operation on a specified control displayed in the graphical user interface, or it can be a trigger operation on a fixed area in the graphical user interface. In a specific embodiment, a combination editing control is displayed in the graphical user interface, and the merchant's combination editing operation includes: triggering an operation on the combination editing control when multiple first scene components are selected.
[0037] In a specific implementation, the aforementioned first arrangement information includes at least one of the following: the relative positional relationships between the first scene components in the plurality of first scene components and the component attribute parameters corresponding to each first scene component. Specifically, the aforementioned related positional relationships include the relative position coordinates corresponding to different first scene components in the plurality of first scene components; for example, the plurality of first scene components can be treated as a whole, the center point coordinates of this whole can be set to (0,0,0), and then the relative coordinates of each scene component in the plurality of first scene components relative to the center point coordinates can be determined as the relative position coordinates corresponding to that first scene component.
[0038] The aforementioned component attribute parameters include at least one of the following: component rotation parameters, component appearance parameters, component size parameters, component interaction parameters, component motion parameters, and component physical parameters. Specifically, the component rotation parameter refers to the omnidirectional rotation angle of the component in the first scene relative to its initial state, where the initial state refers to the orientation of the component in all directions when it was initially set up in the game editing scene; component appearance parameters include component color and component transparency, etc.; component size parameters include the scaled size of the component relative to its initial state or the actual size of the component; component interaction parameters can include conditions or controls that trigger the component to execute preset actions; component motion parameters can include preset actions that the component can execute or events that are triggered, etc.; and component physical parameters include component collision parameters and component force parameters, etc.
[0039] Step S108: In response to the second selection operation, at least one second scene component is determined.
[0040] In practice, the specific operation corresponding to the second selection operation can be determined based on player operation and development needs. For example, the second selection operation can be a selection operation, a click operation, or a long press operation of any scene component among multiple scene components contained in the game editing scene, or it can be a selection operation of scene component controls in the component control window.
[0041] In one specific embodiment, the step of determining at least one second scene component in response to a second selection operation includes at least one of the following: in response to a first selection operation on a scene component in a game editing scene, determining at least one second scene component from the scene components in the game editing scene based on the first selection operation; and in response to a second selection operation on a scene component control in a component control window displayed in a graphical user interface, determining a selected scene component control from the component control window based on the second selection operation, and determining the scene component corresponding to the selected scene component control as the second scene component; wherein the component control window includes multiple scene component controls, and the scene component controls are used to generate scene components corresponding to the scene component controls in the game editing scene in response to editing operations.
[0042] In specific implementation, the aforementioned second selection operation can include only the first selection operation, only the second selection operation, or both. It can also be understood that the second scene component can be a scene component already existing in the game editing scene, or a scene component corresponding to a scene component control in the component control scene; this scene component is the scene component generated in the game editing scene. The aforementioned first selection operation can be a selection operation, click operation, or long-press operation on any scene component among multiple scene components contained in the game editing scene; the player can select any one or more scene components in the game editing scene through the first selection operation and designate the selected scene component as the second scene component. However, the second scene component is different from the first scene component; that is, the first scene component and the second scene component are different scene components in the game editing scene. The aforementioned second selection operation can be: after the player performs a combined editing operation, a click operation or long-press operation on a scene component control in the component control window; the player can select any one or more scene component controls in the component control window through the second selection operation and designate the scene component corresponding to the selected scene component control as the second scene component.
[0043] Step S110: Determine at least one second scene component to be adjusted based on at least one second scene component.
[0044] In practice, all second scene components can be identified as second scene components to be adjusted, or only some of the second scene components can be identified as second scene components to be adjusted.
[0045] Step S112: Adjust at least one second scene component to be adjusted based on the first layout information to generate at least one target second scene component.
[0046] In practical implementation, the first layout information can be applied to the second scene component to be adjusted. That is, the layout of the second scene component to be adjusted in the game editing scene is adjusted based on the first layout information, thereby generating at least one target second scene component whose layout is at least partially the same as the layout corresponding to the first layout information. There is a one-to-one correspondence between the at least one target second scene component and the at least one second scene component to be adjusted. However, the component attribute parameters corresponding to the at least one target second scene component are different from the component attribute parameters corresponding to the at least one second scene component to be adjusted, and the relative positional relationship between the at least one target scene component matches the relative positional relationship indicated by the first layout information.
[0047] In an optional embodiment, if the number of components in the second scene component to be adjusted is the same as the number of components in the first scene component, it is necessary to determine the one-to-one correspondence between the second scene component to be adjusted and the first scene component. Then, the relative positional relationship and component attribute parameters corresponding to the first scene component are applied to the second scene component to be adjusted that corresponds to the first scene component, resulting in the second scene component to be adjusted after information application (equivalent to the aforementioned target second scene component). At this time, the arrangement of the target second scene component in the game editing scene is exactly the same as the arrangement of multiple first scene components.
[0048] In another optional embodiment, if the number of components in the second scene component to be adjusted is less than the number of components in the first scene component, it is necessary to determine the arrangement shape formed by the positions of the multiple first scene components based on the relative positional relationships between the multiple first scene components in the first arrangement information and the component attribute parameters corresponding to the multiple first scene components. Then, the positions and component attribute parameters of the second scene component to be adjusted are adjusted according to this arrangement shape to obtain the target second scene component, so that the arrangement shape of the target second scene component is the same as that of the multiple first scene components. For example, if the number of components in the first scene component is seven and the number of components in the second scene component to be adjusted is three, and the arrangement shape formed by the relative positional relationships of the seven first scene components is a Big Dipper shape, then the positions of the three second scene components to be adjusted can be placed on the trajectory of the Big Dipper shape to obtain three target second scene components with a Big Dipper shape.
[0049] Step S114: Control the display of at least one target second scene component, wherein the arrangement of at least one target second scene component in the game editing scene is at least partially the same as the arrangement of multiple first scene components.
[0050] After generating at least one target second scene component, it is necessary to display this target second scene component in the graphical user interface, with an arrangement that is at least partially the same as that of the multiple first scene components. This allows players to easily check whether the current arrangement of the target second scene component meets their needs.
[0051] This disclosure provides a component editing method in a game. This method can migrate the layout information of multiple scene components to a specified scene component, so that players can quickly copy and generate scene components with the same layout. This not only saves the time and effort of manual layout, but also reduces human layout errors. At the same time, the layout information automatically recorded by the system can ensure the accurate position and attribute information of the copied scene components, thereby improving the quality and consistency of component construction.
[0052] The following examples describe how to determine the second scene component to be adjusted.
[0053] Specifically, the above-described process of determining at least one second scene component to be adjusted based on at least one second scene component includes at least one of the following:
[0054] At least one second scene component is identified as at least one second scene component to be adjusted; and, the number of components of multiple first scene components is obtained, and the same number of second scene components to be adjusted is generated based on the number of components and at least one second scene component, and the same number of second scene components to be adjusted is identified as at least one second scene component to be adjusted.
[0055] In practical implementation, all second-scene components can be designated as components to be adjusted. The number of components in these second-scene components may be less than, the same as, or greater than the number of components in the first-scene components. Alternatively, it can be ensured that the number of components in the second-scene components is the same as the number of components in the first-scene components. To guarantee this, the number of second-scene components can be increased when the total number of components in all second-scene components is less than the total number of components in the first-scene components, or some second-scene components can be deleted when the total number of components in all second-scene components is greater than the total number of components in the first-scene components.
[0056] In practical applications, the specific process of generating the same number of second scene components to be adjusted based on the number of components and at least one second scene component, and determining the same number of second scene components to be adjusted as at least one second scene component to be adjusted, includes the following steps 10-11:
[0057] Step 10: In response to the fact that the number of components of at least one second scene component is less than the number of components of multiple first scene components, the at least one second scene component is expanded to obtain an expanded second scene component, and the at least one second scene component and the expanded second scene component are determined as at least one second scene component to be adjusted; wherein, the total number of components of the at least one second scene component and the expanded second scene component is the same as the number of components of multiple first scene components.
[0058] In practical implementation, when the number of components in the second scene component is less than the number of components in the first scene component, the second scene component needs to be expanded so that the number of components in the expanded second scene component equals the number of components in the first scene component. Specifically, the number of components to be expanded in the second scene component is the difference between the number of components in the first scene component and the number of components in the second scene component.
[0059] In an optional embodiment, it is first necessary to determine the result of subtracting the number of components from the number of components in multiple first scene components and the number of components in at least one second scene component, and determine the component expansion quantity from the subtracted result; then, select the same number of expanded second scene components from the at least one second scene component. That is, the same number of second scene components as the component expansion quantity can be randomly selected from all the second scenes or selected in a preset order as the expanded second scene components, wherein the preset order can be the selection order of the second scene components or the arrangement order of the second scene components in the game editing scene.
[0060] In another optional embodiment, when determining the expanded second scene, the component types of the expanded second scene components can also be determined according to preset rules; then, expanded second scene components are generated based on the component types. The component types can include at least one of the following: component shape, component color, and component category, etc. Specifically, the preset rules can include: random rules; or, according to the selection order of the first scene components and the number of component expansions, the corresponding component types of the expanded second scene components are generated based on the component types of multiple first scene components; wherein, the number of component expansions is the result of subtracting the number of components of multiple first scene components from the number of components of at least one second scene component.
[0061] In practical implementation, the component type of the expanded second scene component can be randomly determined, and then expanded second scene components matching that component type can be generated, with the number of generated expanded second scene components matching the number of expanded components. Alternatively, the component type of the expanded second scene component can be determined based on the selection order of the first scene components, the number of expanded components, and the component type of the first scene components. For example, if the second scene component has 3 components and the first scene component has 5 components, and the component types corresponding to the 5 first scene components are ellipse, circle, square, rectangle, and triangle, then the number of expanded components corresponding to the second scene component is 2, and the component type corresponding to the expanded second scene component is the component type corresponding to the last two of the 5 first scene components, namely rectangle and triangle.
[0062] In practical applications, in response to the fact that the number of components in at least one second scene component is greater than the number of components in multiple first scene components, based on the selection order of the second scene components, a number of second scene components to be adjusted, equal to the number of components in multiple first scene components, are determined from the at least one second scene component. Specifically, when the number of components in the second scene component is greater than the number of components in the first scene component, the second scene component with the same number of components as the multiple first scene components selected from all the second scene components can be determined as the second scene component to be adjusted; alternatively, the second scene component with the same number of components as the multiple first scene components can be determined from the second scene components selected from the second scene components that are later in the order or in the middle.
[0063] Step 11: In response to the fact that the number of components of at least one second scene component is equal to the number of components of multiple first scene components, at least one second scene component is determined as at least one second scene component to be adjusted.
[0064] In other words, when the number of components in the second scene selected by the player is exactly the same as the number of components in multiple first scene components, all the second scene components selected by the player are identified as second scene components to be adjusted.
[0065] The above method can determine the second scene component to be adjusted based on at least one second scene component, which facilitates the subsequent adjustment of the position and attribute parameters of the second scene component to be adjusted, so as to obtain a component layout that matches the first layout information.
[0066] The following examples describe a method for generating the target second scene component.
[0067] Specifically, the process of adjusting at least one second scene component to be adjusted based on the first arrangement information to generate at least one target second scene component can be achieved through the following steps 20-22:
[0068] Step 20: Determine the first preset order of multiple first scene components and the second preset order of at least one second scene component to be adjusted.
[0069] In practice, the first preset order is related to the selection order of the first scene components, and the second preset order is related to the selection order of the second scene components corresponding to the second scene components to be adjusted.
[0070] In one specific embodiment, the first preset order includes a sorting number corresponding to each of the plurality of first scene components; wherein, the sorting number corresponding to the first scene component can be randomly determined, or the sorting number corresponding to the first scene component can match the selection order of the first scene components; that is, the later the selection order of the first scene component, the larger the sorting number corresponding to the first scene component. For example, the sorting number of the first selected first scene component is 1, the sorting number of the second selected first scene component is 2, and so on; in addition, if two first scene components are selected at the same time, the sorting numbers corresponding to these two first scene components are randomly determined.
[0071] The aforementioned second preset order may include a sorting number corresponding to each of the at least one second scene components to be adjusted; wherein, the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component or is randomly determined, or the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component and the expansion order of the expanded second scene component.
[0072] In one specific embodiment, the sorting number corresponding to each second scene component to be adjusted can be randomly determined. In another specific embodiment, if the second scene component to be adjusted contains only at least one second scene component, then the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component; that is, the sorting number corresponding to the second scene component to be adjusted matches the selection order of the second scene component to be adjusted. For example, if the second scene component to be adjusted is exactly the same as the second scene component selected by the player, then the later the selection order of the second scene component, the larger the sorting number of the second scene component to be adjusted.
[0073] If the second scene component to be adjusted includes at least one second scene component and a supplementary second scene component, the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of the at least one second scene component and the expansion order of the supplementary second scene component. This expansion order can refer to the order in which the supplementary second scene components are determined, or it can be a random order. Specifically, the sorting number corresponding to at least one second scene component in the at least one second scene component to be adjusted is less than the sorting number corresponding to the supplementary second scene component. For example, if the second scene components included in the second scene component to be adjusted match the order in which the player selects the second scene components, then the later the selection order of the second scene component, the larger the sorting number of the second scene component to be adjusted corresponding to that second scene component. The sorting number of the supplementary second scene component can continue the sorting number corresponding to the selection order of the second scene components, and the sorting number corresponding to the supplementary second scene component can be randomly determined. If the number of components in the second scene component to be adjusted is 5, and the number of components in the second scene component selected by the player is 3, then the sorting number of the second scene component to be adjusted corresponding to the second scene component selected by the player is the same as the selection order of the second scene component. The sorting number of the supplementary second scene component in the second scene component to be adjusted can be randomly determined as 4 or 5.
[0074] Step 21: Determine the second arrangement information of at least one second scene component to be adjusted according to the first preset order, the second preset order and the first arrangement information; wherein, the second arrangement information includes at least one of the following: the relative positional relationship between at least one second scene component to be adjusted, and the component attribute parameters corresponding to at least one second scene component to be adjusted.
[0075] In practice, the second layout information of the second scene component to be adjusted is matched with the first layout information. If the number of components in the second scene component to be adjusted is the same as the number of components in the first scene component in the first sorting information, then there is a one-to-one correspondence between the second scene component to be adjusted and the first scene component. Therefore, the sorting information corresponding to the first scene component will be applied to the corresponding second scene component to be adjusted, so that the corresponding first scene component and the second scene component to be adjusted have the same relative position coordinates and component attribute parameters. If the number of components in the second scene component to be adjusted is less than the number of components in the first scene component in the first sorting information, the relative positional relationship between the second scene components to be adjusted will be determined according to the layout shape formed by the relative positional relationship in the first layout information, so that the layout shape of the second scene component to be adjusted is the same as that in the first layout information.
[0076] In one specific embodiment, if the number of components of the second scene component to be adjusted is the same as the number of components of the first scene component, the specific process of step 21 above includes: determining the correspondence between the second scene component to be adjusted and the first scene component based on the sorting number corresponding to the first scene component in the first preset order and the sorting number corresponding to the second scene component to be adjusted in the second preset order; wherein, when there is a correspondence between the second scene component to be adjusted and the first scene component, the sorting number corresponding to the second scene component to be adjusted matches the sorting number corresponding to the first scene component; and determining the second arrangement information of at least one second scene component to be adjusted according to the correspondence and the first arrangement information.
[0077] In practical implementation, since the number of components in the second scene component to be adjusted is the same as the number of components in the first scene component, there is a one-to-one correspondence between the second scene component and the first scene component. Therefore, the relative positional relationships and component attribute parameters corresponding to the first scene component can be transferred to the second scene component to be adjusted, thus obtaining the relative positional relationships and component attribute parameters corresponding to the second scene component to be adjusted. Specifically, the correspondence between the second scene component to be adjusted and the first scene component can be determined based on the position and sorting number of the second scene component to be adjusted, or it can be determined solely based on the sorting number of the second scene component to be adjusted.
[0078] In an optional embodiment, a correspondence is established between the second scene component to be adjusted and the first scene component with the same sorting number. For example, the second scene component to be adjusted with sorting number 1 corresponds to the first scene component with sorting number 1, the second scene component to be adjusted with sorting number 2 corresponds to the first scene component with sorting number 2, and so on, to determine the one-to-one correspondence between the second scene component to be adjusted and the first scene component.
[0079] In one specific embodiment, the process of determining the second arrangement information of at least one second scene component to be adjusted based on the correspondence and the first arrangement information includes: for each of the at least one second scene component to be adjusted, determining a target first scene component that has a corresponding relationship with the current second scene component to be adjusted, and configuring the first arrangement information corresponding to the target first scene component as the arrangement information corresponding to the current second scene component to be adjusted; and obtaining the second arrangement information corresponding to at least one second scene component to be adjusted based on the arrangement information corresponding to each of the at least one second scene component to be adjusted.
[0080] For example, if multiple first scene components include: first scene component 1 with a sorting number of 1, first scene component 2 with a sorting number of 2, and first scene component 3 with a sorting number of 3; and multiple second scene components to be adjusted include: second scene component 1 to be adjusted with a sorting number of 1, second scene component 2 to be adjusted with a sorting number of 2, and second scene component 3 to be adjusted with a sorting number of 3, then there is a correspondence between second scene component 1 and first scene component 1, second scene component 2 and first scene component 2, and second scene component 3 and first scene component 3. Based on this, the relative position relationship and component attribute parameters corresponding to first scene component 1 can be copied to second scene component 1 to be adjusted, the relative position relationship and component attribute parameters corresponding to first scene component 2 can be copied to second scene component 2 to be adjusted, and the relative position relationship and component attribute parameters corresponding to first scene component 3 can be copied to second scene component 3 to be adjusted.
[0081] Step 22: Generate at least one target second scene component based on the second layout information and at least one second scene component to be adjusted.
[0082] In specific implementation, the above component attribute parameters include at least one of the following: component rotation parameters, component appearance parameters, component size parameters, component interaction parameters, component motion parameters, and component physical parameters.
[0083] In practical applications, the relative positional relationships between the first scene components can be configured based on the correspondence between the second scene components to be adjusted and the first scene components. In one specific embodiment, when the component attribute parameters include component rotation parameters, for each of the at least one second scene components to be adjusted, a target first scene component that corresponds to the current second scene component to be adjusted is determined, and the component rotation parameters corresponding to the target first scene component are configured to be the same as those corresponding to the current second scene component to be adjusted. This generates a target second scene component in the game editing scene with the same arrangement as the multiple first scene components.
[0084] In an optional embodiment, the component attribute parameters include a component size parameter, which is the scaling size corresponding to the first scene component. This scaling size indicates the scaling magnitude of the first scene component relative to its initial state. For example, the scaling size can be one, two, or three times the initial state. Based on this, for each of the at least one second scene component to be adjusted, a target first scene component corresponding to the current second scene component to be adjusted is determined, and the scaling size corresponding to the target first scene component is configured to be the scaling size corresponding to the current second scene component to be adjusted. This method can adjust the scaling size of the second scene component to be adjusted to be the same as the scaling size of the first scene component to which it corresponds, thereby making the component display state of the second scene component to be adjusted completely the same as the component display state of the first scene component.
[0085] In the above methods, users can select the desired combination of elements to copy, and the system will record the number of selected scene components, their relative positions, and component attribute parameters. Users can quickly and efficiently copy combinations of the same arrangement between different components, eliminating the hassle of manual rearrangement and saving time and effort. Furthermore, users can quickly copy and generate scene components with the same arrangement. This not only saves time and labor from manual arrangement but also reduces human error. Simultaneously, the automatically recorded arrangement information ensures the accurate position, angle, and scaling of copied scene components, improving the quality and consistency of the build.
[0086] The following examples describe the selection of scene components in a game editing scene and the method of recording arrangement information.
[0087] Specifically, players can select multiple first scene components in the game editing scene to copy information as needed. These first scene components can be any scene component within the game editing scene. When selecting a first scene component, its sequence number must be determined and recorded based on the selection order.
[0088] In an optional embodiment, the graphical user interface displays a combined editing control; the combined editing operation for multiple first scene components includes: a trigger operation on the combined editing control when multiple first scene components are selected. This trigger operation can be a click operation or a long-press operation on the combined editing control, etc., which can be determined according to development needs. The display position and physical form of the combined editing control in the graphical user interface can be determined according to development needs.
[0089] Figure 2 shows a schematic diagram of a combined copying method provided in this embodiment of the present disclosure. Figure 2 includes a multi-selection control and a combined editing control. Players can click the multi-selection control to select multiple scene components in the game editing scene, and define the selected scene components as the first scene components. After multiple first scene components are selected, players can click the combined editing control to enter the copying process. The cuboid, rectangle, triangle, and pentagram models in Figure 2 are scene components in the game editing scene, among which the five gray scene components are the selected first scene components.
[0090] After the player triggers the combination editing control, the system automatically records the first layout information corresponding to multiple first scene components. This first layout information may include, but is not limited to, the number of components of multiple first scene components, the sorting number of the first scene components, the relative positional relationship between multiple first scene components, and the component attribute parameters corresponding to each of the multiple first scene components.
[0091] After the layout information is recorded, the system responds to selection operations on scene components within the game editing scene, confirming the selected scene components and recording their selection order. It also responds to trigger operations on confirmation controls displayed in the graphical user interface, designating the selected scene components as the second scene components. Specifically, when a player selects a first scene component in the game editing scene, a confirmation control is displayed in the graphical user interface. This control determines which scene components are currently selected. Players can select one or more scene components in the game editing scene, trigger the confirmation control, and designate the selected scene components as the second scene components. During the process of selecting scene components in the game scene, the system also records the selection order of the selected scene components to establish a one-to-one correspondence between the selected scene components and the multiple first scene components corresponding to the layout information.
[0092] Figure 3 shows a schematic diagram of the selection of a second scene component provided in an embodiment of this disclosure. The five scene components selected by the rectangle in Figure 3 are the second scene components. After the player selects the components, a confirmation control can be triggered to confirm the selected scene components as the second scene components that need to be rearranged according to the recorded arrangement information.
[0093] During the player's selection of scene components, if the number of selected scene components exceeds the total number of components in multiple first-order scene components, a prompt message is displayed in the graphical user interface. This prompt message indicates that the number of selected scene components exceeds the total number of components in multiple first-order scene components. After the prompt message appears, it can be assumed that the maximum number of scene components has been reached, and no more scene components can be selected.
[0094] Specifically, if the number of selected second scene components is less than the number of components in the layout information, there is a lack of scene components with a one-to-one correspondence. Therefore, it is necessary to randomly fill the gaps with second scene components from all the selected components to ensure that the number of components in the subsequently generated target second scene components is the same as the number of components in the first layout information. If the number of selected second scene components is equal to the number of components in the first layout information, the scene components are matched one-to-one according to the selection order, and the corresponding information is matched. If the number of selected second scene components is greater than the number of components in the first layout information, a prompt message is displayed, which may include "The maximum number has been reached, and no more can be selected."
[0095] In practical implementation, the selected second scene component can be rearranged in the game editing scene according to the first arrangement information corresponding to multiple first scene components, so as to generate a rearranged target second scene component. The target second scene component has the same arrangement method as the multiple first scene components. Figure 4 shows a schematic diagram of the arrangement of target scene components provided in this embodiment of the present disclosure. The multiple target scene components in Figure 4 are obtained by rearranging the selected first scene components in Figure 3 according to the first arrangement information.
[0096] In this method, players can choose the combination they want to copy, and the system will record information such as the number of components, their relative positions, and component attribute parameters of the selected first scene component. Users can quickly and efficiently copy the same arrangement of components across different scenes, eliminating the hassle of manually rearranging them and saving time and effort.
[0097] Corresponding to the above method embodiments, this disclosure also provides a component editing device in a game, as shown in FIG5, the device comprising:
[0098] The interface display module 50 is configured to display a graphical user interface by running a game program. The graphical user interface displays a game editing scene, which includes multiple scene components. These scene components are set in the game editing scene in response to editing operations.
[0099] The first component selection module 51 is configured to perform a first selection operation in response to a scene component in the game editing scene, and to determine multiple first scene components selected in the game editing scene based on the first selection operation.
[0100] The combined editing module 52 is configured to perform combined editing operations on multiple first scene components and record the first layout information corresponding to the multiple first scene components. The first layout information includes at least one of the following: the relative positional relationship between the multiple first scene components and the component attribute parameters corresponding to the multiple first scene components respectively.
[0101] The second component selection module 53 is configured to perform a response to a second selection operation to determine at least one second scene component.
[0102] The component determination module 54 is configured to perform the determination of at least one second scene component to be adjusted based on at least one second scene component.
[0103] The component adjustment module 55 is configured to adjust at least one second scene component to be adjusted based on the first arrangement information, and generate at least one target second scene component.
[0104] The component layout display module 56 is configured to perform control display of at least one target second scene component, wherein the layout of the at least one target second scene component in the game editing scene is at least partially the same as the layout of the plurality of first scene components.
[0105] The component editing device in the aforementioned game can migrate the layout information of multiple scene components to a specified scene component, allowing players to quickly copy and generate scene components with the same layout. This not only saves time and effort in manual layout but also reduces human error. At the same time, the layout information automatically recorded by the system ensures the accurate position and attribute information of the copied scene components, improving the quality and consistency of component construction.
[0106] Specifically, the second component selection module 53 mentioned above includes at least one of the following implementation methods: responding to a first selection operation for a scene component in the game editing scene, determining at least one second scene component from the scene components in the game editing scene based on the first selection operation; and responding to a second selection operation for a scene component control in a component control window displayed in the graphical user interface, determining the selected scene component control from the component control window based on the second selection operation, and determining the scene component corresponding to the selected scene component control as the second scene component; wherein, the component control window includes multiple scene component controls, and the scene component controls are used to generate scene components corresponding to the scene component controls in the game editing scene in response to editing operations.
[0107] In a specific implementation, the aforementioned component adjustment module 55 is configured to perform the following: determining a first preset order of multiple first scene components and a second preset order of at least one second scene component to be adjusted; determining second arrangement information of at least one second scene component to be adjusted based on the first preset order, the second preset order, and the first arrangement information; wherein the second arrangement information includes at least one of the following: the relative positional relationship between at least one second scene component to be adjusted, and the component attribute parameters corresponding to at least one second scene component to be adjusted; and generating at least one target second scene component based on the second arrangement information and at least one second scene component to be adjusted.
[0108] In a specific implementation, the component determination module 54 includes at least one of the following implementation methods: determining at least one second scene component as at least one second scene component to be adjusted; and obtaining the component count of multiple first scene components, generating a number of second scene components to be adjusted equal to the component count based on the component count and at least one second scene component, and determining the number of second scene components to be adjusted equal to the component count as at least one second scene component to be adjusted.
[0109] Furthermore, the aforementioned component determination module 54 is also configured to perform: in response to the fact that the number of components of at least one second scene component is less than the number of components of multiple first scene components, to perform an expansion process on at least one second scene component to obtain an expanded second scene component, and to determine at least one second scene component and the expanded second scene component as at least one second scene component to be adjusted; wherein, the total number of components of at least one second scene component and the expanded second scene component is the same as the number of components of multiple first scene components; in response to the fact that the number of components of at least one second scene component is equal to the number of components of multiple first scene components, to determine at least one second scene component as at least one second scene component to be adjusted.
[0110] Specifically, the first preset order includes a sorting number corresponding to each of the multiple first scene components; wherein the sorting number corresponding to the first scene component matches the selection order of the first scene components or the sorting number corresponding to the first scene component is randomly determined; the second preset order includes a sorting number corresponding to each of the at least one second scene component to be adjusted; wherein the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component or the sorting number corresponding to the second scene component to be adjusted is randomly determined, or the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component and the expansion order of the expanded second scene component.
[0111] In a specific implementation, when the above-mentioned at least one second scene component to be adjusted includes at least one second scene component and an extended second scene component, the sorting number corresponding to at least one second scene component in the at least one second scene component to be adjusted is less than the sorting number corresponding to the extended second scene component.
[0112] Furthermore, the aforementioned component adjustment module 55 is also configured to perform: determining the correspondence between the second scene component to be adjusted and the first scene component based on the sorting number corresponding to the first scene component in the first preset order and the sorting number corresponding to the second scene component to be adjusted in the second preset order; wherein, when there is a correspondence between the second scene component to be adjusted and the first scene component, the sorting number corresponding to the second scene component to be adjusted matches the sorting number corresponding to the first scene component; and determining the second arrangement information of at least one second scene component to be adjusted according to the correspondence and the first arrangement information.
[0113] In a specific implementation, the aforementioned component adjustment module 55 is further configured to perform the following: for each of the at least one second scene components to be adjusted, determine a target first scene component that has a corresponding relationship with the current second scene component to be adjusted, and configure the first layout information corresponding to the target first scene component as the layout information corresponding to the current second scene component to be adjusted; based on the layout information corresponding to each of the at least one second scene components to be adjusted, obtain the second layout information corresponding to at least one second scene component to be adjusted.
[0114] Furthermore, the aforementioned component determination module 54 is also configured to perform: in response to the fact that the number of components of at least one second scene component is greater than the number of components of multiple first scene components, determine, based on the selection order of the second scene components, the same number of second scene components to be adjusted from at least one second scene component as the number of components of multiple first scene components.
[0115] In an optional embodiment, the component determination module 54 is further configured to perform: determining the result of subtracting the number of components of a plurality of first scene components from the number of components of at least one second scene component, and determining the subtraction result as the number of component expansions; and determining the number of expanded second scene components from at least one second scene component that is the same as the number of component expansions.
[0116] In another optional embodiment, the component determination module 54 is further configured to perform: determining the component type of the extended second scene component according to a preset rule; and generating the extended second scene component based on the component type.
[0117] In specific implementation, the above-mentioned preset rules include: random rules; or according to the selection order of the first scene components and the number of component expansions, the corresponding component types of the expanded second scene components are generated based on the component types of the multiple first scene components; wherein, the number of component expansions is the result of subtracting the number of components of the multiple first scene components from the number of components of at least one second scene component.
[0118] In specific implementation, the above component attribute parameters include at least one of the following: component rotation parameters, component appearance parameters, component size parameters, component interaction parameters, component motion parameters, and component physical parameters.
[0119] Furthermore, the graphical user interface described above displays a combined editing control; the combined editing operation includes: triggering an operation on the combined editing control when multiple first scene components are selected.
[0120] Furthermore, the aforementioned second component selection module 53 is configured to: respond to a selection operation of a scene component in the game editing scene, determine the selected scene component and record the selection order of the selected scene components; and respond to a trigger operation of a confirmation control displayed in the graphical user interface, determine the selected scene component as the second scene component.
[0121] Furthermore, the aforementioned device also includes an information prompting module configured to: in response to the number of components of the selected scene component being greater than the number of components of the plurality of first scene components, control the display of prompting information in the graphical user interface, the prompting information being used to indicate that the number of components of the selected scene component is greater than the number of components of the plurality of first scene components.
[0122] The component editing device in the game provided in this disclosure has the same implementation principle and technical effect as the aforementioned method embodiment. For the sake of brevity, any parts not mentioned in the device embodiment can be referred to the corresponding content in the aforementioned method embodiment.
[0123] This disclosure also provides an electronic device, as shown in FIG6, which includes a processor and a memory. The memory stores machine-executable instructions that can be executed by the processor. The processor executes the machine-executable instructions to implement the component editing method in the above-mentioned game.
[0124] Specifically, the process of the component editing method in the above game may include: displaying a graphical user interface by running the game program, the graphical user interface displaying a game editing scene, the game editing scene including multiple scene components, the scene components being components set in the game editing scene in response to editing operations; responding to a first selection operation for a scene component in the game editing scene, determining multiple first scene components selected in the game editing scene based on the first selection operation; responding to a combined editing operation for multiple first scene components, recording first arrangement information corresponding to the multiple first scene components, the first arrangement information including at least one of the following: the relative positional relationship between the multiple first scene components and the component attribute parameters corresponding to the multiple first scene components respectively; responding to a second selection operation, determining at least one second scene component; determining at least one second scene component to be adjusted based on the at least one second scene component; adjusting the at least one second scene component to be adjusted based on the first arrangement information, generating at least one target second scene component; controlling the display of at least one target second scene component, wherein the arrangement of the at least one target second scene component in the game editing scene is at least partially the same as the arrangement of the multiple first scene components.
[0125] The component editing method in the game described above can migrate the layout information of multiple scene components to a specified scene component, allowing players to quickly copy and generate scene components with the same layout. This not only saves time and effort in manual layout but also reduces human error. At the same time, the layout information automatically recorded by the system ensures the accurate position and attribute information of the copied scene components, improving the quality and consistency of component building.
[0126] In an optional embodiment, the step of determining at least one second scene component in response to the second selection operation includes at least one of the following: in response to a first selection operation on a scene component in the game editing scene, determining at least one second scene component from the scene components in the game editing scene based on the first selection operation; in response to a second selection operation on a scene component control in a component control window displayed in the graphical user interface, determining the selected scene component control from the component control window based on the second selection operation, and determining the scene component corresponding to the selected scene component control as the second scene component; wherein, the component control window includes multiple scene component controls, and the scene component controls are used to generate scene components corresponding to the scene component controls in the game editing scene in response to editing operations.
[0127] In an optional embodiment, the step of adjusting at least one second scene component to be adjusted based on the first arrangement information to generate at least one target second scene component includes: determining a first preset order of multiple first scene components and a second preset order of at least one second scene component to be adjusted; determining second arrangement information of at least one second scene component to be adjusted according to the first preset order, the second preset order and the first arrangement information; wherein the second arrangement information includes at least one of the following: the relative positional relationship between at least one second scene component to be adjusted, and the component attribute parameters corresponding to at least one second scene component to be adjusted; generating at least one target second scene component according to the second arrangement information and at least one second scene component to be adjusted.
[0128] In an optional embodiment, the step of determining at least one second scene component to be adjusted based on at least one second scene component includes at least one of the following: determining at least one second scene component as at least one second scene component to be adjusted; obtaining the component count of multiple first scene components, and generating a number of second scene components to be adjusted equal to the component count based on the component count and at least one second scene component, and determining the number of second scene components to be adjusted equal to the component count as at least one second scene component to be adjusted.
[0129] In an optional embodiment, the step of generating a number of second scene components to be adjusted equal to the number of components based on the number of components and at least one second scene component, and determining the number of second scene components to be adjusted equal to the number of components as at least one second scene component to be adjusted, includes: in response to the fact that the number of components of at least one second scene component is less than the number of components of multiple first scene components, expanding at least one second scene component to obtain expanded second scene components, and determining at least one second scene component and expanded second scene components as at least one second scene component to be adjusted; wherein, the total number of components of at least one second scene component and expanded second scene component is the same as the number of components of multiple first scene components; in response to the fact that the number of components of at least one second scene component is equal to the number of components of multiple first scene components, determining at least one second scene component as at least one second scene component to be adjusted.
[0130] In an optional embodiment, the first preset order includes a sorting number corresponding to each of the plurality of first scene components; wherein the sorting number corresponding to the first scene component matches the selection order of the first scene components or the sorting number corresponding to the first scene component is randomly determined; the second preset order includes a sorting number corresponding to each of the at least one second scene component to be adjusted; wherein the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component or the sorting number corresponding to the second scene component to be adjusted is randomly determined, or the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component and the expansion order of the expanded second scene component.
[0131] In an optional embodiment, when the at least one second scene component to be adjusted includes at least one second scene component and an expanded second scene component, the sorting number corresponding to at least one second scene component in the at least one second scene component to be adjusted is less than the sorting number corresponding to the expanded second scene component.
[0132] In an optional embodiment, the step of determining the second arrangement information of at least one second scene component to be adjusted based on the first preset order, the second preset order, and the first arrangement information includes: determining the correspondence between the second scene component to be adjusted and the first scene component based on the sorting number corresponding to the first scene component in the first preset order and the sorting number corresponding to the second scene component to be adjusted in the second preset order; wherein, when there is a correspondence between the second scene component to be adjusted and the first scene component, the sorting number corresponding to the second scene component to be adjusted matches the sorting number corresponding to the first scene component; and determining the second arrangement information of at least one second scene component to be adjusted based on the correspondence and the first arrangement information.
[0133] In an optional embodiment, the step of determining the second arrangement information of at least one second scene component to be adjusted based on the correspondence and the first arrangement information includes: for each of the at least one second scene component to be adjusted, determining a target first scene component that has a corresponding relationship with the current second scene component to be adjusted, and configuring the first arrangement information corresponding to the target first scene component as the arrangement information corresponding to the current second scene component to be adjusted; and obtaining the second arrangement information corresponding to at least one second scene component to be adjusted based on the arrangement information corresponding to each of the at least one second scene component to be adjusted.
[0134] In an optional embodiment, the method further includes: in response to the fact that the number of components of at least one second scene component is greater than the number of components of multiple first scene components, determining, based on the selection order of the second scene components, a number of second scene components to be adjusted that are the same as the number of components of multiple first scene components from at least one second scene component.
[0135] In an optional embodiment, the step of expanding at least one second scene component to obtain an expanded second scene component includes: determining the result of subtracting the number of components of a plurality of first scene components from the number of components of at least one second scene component, and determining the subtraction result as the number of expanded components; and determining the same number of expanded second scene components from at least one second scene component as the number of expanded components.
[0136] In an optional embodiment, the step of expanding at least one second scene component to obtain an expanded second scene component includes: determining the component type of the expanded second scene component according to a preset rule; and generating the expanded second scene component based on the component type.
[0137] In an optional embodiment, the preset rules include: random rules; or according to the selection order of the first scene components and the number of component expansions, the corresponding component types of the expanded second scene components are generated based on the component types of the multiple first scene components; wherein, the number of component expansions is the result of subtracting the number of components of the multiple first scene components from the number of components of at least one second scene component.
[0138] In an optional embodiment, the above-mentioned component attribute parameters include at least one of the following: component rotation parameters, component appearance parameters, component size parameters, component interaction parameters, component motion parameters, and component physical parameters.
[0139] In an optional embodiment, the graphical user interface displays a combined editing control; the combined editing operation includes: triggering an operation on the combined editing control when multiple first scene components are selected.
[0140] In an optional embodiment, the step of determining at least one second scene component in response to the second selection operation includes: in response to a selection operation of a scene component in the game editing scene, determining the selected scene component and recording the selection order of the selected scene components; and in response to a trigger operation of a confirmation control displayed in the graphical user interface, determining the selected scene component as the second scene component.
[0141] In an optional embodiment, the method further includes: in response to the fact that the number of components of the selected scene component is greater than the number of components of the plurality of first scene components, controlling the display of prompt information in the graphical user interface, the prompt information being used to indicate that the number of components of the selected scene component is greater than the number of components of the plurality of first scene components.
[0142] Furthermore, the electronic device shown in Figure 6 also includes a bus 102 and a communication interface 103, with the processor 101, the communication interface 103, and the memory 100 connected via the bus 102.
[0143] The memory 100 may include high-speed random access memory (RAM) or non-volatile memory, such as at least one disk storage device. Communication between this system network element and at least one other network element is achieved through at least one communication interface 103 (which can be wired or wireless), such as the Internet, wide area network, local area network, or metropolitan area network. The bus 102 may be an ISA bus, PCI bus, or EISA bus, etc. The bus can be divided into address bus, data bus, control bus, etc. For ease of illustration, only a single bidirectional arrow is used in Figure 6, but this does not indicate that there is only one bus or one type of bus.
[0144] Processor 101 may be an integrated circuit chip with signal processing capabilities. In implementation, each step of the above method can be completed by the integrated logic circuitry in the hardware of processor 101 or by instructions in software form. The processor 101 may be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this disclosure. The general-purpose processor may be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of this disclosure can be directly manifested as execution by a hardware decoding processor, or execution by a combination of hardware and software modules in the decoding processor. The software module can reside in a readily available storage medium in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. This storage medium is located in memory 100, and processor 101 reads information from memory 100 and, in conjunction with its hardware, completes the steps of the method described in the foregoing embodiments.
[0145] This disclosure also provides a computer-readable storage medium storing computer-executable instructions. When these computer-executable instructions are invoked and executed by a processor, they cause the processor to implement the component editing method in the game described above. For specific implementation details, please refer to the method embodiments, which will not be repeated here.
[0146] Specifically, the process of the component editing method in the above game may include: displaying a graphical user interface by running the game program, the graphical user interface displaying a game editing scene, the game editing scene including multiple scene components, the scene components being components set in the game editing scene in response to editing operations; responding to a first selection operation for a scene component in the game editing scene, determining multiple first scene components selected in the game editing scene based on the first selection operation; responding to a combined editing operation for multiple first scene components, recording first arrangement information corresponding to the multiple first scene components, the first arrangement information including at least one of the following: the relative positional relationship between the multiple first scene components and the component attribute parameters corresponding to the multiple first scene components respectively; responding to a second selection operation, determining at least one second scene component; determining at least one second scene component to be adjusted based on the at least one second scene component; adjusting the at least one second scene component to be adjusted based on the first arrangement information, generating at least one target second scene component; controlling the display of at least one target second scene component, wherein the arrangement of the at least one target second scene component in the game editing scene is at least partially the same as the arrangement of the multiple first scene components.
[0147] The component editing method in the game described above can migrate the layout information of multiple scene components to a specified scene component, allowing players to quickly copy and generate scene components with the same layout. This not only saves time and effort in manual layout but also reduces human error. At the same time, the layout information automatically recorded by the system ensures the accurate position and attribute information of the copied scene components, improving the quality and consistency of component building.
[0148] In an optional embodiment, the step of determining at least one second scene component in response to the second selection operation includes at least one of the following: in response to a first selection operation on a scene component in the game editing scene, determining at least one second scene component from the scene components in the game editing scene based on the first selection operation; in response to a second selection operation on a scene component control in a component control window displayed in the graphical user interface, determining the selected scene component control from the component control window based on the second selection operation, and determining the scene component corresponding to the selected scene component control as the second scene component; wherein, the component control window includes multiple scene component controls, and the scene component controls are used to generate scene components corresponding to the scene component controls in the game editing scene in response to editing operations.
[0149] In an optional embodiment, the step of adjusting at least one second scene component to be adjusted based on the first arrangement information to generate at least one target second scene component includes: determining a first preset order of multiple first scene components and a second preset order of at least one second scene component to be adjusted; determining second arrangement information of at least one second scene component to be adjusted according to the first preset order, the second preset order and the first arrangement information; wherein the second arrangement information includes at least one of the following: the relative positional relationship between at least one second scene component to be adjusted, and the component attribute parameters corresponding to at least one second scene component to be adjusted; generating at least one target second scene component according to the second arrangement information and at least one second scene component to be adjusted.
[0150] In an optional embodiment, the step of determining at least one second scene component to be adjusted based on at least one second scene component includes at least one of the following: determining at least one second scene component as at least one second scene component to be adjusted; obtaining the component count of multiple first scene components, and generating a number of second scene components to be adjusted equal to the component count based on the component count and at least one second scene component, and determining the number of second scene components to be adjusted equal to the component count as at least one second scene component to be adjusted.
[0151] In an optional embodiment, the step of generating a number of second scene components to be adjusted equal to the number of components based on the number of components and at least one second scene component, and determining the number of second scene components to be adjusted equal to the number of components as at least one second scene component to be adjusted, includes: in response to the fact that the number of components of at least one second scene component is less than the number of components of multiple first scene components, expanding at least one second scene component to obtain expanded second scene components, and determining at least one second scene component and expanded second scene components as at least one second scene component to be adjusted; wherein, the total number of components of at least one second scene component and expanded second scene component is the same as the number of components of multiple first scene components; in response to the fact that the number of components of at least one second scene component is equal to the number of components of multiple first scene components, determining at least one second scene component as at least one second scene component to be adjusted.
[0152] In an optional embodiment, the first preset order includes a sorting number corresponding to each of the plurality of first scene components; wherein the sorting number corresponding to the first scene component matches the selection order of the first scene components or the sorting number corresponding to the first scene component is randomly determined; the second preset order includes a sorting number corresponding to each of the at least one second scene component to be adjusted; wherein the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component or the sorting number corresponding to the second scene component to be adjusted is randomly determined, or the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of at least one second scene component and the expansion order of the expanded second scene component.
[0153] In an optional embodiment, when the at least one second scene component to be adjusted includes at least one second scene component and an expanded second scene component, the sorting number corresponding to at least one second scene component in the at least one second scene component to be adjusted is less than the sorting number corresponding to the expanded second scene component.
[0154] In an optional embodiment, the step of determining the second arrangement information of at least one second scene component to be adjusted based on the first preset order, the second preset order, and the first arrangement information includes: determining the correspondence between the second scene component to be adjusted and the first scene component based on the sorting number corresponding to the first scene component in the first preset order and the sorting number corresponding to the second scene component to be adjusted in the second preset order; wherein, when there is a correspondence between the second scene component to be adjusted and the first scene component, the sorting number corresponding to the second scene component to be adjusted matches the sorting number corresponding to the first scene component; and determining the second arrangement information of at least one second scene component to be adjusted based on the correspondence and the first arrangement information.
[0155] In an optional embodiment, the step of determining the second arrangement information of at least one second scene component to be adjusted based on the correspondence and the first arrangement information includes: for each of the at least one second scene component to be adjusted, determining a target first scene component that has a corresponding relationship with the current second scene component to be adjusted, and configuring the first arrangement information corresponding to the target first scene component as the arrangement information corresponding to the current second scene component to be adjusted; and obtaining the second arrangement information corresponding to at least one second scene component to be adjusted based on the arrangement information corresponding to each of the at least one second scene component to be adjusted.
[0156] In an optional embodiment, the method further includes: in response to the fact that the number of components of at least one second scene component is greater than the number of components of multiple first scene components, determining, based on the selection order of the second scene components, a number of second scene components to be adjusted that are the same as the number of components of multiple first scene components from at least one second scene component.
[0157] In an optional embodiment, the step of expanding at least one second scene component to obtain an expanded second scene component includes: determining the result of subtracting the number of components of a plurality of first scene components from the number of components of at least one second scene component, and determining the subtraction result as the number of expanded components; and determining the same number of expanded second scene components from at least one second scene component as the number of expanded components.
[0158] In an optional embodiment, the step of expanding at least one second scene component to obtain an expanded second scene component includes: determining the component type of the expanded second scene component according to a preset rule; and generating the expanded second scene component based on the component type.
[0159] In an optional embodiment, the preset rules include: random rules; or according to the selection order of the first scene components and the number of component expansions, the corresponding component types of the expanded second scene components are generated based on the component types of the multiple first scene components; wherein, the number of component expansions is the result of subtracting the number of components of the multiple first scene components from the number of components of at least one second scene component.
[0160] In an optional embodiment, the above-mentioned component attribute parameters include at least one of the following: component rotation parameters, component appearance parameters, component size parameters, component interaction parameters, component motion parameters, and component physical parameters.
[0161] In an optional embodiment, the graphical user interface displays a combined editing control; the combined editing operation includes: triggering an operation on the combined editing control when multiple first scene components are selected.
[0162] In an optional embodiment, the step of determining at least one second scene component in response to the second selection operation includes: in response to a selection operation of a scene component in the game editing scene, determining the selected scene component and recording the selection order of the selected scene components; and in response to a trigger operation of a confirmation control displayed in the graphical user interface, determining the selected scene component as the second scene component.
[0163] In an optional embodiment, the method further includes: in response to the fact that the number of components of the selected scene component is greater than the number of components of the plurality of first scene components, controlling the display of prompt information in the graphical user interface, the prompt information being used to indicate that the number of components of the selected scene component is greater than the number of components of the plurality of first scene components.
[0164] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this disclosure, or the part that contributes to related technologies, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, terminal device, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this disclosure. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0165] In the description of this disclosure, it should be noted that the terms "center," "upper," "lower," "left," "right," "vertical," "horizontal," "inner," and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, and are only for the convenience of describing this disclosure and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this disclosure. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and should not be construed as indicating or implying relative importance.
[0166] Finally, it should be noted that the above-described embodiments are merely specific implementations of this disclosure, used to illustrate the technical solutions of this disclosure, and not to limit it. The protection scope of this disclosure is not limited thereto. Although this disclosure has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments, or make equivalent substitutions for some of the technical features, within the scope of the technology disclosed in this disclosure. Such modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this disclosure, and should all be covered within the protection scope of this disclosure. Therefore, the protection scope of this disclosure should be determined by the protection scope of the claims.
Claims
1. A method for editing components in a game, the method comprising: A graphical user interface is displayed by running the game program. The graphical user interface displays a game editing scene, which includes multiple scene components. The scene components are components set in the game editing scene in response to editing operations. In response to a first selection operation for a scene component in the game editing scene, a plurality of first scene components selected in the game editing scene are determined based on the first selection operation; In response to the combined editing operation of the plurality of first scene components, the first arrangement information corresponding to the plurality of first scene components is recorded. The first arrangement information includes at least one of the following: the relative positional relationship between the plurality of first scene components and the component attribute parameters corresponding to the plurality of first scene components respectively. In response to the second selection operation, at least one second scene component is determined; Based on the at least one second scene component, at least one second scene component to be adjusted is determined; Based on the first arrangement information, adjust the at least one second scene component to be adjusted to generate at least one target second scene component; The control displays the at least one target second scene component, wherein the arrangement of the at least one target second scene component in the game editing scene is at least partially the same as the arrangement of the plurality of first scene components.
2. The method according to claim 1, wherein, The step of determining at least one second scene component in response to the second selection operation includes at least one of the following: In response to a first selection operation for a scene component in the game editing scene, at least one second scene component is determined from the scene components in the game editing scene based on the first selection operation; In response to a second selection operation on a scene component control in a component control window displayed in the graphical user interface, the selected scene component control is determined from the component control window based on the second selection operation, and the scene component corresponding to the selected scene component control is determined as the second scene component; wherein, the component control window includes multiple scene component controls, and the scene component controls are used to generate a scene component corresponding to the scene component control in the game editing scene in response to an editing operation.
3. The method according to claim 1, wherein, The step of adjusting the at least one second scene component to be adjusted based on the first arrangement information to generate at least one target second scene component includes: Determine a first preset order of the plurality of first scene components and a second preset order of the at least one second scene component to be adjusted; The second arrangement information of the at least one second scene component to be adjusted is determined according to the first preset order, the second preset order, and the first arrangement information; wherein, the second arrangement information includes at least one of the following: the relative positional relationship between the at least one second scene component to be adjusted, and the component attribute parameters corresponding to the at least one second scene component to be adjusted; The at least one target second scene component is generated based on the second layout information and the at least one second scene component to be adjusted.
4. The method according to claim 3, wherein, The step of determining at least one second scene component to be adjusted based on the at least one second scene component includes at least one of the following: The at least one second scene component is identified as the at least one second scene component to be adjusted; Obtain the number of components of the plurality of first scene components, and generate a number of second scene components to be adjusted that are the same as the number of components based on the number of components and the at least one second scene component. The number of second scene components to be adjusted that are the same as the number of components is determined as the at least one second scene component to be adjusted.
5. The method according to claim 4, wherein, The step of generating a number of second scene components to be adjusted equal to the number of components based on the number of components and the at least one second scene component, and determining the number of second scene components to be adjusted equal to the number of components as the at least one second scene component to be adjusted, includes: In response to the fact that the number of components of the at least one second scene component is less than the number of components of the plurality of first scene components, the at least one second scene component is expanded to obtain an expanded second scene component, and the at least one second scene component and the expanded second scene component are determined as the at least one second scene component to be adjusted; wherein, the total number of components of the at least one second scene component and the expanded second scene component is the same as the number of components of the plurality of first scene components; In response to the fact that the number of components of the at least one second scene component is equal to the number of components of the plurality of first scene components, the at least one second scene component is determined as the at least one second scene component to be adjusted.
6. The method according to claim 5, wherein, The first preset order includes the sorting number corresponding to each of the plurality of first scene components; wherein, the sorting number corresponding to the first scene component matches the selection order of the first scene components or the sorting number corresponding to the first scene component is randomly determined; The second preset order includes the sorting number corresponding to each of the at least one second scene components to be adjusted; wherein, the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of the at least one second scene component or the sorting number corresponding to the second scene component to be adjusted is randomly determined, or the sorting number corresponding to the second scene component to be adjusted is determined based on the selection order of the at least one second scene component and the expansion order of the expanded second scene component.
7. The method according to claim 6, wherein, When the at least one second scene component to be adjusted includes the at least one second scene component and the expanded second scene component, the sorting number corresponding to the at least one second scene component to be adjusted is less than the sorting number corresponding to the expanded second scene component.
8. The method according to claim 6, wherein, The step of determining the second arrangement information of the at least one second scene component to be adjusted according to the first preset order, the second preset order, and the first arrangement information includes: Based on the sorting number corresponding to the first scene component in the first preset order and the sorting number corresponding to the second scene component to be adjusted in the second preset order, the correspondence between the second scene component to be adjusted and the first scene component is determined; wherein, when there is a correspondence between the second scene component to be adjusted and the first scene component, the sorting number corresponding to the second scene component to be adjusted matches the sorting number corresponding to the first scene component. Based on the correspondence and the first arrangement information, the second arrangement information of the at least one second scene component to be adjusted is determined.
9. The method according to claim 8, wherein, The step of determining the second arrangement information of the at least one second scene component to be adjusted based on the correspondence and the first arrangement information includes: For each of the at least one second scene component to be adjusted, a target first scene component that corresponds to the current second scene component to be adjusted is determined, and the first arrangement information corresponding to the target first scene component is configured as the arrangement information corresponding to the current second scene component to be adjusted. Based on the arrangement information corresponding to each of the at least one second scene components to be adjusted, the second arrangement information corresponding to the at least one second scene component to be adjusted is obtained.
10. The method according to claim 5, wherein, The method further includes: In response to the fact that the number of components of the at least one second scene component is greater than the number of components of the plurality of first scene components, based on the selection order of the second scene components, a number of second scene components to be adjusted, which are the same as the number of components of the plurality of first scene components, are determined from the at least one second scene component.
11. The method according to claim 5, wherein, The step of expanding the at least one second scene component to obtain an expanded second scene component includes: The number of components in the plurality of first scene components is subtracted from the number of components in the at least one second scene component, and the result of the subtraction is determined as the number of component expansions; Determine an expanded second scene component from the at least one second scene component, the same number as the number of expanded components.
12. The method according to claim 5, wherein, The step of expanding the at least one second scene component to obtain an expanded second scene component includes: Based on preset rules, determine the component types for expanding the second scene components; Based on the component type, the extended second scene component is generated.
13. The method according to claim 12, wherein, The preset rules include: random rules; or according to the selection order of the first scene components and the number of component expansions, the corresponding component types of the expanded second scene components are generated based on the component types of the plurality of first scene components; wherein, the number of component expansions is the result of subtracting the number of components of the plurality of first scene components from the number of components of the at least one second scene component.
14. The method according to any one of claims 1-13, wherein, The component attribute parameters include at least one of the following: component rotation parameters, component appearance parameters, component size parameters, component interaction parameters, component motion parameters, and component physical parameters.
15. The method according to claim 1, wherein, The graphical user interface displays a combined editing control; the combined editing operation includes: triggering an operation on the combined editing control when the plurality of first scene components are selected.
16. The method according to claim 1, wherein, The step of determining at least one second scene component in response to a second selection operation includes: In response to a selection operation of a scene component in the game editing scene, the selected scene component is determined and the selection order of the selected scene components is recorded; In response to a trigger operation on a confirmation control displayed in the graphical user interface, the selected scene component is identified as the second scene component.
17. The method according to claim 16, wherein, The method further includes: In response to the fact that the number of components of the selected scene component is greater than the number of components of the plurality of first scene components, a prompt message is displayed in the graphical user interface, the prompt message indicating that the number of components of the selected scene component is greater than the number of components of the plurality of first scene components.
18. A component editing device for a game, the device comprising: The interface display module is configured to display a graphical user interface by running a game program. The graphical user interface displays a game editing scene, which includes multiple scene components. The scene components are components set in the game editing scene in response to editing operations. The first component selection module is configured to perform a first selection operation in response to a scene component in the game editing scene, and to determine a plurality of first scene components selected in the game editing scene based on the first selection operation; The combined editing module is configured to perform combined editing operations in response to the plurality of first scene components, and record the first arrangement information corresponding to the plurality of first scene components. The first arrangement information includes at least one of the following: the relative positional relationship between the plurality of first scene components and the component attribute parameters corresponding to the plurality of first scene components respectively. The second component selection module is configured to perform a second selection operation to determine at least one second scene component. The component determination module is configured to perform the function of determining at least one second scene component to be adjusted based on the at least one second scene component; The component adjustment module is configured to adjust the at least one second scene component to be adjusted based on the first arrangement information, and generate at least one target second scene component; The component layout display module is configured to control the display of at least one target second scene component, wherein the layout of the at least one target second scene component in the game editing scene is at least partially the same as the layout of the plurality of first scene components.
19. An electronic device comprising a processor and a memory, the memory storing machine-executable instructions executable by the processor, the processor executing the machine-executable instructions to implement the component editing method in a game according to any one of claims 1 to 17.
20. A computer-readable storage medium storing computer-executable instructions, which, when invoked and executed by a processor, cause the processor to implement the component editing method in a game according to any one of claims 1 to 17.
Citation Information
Patent Citations
Component generation method and device in game scene, storage medium and electronic equipment
CN116672719A
Component editing method and device in game, storage medium and electronic equipment
CN116966589A
Interaction control method and device in game and electronic equipment
CN117101123A
Editing method and device for scene component in game, electronic equipment and medium
CN117414584A
User interface configuration method and device, equipment and medium
CN117732083A