Processing method, device, equipment, medium and program product in virtual scene

By displaying a crosshair on a virtual weapon and automatically adjusting its firing direction to attach it to the skeletal binding area of ​​a second virtual object, the problem of the virtual weapon's crosshair failing to accurately indicate the target is solved, improving the efficiency and hit rate of human-computer interaction in virtual scenes.

CN116764196BActive Publication Date: 2026-07-21TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
TENCENT TECHNOLOGY (SHENZHEN) CO LTD
Filing Date
2022-03-09
Publication Date
2026-07-21

Smart Images

  • Figure CN116764196B_ABST
    Figure CN116764196B_ABST
Patent Text Reader

Abstract

The application provides a processing method and device in a virtual scene, electronic equipment, a computer readable storage medium and a computer program product; the method comprises: displaying a virtual scene; in response to triggering an operation of a first virtual object holding a virtual weapon, controlling the first virtual object to hold the virtual weapon, and displaying a sight of the virtual weapon in the virtual scene; in response to the sight moving from outside a first adsorption area to inside the first adsorption area, automatically adjusting a shooting direction of the virtual weapon, so that the sight of the virtual weapon is automatically adsorbed onto a second adsorption area in a second virtual object; wherein the first adsorption area is an area surrounding the second virtual object, and the second adsorption area is bound to the second virtual object along a direction penetrating at least part of a skeleton of the second virtual object. Through the application, the efficiency of human-computer interaction in the virtual scene can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to computer human-computer interaction technology, and more particularly to a processing method, device, electronic device, computer-readable storage medium, and computer program product in a virtual scene. Background Technology

[0002] Display technologies based on graphics processing hardware have expanded the channels for perceiving the environment and acquiring information. In particular, virtual scene display technologies can realize diverse interactions between virtual objects controlled by users or artificial intelligence according to actual application needs. They have various typical application scenarios. For example, in virtual scenes such as games, they can simulate the real battle process between virtual objects.

[0003] With the popularization of information technology, electronic devices can realize richer and more vivid virtual scenes, typically in games. More and more users are participating in virtual scene interactions through electronic devices, for example, quickly participating in virtual scene battles through virtual weapons held by virtual objects in games.

[0004] However, when the related technology is based on holding a virtual weapon to shoot at the enemy, the crosshair on the virtual weapon cannot accurately assist in indicating the target that the virtual weapon needs to shoot, and it is easy to deviate from the target, thus affecting the efficiency of human-computer interaction in the virtual scene and wasting a lot of communication and computing resources. Summary of the Invention

[0005] This application provides a processing method, apparatus, electronic device, computer-readable storage medium, and computer program product for virtual scenes, which can improve the efficiency of human-computer interaction in virtual scenes.

[0006] The technical solution of this application embodiment is implemented as follows:

[0007] This application provides a processing method in a virtual scene, including:

[0008] Displaying a virtual scene, wherein the virtual scene includes a first virtual object and a second virtual object;

[0009] In response to triggering the operation of the first virtual object holding a virtual weapon, the system controls the first virtual object to hold the virtual weapon and displays the crosshair of the virtual weapon in the virtual scene;

[0010] The crosshair corresponds to the firing direction of the virtual weapon and is used to indicate the landing point of the projectile of the virtual weapon in the virtual scene;

[0011] In response to the crosshair moving from outside the first adsorption area to inside the first adsorption area, the firing direction of the virtual weapon is automatically adjusted so that the crosshair of the virtual weapon automatically adsorbs onto the second adsorption area in the second virtual object;

[0012] The first adsorption region is the region surrounding the second virtual object, and the second adsorption region is attached to the second virtual object along a direction that runs through at least a portion of the skeleton of the second virtual object.

[0013] This application provides a processing device for a virtual scene, including:

[0014] A first display module is used to display a virtual scene, wherein the virtual scene includes a first virtual object and a second virtual object;

[0015] The second display module is used to respond to the operation of triggering the first virtual object to hold the virtual weapon, control the first virtual object to hold the virtual weapon, and display the crosshair of the virtual weapon in the virtual scene;

[0016] The crosshair corresponds to the firing direction of the virtual weapon and is used to indicate the landing point of the projectile of the virtual weapon in the virtual scene;

[0017] The third display module is used to automatically adjust the firing direction of the virtual weapon in response to the crosshair moving from the outside of the first adsorption area to the inside of the first adsorption area, so that the crosshair of the virtual weapon automatically adsorbs onto the second adsorption area in the second virtual object;

[0018] The first adsorption region is the region surrounding the second virtual object, and the second adsorption region is attached to the second virtual object along a direction that runs through at least a portion of the skeleton of the second virtual object.

[0019] In the above technical solution, the type of the second adsorption region includes:

[0020] A line segment passing through the head skeleton of the second virtual object, a line segment passing through the torso skeleton of the second virtual object, a bounding box surrounding the head skeleton of the second virtual object, and a bounding box surrounding the torso skeleton of the second virtual object.

[0021] In the above technical solution, the direction through at least a portion of the bones of the second virtual object is the direction from the center point of the at least a portion of the bones to the critical point, and the critical point is the center point of the connection line between the at least a portion of the bones and the adjacent bones.

[0022] In the above technical solution, when there are multiple second adsorption areas, the third display module is also used to automatically adjust the firing direction of the virtual weapon so that the crosshair of the virtual weapon automatically adsorbs onto the target adsorption area closest to the crosshair;

[0023] The target adsorption region is a second adsorption region among multiple second adsorption regions, including the adsorption point closest to the reticle.

[0024] In the above technical solution, the adsorption points in the second adsorption region are determined according to the priority order of the candidate adsorption points in the second adsorption region from high to low, so that the aiming point is automatically adsorbed onto the adsorption points in the second adsorption region.

[0025] The priority order of the candidate adsorption points from high to low is as follows: the intersection of the second adsorption region and the horizontal line of the collimator, the intersection of the second adsorption region and the vertical line of the collimator, the point on the second adsorption region closest to the collimator, and the vertex on the second adsorption region closest to the collimator.

[0026] In the above technical solution, the third display module is also used to display multiple candidate types of the second adsorption region;

[0027] In response to the selection operation for the candidate type, the selected candidate type is taken as the type of the second adsorption region.

[0028] In the above technical solution, when the object parameter of the first virtual object is greater than the object parameter threshold, the type of the second adsorption region is determined to be a bounding box;

[0029] The object parameters include at least one of the following types: the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

[0030] In the above technical solution, the third display module is further used to call a type prediction model based on the scene data of the virtual scene, the virtual weapon, and the second virtual object to perform type prediction processing and obtain the type of the second adsorption region;

[0031] The type prediction model is trained using historical scene data, historical virtual weapons, historical targets being shot at, and corresponding historical type annotations.

[0032] In the above technical solution, the third display module is also used to display the second adsorption area bound to the second virtual object;

[0033] In response to the size adjustment operation for the second adsorption region, the size of the second adsorption region is adjusted based on the target size set by the size adjustment operation, and the adjusted second adsorption region is hidden.

[0034] In the above technical solution, before displaying the second adsorption area bound to the second virtual object, the third display module is further used to obtain the object parameters of the first virtual object;

[0035] When the object parameter is less than the object parameter threshold, the process of displaying the second adsorption region bound to the second virtual object is initiated.

[0036] The object parameters include at least one of the following types: the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

[0037] In the above technical solution, before displaying the second adsorption area bound to the second virtual object, the third display module is further used to obtain the associated information bound to the second virtual object in the virtual scene;

[0038] The parameters of the display style of the associated information include at least one of the following: color, shape, and output format;

[0039] When the association information of the second virtual object meets the following triggering conditions, the operation of displaying the second adsorption area bound to the second virtual object is triggered:

[0040] The number of associated information is greater than the quantity threshold;

[0041] The area of ​​the associated information is greater than the area threshold;

[0042] The difference between the color of the associated information and the color set in the second adsorption region is greater than the color difference threshold.

[0043] The area of ​​the second adsorption region that obscures the associated information is less than the area threshold.

[0044] In the above technical solution, before the display is bound to the second adsorption area on the second virtual object, the third display module is further used to perform display timing prediction processing based on the scene data of the virtual scene and the second virtual object by calling the display timing prediction model, so as to obtain a prediction result of whether the second adsorption area on the second virtual object needs to be displayed;

[0045] The display timing prediction model is trained using historical scene data, historically shot virtual objects, and corresponding historical adsorption areas with display timing annotations.

[0046] When the prediction result indicates that the second adsorption region needs to be displayed, the process of displaying the second adsorption region bound to the second virtual object is initiated.

[0047] In the above technical solution, the triggering condition for the hidden and adjusted second adsorption region includes at least one of the following:

[0048] Display a close control for the second adsorption area, and receive a trigger operation for the close control;

[0049] No shooting operation was received against the second virtual object within the set time period;

[0050] A firing command was received targeting the second virtual object.

[0051] In the above technical solution, the size adjustment operation includes a selection operation; the third display module is also used to display multiple candidate sizes of the second adsorption region;

[0052] In response to the selection operation for the candidate size, the size of the second adsorption region is adjusted based on the selected candidate size.

[0053] In the above technical solution, the size of the first adsorption area is positively correlated with the shooting difficulty parameter of the first virtual object, or negatively correlated with the object parameter of the first virtual object;

[0054] The shooting difficulty parameter includes at least one of the following: the size of the second virtual object, and the distance between the second virtual object and the virtual weapon;

[0055] The object parameters include at least one of the following types: the shooting hit rate of the virtual weapon held by the first virtual object, the shooting accuracy of the virtual weapon held by the first virtual object, the level of the first virtual object, the historical kill count of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

[0056] In the above technical solution, the third display module is also used to display the first adsorption area;

[0057] In response to the size adjustment operation for the first adsorption region, the size of the first adsorption region is adjusted based on the target size set by the size adjustment operation, and the adjusted first adsorption region is hidden.

[0058] In the above technical solution, the third display module is also used to emit a detection ray from the firing port of the virtual weapon that is consistent with the firing direction, and the crosshair is the endpoint of the detection ray;

[0059] When the detection ray intersects with the first adsorption region, it is determined that the collimator has moved from the outside of the first adsorption region to the inside of the first adsorption region.

[0060] In the above technical solution, before the crosshair moves from the outside of the first adsorption area to the inside of the first adsorption area, the third display module is further configured to adjust the firing direction of the virtual weapon in response to an adjustment operation on the firing direction of the virtual weapon, so that the crosshair of the virtual weapon moves from the outside of the first adsorption area to the inside of the first adsorption area; or,

[0061] In response to the virtual weapon's firing direction remaining unchanged and the second virtual object moving in the firing direction, the aiming point of the virtual weapon is controlled to move from outside the first adsorption area to inside the first adsorption area.

[0062] This application provides an electronic device, the electronic device comprising:

[0063] Memory, used to store executable instructions;

[0064] The processor, when executing executable instructions stored in the memory, implements the processing method in the virtual scene provided in the embodiments of this application.

[0065] This application provides a computer-readable storage medium storing executable instructions for inducing a processor to execute and implement the processing method in the virtual scene provided in this application.

[0066] This application provides a computer program product, including a computer program or instructions, characterized in that the computer program or instructions, when executed by a processor, implement the processing method in the virtual scene provided in this application embodiment.

[0067] The embodiments of this application have the following beneficial effects:

[0068] By adjusting the firing direction of the virtual weapon, the crosshair of the virtual weapon is automatically attached to the second attachment area in the second virtual object. Since the second attachment area is along the direction that runs through at least part of the skeleton of the second virtual object and is bound to the second virtual object, accurate crosshair attachment is achieved to precisely assist the firing operation of the virtual weapon, thereby improving the efficiency of human-computer interaction in the virtual scene and saving related communication and computing resources. Attached Figure Description

[0069] Figures 1A-1C This is a schematic diagram of the central axis provided in an embodiment of this application;

[0070] Figures 2A-2B This is a schematic diagram illustrating the application mode of the processing method in the virtual scene provided in the embodiments of this application;

[0071] Figure 3 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application;

[0072] Figures 4A-4B This is a flowchart illustrating the processing method in a virtual scene provided in the embodiments of this application;

[0073] Figure 5 This is a schematic diagram of the adsorption line provided in the embodiments of this application;

[0074] Figures 6A-6B This is a schematic diagram of the adsorption line provided in the embodiments of this application;

[0075] Figures 7-8 This is a schematic diagram of the rectangular frame provided in an embodiment of this application;

[0076] Figure 9 This is a schematic diagram of the nearest rectangular frame provided in the embodiments of this application;

[0077] Figure 10 This is a schematic diagram of the adsorption points provided in the embodiments of this application;

[0078] Figure 11 This is a flowchart illustrating the processing method in a virtual scene provided in the embodiments of this application;

[0079] Figure 12 This is a schematic diagram of the adsorption region provided in the embodiments of this application;

[0080] Figures 13-14 This is a schematic diagram of the target adsorption point provided in the embodiments of this application. Detailed Implementation

[0081] To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings. The described embodiments should not be regarded as limitations on this application. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0082] In the following description, the terms "first" and "second" are used merely to distinguish similar objects and do not represent a specific ordering of objects. It is understood that "first" and "second" may be interchanged in a specific order or sequence where permitted, so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.

[0083] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.

[0084] Before providing a further detailed description of the embodiments of this application, the nouns and terms involved in the embodiments of this application will be explained, and the nouns and terms involved in the embodiments of this application shall be interpreted as follows.

[0085] 1) Responding to: used to indicate the conditions or states on which the operation is performed depends. When the conditions or states on which it depends are met, one or more operations can be performed in real time or with a set delay. Unless otherwise specified, there is no restriction on the order in which the multiple operations are performed.

[0086] 2) Client: An application running on a terminal that provides various services, such as a video playback client, a game client, etc.

[0087] 3) Virtual Scene: A virtual game scene displayed (or provided) when the game program runs on the terminal. This virtual scene can be a simulation of the real world, a semi-simulated / semi-fictional virtual environment, or a purely fictional virtual environment. The virtual scene can be any of a two-dimensional, 2.5-dimensional, or three-dimensional virtual scene; this application does not limit the dimension of the virtual scene. For example, a virtual scene may include the sky, land, ocean, etc., and the land may include environmental elements such as deserts and cities. Users can control virtual objects to move within this virtual scene.

[0088] 4) Virtual Objects: These are interactive images of people and objects within a virtual scene, or movable objects within the virtual scene. These movable objects can be virtual characters, virtual animals, anime characters, etc., such as people or animals displayed in a virtual scene. A virtual object can be a virtual character representing the user within the virtual scene. A virtual scene can include multiple virtual objects, each with its own shape and volume, occupying a portion of the space within the virtual scene.

[0089] 5) Scene data: This represents the characteristic data of the virtual scene, such as the area of ​​the construction area in the virtual scene, the current architectural style of the virtual scene, etc.; it can also include the location of the virtual building in the virtual scene, and the area occupied by the virtual building, etc.

[0090] 6) Shooting games: including first-person shooter games, third-person shooter games, etc., including but not limited to all games that use firearms for ranged attacks.

[0091] In shooting games, the endpoint of the crosshair attachment in the relevant technology is any point on the central axis of the virtual character (the vertical line where the center of the virtual character's body is located). However, the central axis will only coincide with the virtual character's head when facing the virtual character directly. When the virtual character changes its position (such as standing, crouching, lying down, or turning to the side), the central axis will not coincide with the virtual character's head. Therefore, due to the fact that the central axis does not coincide with the virtual character's head, under the influence of the attachment effect, it becomes more difficult to aim at the virtual character's head and shoot, even though it was originally possible to aim for the head.

[0092] Since the endpoint of the crosshair's attraction is a point on the central axis of the virtual character, and due to the varying postures of virtual characters, abnormal attraction points often occur, such as... Figure 1A As shown, when the virtual character is standing sideways, the central axis 101 does not coincide with the head 102 of the virtual character; as Figure 1B As shown, when the virtual character is crouching sideways, the central axis 103 does not coincide with the virtual character's head 104. Only when facing the virtual character directly will the central axis coincide with the virtual character's head, as shown below. Figure 1C As shown, the central axis 105 will coincide with the head 106 of the virtual character when facing the virtual character directly.

[0093] To address the issue of non-coincidence of adsorption endpoints due to the aforementioned morphological changes, embodiments of this application provide a processing method, apparatus, electronic device, computer-readable storage medium, and computer program product for virtual scenes, which can improve the efficiency of human-computer interaction in virtual scenes. To facilitate a clearer understanding of the processing method for virtual scenes provided in this application, exemplary implementation scenarios of the processing method for virtual scenes provided in this application are first described. The virtual scene in the processing method for virtual scenes provided in this application can be entirely based on terminal output, or based on collaborative output from a terminal and a server.

[0094] In some embodiments, the virtual scene can be an environment for game characters to interact, such as a virtual scene for game characters to fight each other. By controlling the actions of the game characters, the two sides can interact in the virtual scene, thereby allowing users to relieve life stress during the game.

[0095] In one implementation scenario, see Figure 2A , Figure 2AThis is a schematic diagram of the application mode of the processing method in the virtual scene provided in the embodiment of this application. It is applicable to some application modes that can complete the relevant data calculation of the virtual scene 100 by relying entirely on the graphics processing hardware computing power of the terminal 400, such as stand-alone / offline mode games, and the output of the virtual scene is completed through various types of terminals 400 such as smartphones, tablets and virtual reality / augmented reality devices.

[0096] As an example, types of graphics processing hardware include central processing units (CPUs) and graphics processing units (GPUs).

[0097] When visual perception of virtual scene 100 is formed, terminal 400 calculates the data required for display through graphics computing hardware, and completes the loading, parsing and rendering of display data. The graphics output hardware outputs video frames that can form visual perception of virtual scene. For example, two-dimensional video frames are presented on the display screen of a smartphone, or video frames that achieve three-dimensional display effect are projected on the lenses of augmented reality / virtual reality glasses. In addition, in order to enrich the perception effect, terminal 400 can also use different hardware to form one or more of auditory perception, tactile perception, motion perception and taste perception.

[0098] As an example, a client 410 (e.g., a standalone game application) runs on terminal 400. During the operation of client 410, it outputs a virtual scene for role-playing. The virtual scene can be an environment for game characters to interact with, such as a plain, street, valley, etc., for game characters to fight. Taking the virtual scene 100 displayed in a first-person perspective as an example, the virtual scene 100 displays a first virtual object 110, a virtual weapon 120 equipped by the first virtual object 110, and a second virtual object 130. The first virtual object 110 can be a game character controlled by the user (or player), that is, the first virtual object 110 is controlled by the real user and will respond to the real user's button presses (including joystick presses). The virtual object 110 can be operated in a virtual scene by controlling buttons such as the joystick (attack button, defense button, etc.). For example, when the real user moves the joystick to the left, the first virtual object will move to the left in the virtual scene. It can also stay still, jump, and use various functions (such as skills and items). The virtual weapon 120 is controlled by the first virtual object 110 and will be operated in the virtual scene in response to the operation of the first virtual object 110, thereby realizing game combat by controlling the virtual weapon. The second virtual object 130 can be a game character controlled by the user (or enemy player), that is, the second virtual object 130 is controlled by the real user. The second virtual object 130 can also be a non-user character (NPC, Non-Player Character) in the virtual scene interaction.

[0099] For example, in a virtual scene 100, a first virtual object 110 holds a virtual weapon 120. When the virtual weapon moves within the virtual scene 100, the crosshair 140 of the virtual weapon 120 moves from outside the first adsorption area surrounding the second virtual object 130 to inside the first adsorption area, automatically adjusting the firing direction of the virtual weapon 120 so that the crosshair 140 of the virtual weapon 120 automatically adsorbs onto the second adsorption area 150 in the second virtual object 130. This achieves accurate crosshair adsorption, precisely assisting in the firing operation of the virtual weapon and improving the efficiency of human-computer interaction in the virtual scene.

[0100] In another implementation scenario, see Figure 2B , Figure 2B This is a schematic diagram of the application mode of the processing method in the virtual scene provided in the embodiment of this application. It is applied to the terminal 400 and the server 200 and is suitable for the application mode that relies on the computing power of the server 200 to complete the virtual scene calculation and output the virtual scene on the terminal 400.

[0101] Taking the visual perception of virtual scene 100 as an example, server 200 calculates display data related to the virtual scene (such as scene data) and sends it to terminal 400 via network 300. Terminal 400 relies on graphics computing hardware to load, parse, and render the calculated display data, and relies on graphics output hardware to output the virtual scene to form visual perception. For example, two-dimensional video frames can be displayed on the screen of a smartphone, or video frames with a three-dimensional display effect can be projected onto the lenses of augmented reality / virtual reality glasses. As for the perception of the form of the virtual scene, it can be understood that it can be achieved with the help of the corresponding hardware output of terminal 400, such as using a microphone to form auditory perception, using a vibrator to form tactile perception, and so on.

[0102] As an example, a client 410 (e.g., a web-based game application) runs on terminal 400. It interacts with other users through a connection to server 200 (e.g., a game server). Terminal 400 outputs a virtual scene 100 from client 410. Taking a first-person perspective view of the virtual scene 100 as an example, the virtual scene 100 displays a first virtual object 110, a virtual weapon 120 equipped by the first virtual object 110, and a second virtual object 130. The first virtual object 110 can be a game character controlled by a user (or player), meaning it is controlled by the real user and responds to the real user's actions on buttons (including joystick buttons, attack buttons, defense buttons, etc.). In a virtual scene, for example, when a real user moves the joystick button to the left, the first virtual object will move to the left in the virtual scene. It can also remain stationary, jump, and use various functions (such as skills and items). The virtual weapon 120 is controlled by the first virtual object 110 and will respond to the operation of the first virtual object 110 in the virtual scene, thereby realizing game combat by controlling the virtual weapon. The second virtual object 130 can be a game character controlled by the user (or the enemy player), that is, the second virtual object 130 is controlled by the real user. The second virtual object 130 can also be a non-user character (NPC, Non-Player Character) in the virtual scene interaction.

[0103] For example, in a virtual scene 100, a first virtual object 110 holds a virtual weapon 120. When the virtual weapon moves within the virtual scene 100, the crosshair 140 of the virtual weapon 120 moves from outside the first adsorption area surrounding the second virtual object 130 to inside the first adsorption area, automatically adjusting the firing direction of the virtual weapon 120 so that the crosshair 140 of the virtual weapon 120 automatically adsorbs onto the second adsorption area 150 in the second virtual object 130. This achieves accurate crosshair adsorption, precisely assisting in the firing operation of the virtual weapon and improving the efficiency of human-computer interaction in the virtual scene.

[0104] In some embodiments, the terminal 400 can implement the processing method in the virtual scene provided in this application embodiment by running a computer program. For example, the computer program can be a native program or software module in the operating system; it can be a native application (APP), that is, a program that needs to be installed in the operating system to run, such as a battle game APP (i.e., the client 410 mentioned above); it can also be a mini-program, that is, a program that only needs to be downloaded to the browser environment to run; or it can be a game mini-program that can be embedded in any APP. In short, the above-mentioned computer program can be any form of application, module or plugin.

[0105] Taking a computer program as an example, in actual implementation, terminal 400 has an application that supports virtual scenes installed and running. This application can be any of the following: a first-person shooter (FPS) game, a third-person shooter game, a virtual reality application, a 3D map application, or a multiplayer shooting survival game. Users use terminal 400 to manipulate virtual objects located in the virtual scene, and these activities include, but are not limited to: adjusting body posture, crawling, walking, running, riding, jumping, driving, picking up items, shooting, attacking, throwing, and constructing virtual buildings—at least one of these. For illustrative purposes, the virtual object can be a virtual character, such as a realistic or anime character.

[0106] In some embodiments, the present application embodiments can also be implemented with the aid of cloud technology, which refers to a hosting technology that unifies a series of resources such as hardware, software, and networks within a wide area network or local area network to realize the computation, storage, processing, and sharing of data.

[0107] Cloud technology is a general term encompassing network technology, information technology, integration technology, management platform technology, and application technology based on the cloud computing business model. It can form resource pools, allowing for on-demand use with flexibility and convenience. Cloud computing technology will become a crucial support. The backend services of cloud computing systems require substantial computing and storage resources.

[0108] Example, Figure 2BThe server 200 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. The terminal 400 can be a smartphone, tablet, laptop, desktop computer, smart speaker, smartwatch, etc., but is not limited to these. The terminal 400 and server 200 can be directly or indirectly connected via wired or wireless communication, which is not limited in this embodiment.

[0109] See Figure 3 , Figure 3 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application. Taking the electronic device as terminal 400 as an example for explanation, Figure 3 The illustrated electronic device 400 includes at least one processor 420, a memory 460, at least one network interface 430, and a user interface 440. The various components in the terminal 400 are coupled together via a bus system 450. It is understood that the bus system 450 is used to implement communication between these components. In addition to a data bus, the bus system 450 also includes a power bus, a control bus, and a status signal bus. However, for clarity, in… Figure 3 The general labeled all buses as Bus System 450.

[0110] Processor 420 can be an integrated circuit chip with signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among them, the general-purpose processor can be a microprocessor or any conventional processor.

[0111] User interface 440 includes one or more output devices 441 that enable the presentation of media content, including one or more speakers and / or one or more visual displays. User interface 440 also includes one or more input devices 442, including user interface components that facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.

[0112] The memory 460 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state storage, hard disk drives, optical disk drives, etc. The memory 460 may optionally include one or more storage devices physically located away from the processor 420.

[0113] The memory 460 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), and the volatile memory may be random access memory (RAM). The memory 460 described in this application embodiment is intended to include any suitable type of memory.

[0114] In some embodiments, memory 460 is capable of storing data to support various operations, examples of which include programs, modules, and data structures or subsets or supersets thereof, as illustrated below.

[0115] Operating system 461 includes system programs for handling various basic system services and performing hardware-related tasks, such as the framework layer, core library layer, driver layer, etc., for implementing various basic business functions and handling hardware-based tasks;

[0116] The network communication module 462 is used to reach other computing devices via one or more (wired or wireless) network interfaces 430, exemplary network interfaces 430 including: Bluetooth, WiFi, and Universal Serial Bus (USB), etc.

[0117] Presentation module 463 is configured to enable the presentation of information (e.g., a user interface for operating peripheral devices and displaying content and information) via one or more output devices 441 (e.g., a display screen, a speaker, etc.) associated with user interface 440;

[0118] The input processing module 464 is used to detect and translate one or more user inputs or interactions from one or more input devices 442.

[0119] In some embodiments, the processing device in the virtual scene provided in this application can be implemented in software. Figure 3 A processing device 465 for a virtual scene stored in memory 460 is shown. This device can be software in the form of programs and plugins, including the following software modules: a first display module 4651, a second display module 4652, and a third display module 4653. These modules are logically connected and can therefore be arbitrarily combined or further separated according to the functions they implement. It should be noted that... Figure 3 For ease of explanation, all the above modules are shown at once. However, this should not be interpreted as the processing device 465 in the virtual scene excluding the implementation that may only include the first display module 4651, the second display module 4652, and the third display module 4653. The functions of each module will be described below.

[0120] In other embodiments, the processing device in the virtual scene provided in this application embodiment can be implemented in hardware. As an example, the processing device in the virtual scene provided in this application embodiment can be a processor in the form of a hardware decoding processor, which is programmed to execute the processing method in the virtual scene provided in this application embodiment. For example, the processor in the form of a hardware decoding processor can be one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), or other electronic components.

[0121] The processing method for virtual scenes provided in the embodiments of this application will be described in detail below with reference to the accompanying drawings. The processing method for virtual scenes provided in the embodiments of this application can be... Figure 2A Terminal 400 can be executed independently, or it can be... Figure 2B Terminal 400 and server 200 work together to execute.

[0122] Below, by Figure 2A The following description uses the example of terminal 400 executing the processing method in the virtual scene provided in this application embodiment. See also... Figure 4A , Figure 4A This is a flowchart illustrating the processing method in a virtual scene provided in the embodiments of this application, which will be combined with... Figure 4A The steps shown are explained.

[0123] It should be noted that, Figure 4A The method shown can be executed by various forms of computer programs running on terminal 400, and is not limited to the client 410 described above. It can also be the operating system 461, software modules and scripts mentioned above. Therefore, the client should not be regarded as a limitation on the embodiments of this application.

[0124] In step 101, a virtual scene is displayed, wherein the virtual scene includes a first virtual object and a second virtual object.

[0125] For example, a virtual scene includes at least two virtual objects. The diverse interactions between these virtual objects have various typical application scenarios, such as in virtual scenes like shooting games. Taking shooting games as an example, virtual objects can engage in combat through skills, virtual weapons, etc. In the embodiments of this application, the first virtual object can be a game character controlled by the user (or player), the second virtual object can be a game character controlled by the enemy, or it can be a non-user character (NPC, Non-Player Character) interacting in the virtual scene.

[0126] In step 102, in response to triggering the operation of the first virtual object holding the virtual weapon, the first virtual object is controlled to hold the virtual weapon, and the crosshair of the virtual weapon is displayed in the virtual scene, wherein the crosshair corresponds to the firing direction of the virtual weapon and is used to indicate the landing point of the projectile of the virtual weapon in the virtual scene.

[0127] For example, when a player controls a first virtual object holding a virtual weapon, the first virtual object holding the virtual weapon is displayed in the virtual scene, and the crosshair of the virtual weapon is also displayed in the virtual scene. This crosshair is used to indicate the landing point of the virtual weapon's projectiles (such as virtual bullets or virtual arrows) in the virtual scene to assist the player in shooting.

[0128] For example, when a player controls a first virtual object holding a virtual weapon, the first virtual object holding the virtual weapon is displayed in the virtual scene. When the player opens the scope of the virtual weapon, the crosshair of the virtual weapon is displayed in the virtual scene. This crosshair is used to indicate the landing point of the virtual weapon's projectiles (such as virtual bullets or virtual arrows) in the virtual scene to assist the player in aiming and shooting.

[0129] In step 103, in response to the crosshair moving from the outside of the first adsorption area to the inside of the first adsorption area, the firing direction of the virtual weapon is automatically adjusted so that the crosshair of the virtual weapon automatically adsorbs onto the second adsorption area in the second virtual object, wherein the first adsorption area is the area surrounding the second virtual object, and the second adsorption area is attached to the second virtual object along a direction that runs through at least part of the skeleton of the second virtual object.

[0130] For example, when the crosshair moves from the outside of the first adsorption area to the inside of the first adsorption area, the crosshair of the virtual weapon automatically adsorbs onto the second adsorption area in the second virtual object. Since the second adsorption area is along the direction that runs through at least part of the skeleton of the second virtual object and is bound to the second virtual object, accurate crosshair adsorption is achieved, which can accurately assist the shooting operation of the virtual weapon, improve the hit rate of the virtual weapon, and thus improve the efficiency of human-computer interaction in the virtual scene.

[0131] In some embodiments, the type of the second adsorption region includes: a line segment passing through the head skeleton of the second virtual object, a line segment passing through the torso skeleton of the second virtual object, a bounding box surrounding the head skeleton of the second virtual object, and a bounding box surrounding the torso skeleton of the second virtual object.

[0132] It should be noted that when the second snap-in area is a line segment, the crosshair can be accurately snapped to the second virtual object, achieving precise aiming and shooting without much operating space; when the second snap-in area is a bounding box, more operating space is reserved, thus allowing players to better control the crosshair and improve their aiming accuracy.

[0133] In some embodiments, the direction through at least a portion of the bones of the second virtual object is the direction from the center point of at least a portion of the bones to the critical point, where the critical point is the center point of the line connecting at least a portion of the bones to the adjacent bones.

[0134] For example, taking the second virtual object as a virtual character, as shown in Figure 6, when at least part of the skeleton is the head, the neck is taken as the center dividing line between the head and the body of the virtual character, and the direction from the center of the head to the center 601 of the neck (i.e., the adjacent bones of the partial skeleton) is taken as the direction through the at least part of the skeleton of the second virtual object, that is, the orientation of the head; when at least part of the skeleton is the torso, the direction from the center 601 of the neck (i.e., the adjacent bones of the partial skeleton) to the center of the torso (i.e., the at least part of the skeleton) is taken as the direction through the at least part of the skeleton of the second virtual object, that is, the orientation of the body.

[0135] In some embodiments, when there are multiple second adsorption areas, automatically adjusting the firing direction of the virtual weapon so that the crosshair of the virtual weapon is automatically adsorbed onto the second adsorption area in the second virtual object includes: automatically adjusting the firing direction of the virtual weapon so that the crosshair of the virtual weapon is automatically adsorbed onto the target adsorption area closest to the crosshair; wherein, the target adsorption area is a second adsorption area among multiple second adsorption areas that includes the adsorption point closest to the crosshair.

[0136] For example, when there are multiple second-adsorption regions, such as bounding boxes surrounding the head skeleton of the second virtual object and bounding boxes surrounding the torso skeleton of the second virtual object, during the aiming process, the head and torso of the second virtual object need to be identified in each frame. First, it is determined whether the crosshair is closer to the bounding box of the head or the bounding box of the torso, and then the nearest bounding box is selected for adsorption.

[0137] like Figure 9As shown, if the bounding box of the torso includes the closest adsorption point to the crosshair, then the bounding box of the torso is determined to be the target adsorption area closest to the crosshair, and the bounding box 901 of the torso is selected for adsorption.

[0138] In some embodiments, adsorption points in the second adsorption region are determined according to the priority order of candidate adsorption points in the second adsorption region from high to low, so that the crosshair is automatically adsorbed onto the adsorption points in the second adsorption region; wherein, the priority order of candidate adsorption points from high to low is as follows: the intersection of the horizontal line of the second adsorption region and the crosshair, the intersection of the vertical line of the second adsorption region and the crosshair, the point on the second adsorption region closest to the crosshair, and the vertex on the second adsorption region closest to the crosshair.

[0139] It should be noted that the adsorption point can be any of the following: the intersection of the second adsorption area and the horizontal line of the crosshair, the intersection of the second adsorption area and the vertical line of the crosshair, the point on the second adsorption area closest to the crosshair, or the vertex on the second adsorption area closest to the crosshair.

[0140] Of course, priorities can be set for the points on the second adsorption region. The adsorption points in the second adsorption region are determined according to their priority order from high to low, so that the crosshair automatically adsorbs onto the adsorption points in the second adsorption region. For example, when the horizontal line of the crosshair intersects with the second adsorption region, the intersection with the horizontal line is used as the adsorption point; when the horizontal line of the crosshair does not intersect with the second adsorption region, but the vertical line of the crosshair intersects with the second adsorption region, the intersection with the vertical line is used as the adsorption point; when the vertical line of the crosshair does not intersect with the second adsorption region, the point on the second adsorption region closest to the crosshair is used as the adsorption point; when the vertical line of the crosshair does not intersect with the second adsorption region, the vertex on the second adsorption region closest to the crosshair is used as the adsorption point.

[0141] In some embodiments, multiple candidate types of the second adsorption region are displayed; in response to a selection operation for a candidate type, the selected candidate type is used as the type of the second adsorption region.

[0142] It should be noted that the candidate types for the second adsorption region include: a line segment passing through the head skeleton of the second virtual object, a line segment passing through the torso skeleton of the second virtual object, a bounding box surrounding the head skeleton of the second virtual object, and a bounding box surrounding the torso skeleton of the second virtual object. By manually selecting the candidate type as the type of the second adsorption region, the player's preferred type can be selected to increase the stickiness of the virtual scene.

[0143] In some embodiments, when the object parameter of the first virtual object is greater than the object parameter threshold, the type of the second adsorption region is determined to be a bounding box; wherein, the type of the object parameter includes at least one of the following: the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

[0144] It's important to note that when the second attachment area is a line segment, the crosshair can accurately attach to the second virtual object, achieving precise aiming and shooting without requiring excessive maneuvering space. When the second attachment area is a bounding box, it retains ample maneuvering space, allowing players better control of the crosshair and improving aiming accuracy. Therefore, consider object parameters such as the hit rate of the virtual weapon held by the first virtual object, the remaining number of projectiles, the attack power, level, health, and win rate of the first virtual object. When these object parameters exceed a certain threshold, it indicates a high player skill level, and using a bounding box for attachment preserves ample maneuvering space, allowing for better crosshair control and improved aiming accuracy. Conversely, when these object parameters are less than or equal to the threshold, it indicates a lower player skill level, and using line segments for attachment, due to their more precise attachment points, achieves accurate aiming and shooting without requiring excessive maneuvering space.

[0145] In some embodiments, the type prediction model is invoked based on the scene data of the virtual scene, the virtual weapon, and the second virtual object to perform type prediction processing and obtain the type of the second adsorption region; wherein, the type prediction model is trained by historical scene data, historical virtual weapons, historical shot objects, and corresponding historical type annotations.

[0146] For example, the type of the second adsorption region can be automatically obtained through artificial intelligence. Based on the current virtual scene data (such as the distribution of virtual objects on both sides during the battle, the attributes of virtual objects (attack capability, movement speed, etc.), virtual weapons (such as the number of remaining projectiles, the lethality of projectiles, etc.), and the attributes of virtual props (including various performance parameters, such as kill radius), the outcome of the battle, etc.), and the second virtual object, a type prediction model is invoked to perform type prediction processing to obtain the type of the second adsorption region. The type prediction model is trained using historical scene data (such as the historical distribution of virtual objects on both sides during the battle, the historical attributes of virtual objects (historical attack capability, historical movement speed, etc.), historical virtual weapons (such as the historical number of remaining projectiles, the lethality of projectiles, etc.), historical targets being shot at, and corresponding historical type annotations).

[0147] See Figure 4B , Figure 4B This is an optional flowchart illustrating a processing method in a virtual scene provided in an embodiment of this application. Figure 4B It also includes steps 104-105: In step 105, the second adsorption region bound to the second virtual object is displayed; In step 105, in response to the size adjustment operation for the second adsorption region, the size of the second adsorption region is adjusted based on the target size set by the size adjustment operation, and the adjusted second adsorption region is hidden.

[0148] It should be noted that, to ensure players can clearly see the second adsorption area, it can be displayed in the virtual scene to assist players in manually controlling the crosshair to any position within the second adsorption area. Of course, to avoid the second adsorption area obstructing the player's view, it can also be hidden.

[0149] It should be noted that the size of the second adsorption area in this embodiment can be adjusted. Players can manually adjust the size of the second adsorption area to make the adjusted size of the second adsorption area conform to user preferences.

[0150] In some embodiments, before displaying the second adsorption region bound to the second virtual object, a size adjustment control for the second adsorption region is displayed; in response to a triggering operation on the size adjustment control, an operation to display the second adsorption region bound to the second virtual object is triggered.

[0151] For example, a second adsorption area bound to a second virtual object can be triggered by a size adjustment control, allowing for size adjustments to the displayed second adsorption area. Figure 5 As shown, clicking the size adjustment control 501 will display the second adsorption area 502 in the virtual scene.

[0152] In some embodiments, before displaying the second adsorption area bound to the second virtual object, the object parameters of the first virtual object are obtained; when the object parameters are less than the object parameter threshold, the process of displaying the second adsorption area bound to the second virtual object is initiated; wherein, the type of the object parameters includes at least one of the following: the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health points of the first virtual object, and the win rate of the first virtual object.

[0153] For example, embodiments of this application may consider object parameters such as the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health points of the first virtual object, and the win rate of the first virtual object. When these object parameters are greater than the object parameter threshold, it indicates that the player's skill level is relatively high, and there is no need to display the second adsorption area to assist in aiming. When these object parameters are less than the object parameter threshold, it indicates that the player's skill level is relatively low, and it is necessary to display the second adsorption area to assist in aiming, thereby triggering the display of the second adsorption area.

[0154] In some embodiments, before displaying the second adsorption area bound to the second virtual object, associated information bound to the second virtual object in the virtual scene is obtained; wherein, the display style parameters of the associated information include at least one of the following: color, shape, and output format; when the associated information of the second virtual object meets the following triggering conditions, the operation of displaying the second adsorption area bound to the second virtual object is triggered: the number of associated information is greater than a number threshold; the area of ​​the associated information is greater than an area threshold; the difference between the color of the associated information and the color set by the second adsorption area is greater than a color difference threshold; the area of ​​the associated information obscured by the second adsorption area is less than an area threshold.

[0155] It should be noted that the associated information is information related to the second virtual object, such as the second virtual object's health points, attack capabilities, etc., and the output format includes image format and audio format. When the display of the associated information of the second virtual object does not affect the display of the second adsorption area (e.g., the number of associated information is greater than the number threshold, the area of ​​associated information is greater than the area threshold, the difference between the color of the associated information and the color set by the second adsorption area is greater than the color difference threshold, and the area of ​​the second adsorption area that obscures the associated information is less than the area threshold), the second adsorption area is triggered to assist in aiming.

[0156] In some embodiments, before displaying the second adsorption region bound to the second virtual object, a display timing prediction process is performed based on scene data of the virtual scene and the second virtual object by calling a display timing prediction model to obtain a prediction result of whether the second adsorption region on the second virtual object needs to be displayed; wherein, the display timing prediction model is trained by historical scene data, historically shot virtual objects and corresponding historical display timing annotations of adsorption regions; when the prediction result indicates that the second adsorption region needs to be displayed, the process of displaying the second adsorption region bound to the second virtual object is initiated.

[0157] For example, artificial intelligence can be used to automatically obtain a prediction of whether the second adsorption region on the second virtual object needs to be displayed. Based on scene data of the current virtual scene (such as the distribution of virtual objects on both sides during combat, the attributes of virtual objects (attack capabilities, movement speed, etc.), and the timing prediction model of the second virtual object, a type prediction process is performed to obtain a prediction of whether the second adsorption region on the second virtual object needs to be displayed. The timing prediction model is trained using historical scene data (such as the historical distribution of virtual objects on both sides during combat, the historical attributes of virtual objects (historical attack capabilities, historical movement speed, etc.), historical targets being shot at, and corresponding historical timing annotations).

[0158] In some embodiments, to avoid the second adsorption area from affecting the player's line of sight, the second adsorption area can be hidden. The triggering conditions for hiding the adjusted second adsorption area include at least one of the following: displaying a close control for the second adsorption area, receiving a trigger operation for the close control; not receiving a shooting operation for the second virtual object within a set time period; receiving a shooting operation for the second virtual object.

[0159] In some embodiments, the size adjustment operation includes a selection operation; in response to the size adjustment operation for the second adsorption region, adjusting the size of the second adsorption region based on a target size set by the size adjustment operation includes: displaying a plurality of candidate sizes for the second adsorption region; in response to a selection operation for a candidate size, adjusting the size of the second adsorption region based on the selected candidate size.

[0160] For example, in embodiments of this application, the size of the second adsorption region can be adjusted by selecting a candidate size. The preferred candidate size can be selected directly, avoiding complex manual adjustment operations.

[0161] In some embodiments, the size of the first adsorption area is positively correlated with the shooting difficulty parameter of the first virtual object, or negatively correlated with the object parameter of the first virtual object; wherein the shooting difficulty parameter includes at least one of the following: the size of the second virtual object, the distance between the second virtual object and the virtual weapon; the object parameter includes at least one of the following: the shooting hit rate of the virtual weapon held by the first virtual object, the shooting accuracy of the virtual weapon held by the first virtual object, the level of the first virtual object, the historical kill count of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

[0162] For example, the larger the size of the second virtual object, the greater the difficulty of shooting the virtual weapon, and the larger the size of the first adsorption area; the greater the distance between the second virtual object and the virtual weapon, the greater the difficulty of shooting the virtual weapon, and the larger the size of the first adsorption area; the higher the level of the first virtual object, the higher the player's shooting skill, and the smaller the size of the first adsorption area.

[0163] In some embodiments, a first adsorption region is displayed; in response to a size adjustment operation for the first adsorption region, the size of the first adsorption region is adjusted based on a target size set by the size adjustment operation, and the adjusted first adsorption region is hidden.

[0164] It should be noted that, to ensure players can clearly see the first suction area, it can be displayed in the virtual scene to help them determine the effective range for triggering the crosshair's suction. Alternatively, the first suction area can be hidden to avoid obstructing the player's view.

[0165] It should be noted that the size of the first adsorption area in this embodiment can be adjusted. Players can manually adjust the size of the first adsorption area to make the adjusted size of the first adsorption area conform to user preferences.

[0166] For example, the size adjustment operation includes a selection operation; in response to the size adjustment operation for the first adsorption region, adjusting the size of the first adsorption region based on the target size set by the size adjustment operation includes: displaying multiple candidate sizes of the first adsorption region; in response to the selection operation for the candidate size, adjusting the size of the first adsorption region based on the selected candidate size. Embodiments of this application allow adjustment of the size of the first adsorption region by selecting a candidate size; simply selecting the preferred candidate size avoids complex manual adjustment operations.

[0167] In some embodiments, a detection ray is emitted from the firing port of the virtual weapon in the same direction as the firing direction, and the crosshair is the endpoint of the detection ray; when the detection ray intersects with the first adsorption area, it is determined that the crosshair moves from the outside of the first adsorption area to the inside of the first adsorption area.

[0168] like Figure 12 As shown, a cuboid 1201 (first adsorption area) is attached to the second virtual object. The player controls the muzzle of the virtual weapon to fire a ray for detection. When the ray detects the cuboid (i.e. the ray and the cuboid intersect), an adsorption effect will occur, and the crosshair will be adsorbed towards the second adsorption area.

[0169] In some embodiments, in response to an adjustment operation for the firing direction of a virtual weapon, before the crosshair moves from the outside of the first adsorption area to the inside of the first adsorption area, the firing direction of the virtual weapon is adjusted so that the crosshair of the virtual weapon moves from the outside of the first adsorption area to the inside of the first adsorption area; or, in response to the firing direction of the virtual weapon remaining unchanged and the second virtual object moving in the firing direction, the crosshair of the virtual weapon is controlled to move from the outside of the first adsorption area to the inside of the first adsorption area.

[0170] For example, the virtual weapon's crosshair can be moved from outside to inside the first adsorption area by the player adjusting the virtual weapon's firing direction, or by the player keeping the virtual weapon's firing direction unchanged while the second virtual object moves in that direction.

[0171] The following will describe an exemplary application of the embodiments of this application in a real-world application scenario.

[0172] The embodiments of this application can be applied to various virtual scenarios, such as virtual scenarios in games, and can simulate the real battle process between virtual objects.

[0173] The following explanation uses a virtual scene as an example of a shooting game:

[0174] In shooting games, since the endpoint of the crosshair is a point on the central axis of the virtual character, and because the virtual characters have different postures, abnormal situations of the attachment point often occur.

[0175] To address the issue of non-coincidence of the adsorption endpoints due to the aforementioned morphological changes, this application proposes a design scheme (i.e., a processing method in a virtual scene) that alters the adsorption endpoint based on changes in the character's morphology. This scheme associates the adsorption endpoint with the bone orientation (i.e., the direction through which the bones of the virtual character pass), and changes the position and orientation of the central axis in real time based on the bone orientation. Furthermore, it transforms the original adsorption line segment into an adsorption frame (i.e., a bounding box), changing the adsorption process from the crosshair pointing towards a line segment to adsorption towards a bounding box.

[0176] This application optimizes the position and orientation of adsorption targets (adsorption line segments (hereinafter referred to as adsorption lines) or adsorption boxes) in various forms. The specific optimization scheme is as follows:

[0177] When players adjust their aiming direction or change the current form of their virtual character, the center line changes. If the vertical line from the body's center is still used as the center line, it will not coincide with the virtual character's head. Therefore, the position of the suction line needs to be changed according to the current form of the virtual character. Figure 6A As shown, line segment 601 is the suction line for the virtual character's head, and line segment 602 is the suction line for the virtual character's body. The positions of line segments 601 and 603 are adapted to the shape of the virtual character.

[0178] like Figure 6B As shown, the neck is used as the center dividing line between the head and body of the virtual character. The direction from the top of the head to the neck is the orientation of the head, that is, the direction from the center of the head to the center of the neck 603. The direction from the neck to the body is the orientation of the body, that is, the direction from the center of the neck 603 to the center of the body.

[0179] In this embodiment, the snapping line segment is replaced with a snapping frame (implemented using a rectangle). When using a snapping line, the player's crosshair is snapped to the snapping line of the virtual character, which reduces the player's maneuverability. Therefore, to allow the player to better control the crosshair and improve aiming accuracy, the snapping line segment is replaced with a rectangle. It should be noted that the rectangle will be pressed tightly against the virtual character.

[0180] It should be noted that, as Figure 7 As shown, during the aiming process, each frame needs to identify the enemy's head and torso, and set a rectangular frame 701 around the enemy's head and a rectangular frame 702 around the torso.

[0181] During aiming, if the virtual character changes its orientation, the bounding box will also update accordingly. Figure 8 As shown, when the virtual character is crouching sideways, a rectangular frame 801 is set on the enemy's head and a rectangular frame 802 is set on the body torso, that is, the rectangular frames 801 and 802 are adapted to the orientation of the virtual character.

[0182] In this embodiment, the point on the rectangle closest to the crosshair is taken as the adsorption endpoint. The specific implementation scheme is as follows:

[0183] The adsorption line segment is changed to an adsorption frame. The determination of the final adsorption endpoint on the adsorption frame also needs to be updated. The process of determining the adsorption endpoint includes two parts. First, determine whether the position of the crosshair is closer to the adsorption frame of the head or the adsorption frame of the body (for example, if the circle with the crosshair as the center point first intersects with the rectangle of the head, then the crosshair is closest to the rectangle of the head. That is, within the rectangle of the head and the rectangle of the body, the rectangle of the head includes the adsorption point closest to the crosshair). Then, select the point on the nearest adsorption frame that is closest to the crosshair as the final target adsorption point.

[0184] like Figure 9 As shown, it determines which rectangle the crosshair is closer to. If the crosshair is closer to the head rectangle, the head rectangle is selected for snapping. If the crosshair is closer to the torso rectangle, the torso rectangle 901 is selected for snapping.

[0185] The principle for selecting the target adsorption point on the rectangle is: (e.g.) Figure 9 As shown, if the horizontal line of the crosshair 902 intersects the rectangle (i.e., the rectangle closest to the crosshair) at point 903, then the crosshair will snap to the intersection point; as... Figure 10 As shown, if the horizontal line of the crosshair does not intersect with the rectangle (i.e. the rectangle closest to the crosshair), then the crosshair 1001 will snap towards the point 1002 on the rectangle that is closest to the crosshair.

[0186] The following is combined with Figure 11 The design scheme for changing the adsorption endpoint based on changes in human form, as proposed in this application, is explained in the following steps:

[0187] Step 1: Aim the crosshair at the target to be adsorbed.

[0188] The adsorption target is the second adsorption region, which can be an adsorption line segment or an adsorption frame.

[0189] Step 2: When the crosshair hits the adsorption area, the crosshair begins to move towards the rectangle.

[0190] It should be noted that when the player's crosshair is pointed at a certain area of ​​the virtual character (i.e., the suction area, also known as the first suction area), a suction effect will occur. The principle behind this suction effect is that each virtual character has a cube (i.e., a collider) attached to it. Figure 12 As shown, a cuboid 1201 is attached to the virtual character. The player controls the muzzle of the virtual gun to fire a ray for detection. When the ray detects the cuboid (that is, the ray and the cuboid have an intersection), an adsorption effect will occur, and the crosshair will be attracted to the rectangle.

[0191] It should be noted that the size of the adsorption area can be configured according to requirements; the larger the adsorption area, the larger the adsorption range.

[0192] Step 3: Calculate the point on the rectangle closest to the crosshair in real time.

[0193] It should be noted that because the virtual character's head and body are not the same size, two rectangles are added to allow for more precise control over the target attraction. When attraction occurs, the system first determines whether the crosshair is closer to the head rectangle or the body rectangle. The following explanation uses the example of being closer to the head:

[0194] like Figure 13 As shown, the crosshair is at point A. Since point A and the rectangle have a horizontal intersection point 1301, the crosshair eventually snaps to the intersection point 1301 on the border of the rectangle.

[0195] like Figure 14 As shown, the crosshair is at point B. Since point B has no intersection with the rectangle in either the vertical or horizontal direction, the crosshair eventually snaps to the right vertex 1401 of the rectangle (the right vertex is closest to the crosshair).

[0196] Step 4: When the point on the rectangle closest to the crosshair is calculated, snap the crosshair to that closest point and stop snapping.

[0197] In summary, the embodiments of this application solve the problem that the central axis is not in the head in various modes, and the addition of a rectangular frame allows players to have more control. By attaching the crosshair to the edge of the rectangle, the aiming assistance can be improved. Players can control the crosshair to any position within the rectangle.

[0198] The exemplary application and implementation of the terminal provided in the embodiments of this application have been used to describe the processing method in the virtual scene provided in the embodiments of this application. The following will continue to describe how the various modules in the processing device 465 in the virtual scene provided in the embodiments of this application cooperate to implement the processing scheme in the virtual scene.

[0199] A first display module 4651 is used to display a virtual scene, wherein the virtual scene includes a first virtual object and a second virtual object; a second display module 4652 is used to control the first virtual object to hold the virtual weapon in response to triggering an operation of the first virtual object holding the virtual weapon, and to display the crosshair of the virtual weapon in the virtual scene; wherein the crosshair corresponds to the firing direction of the virtual weapon and is used to indicate the impact point of the projectile of the virtual weapon in the virtual scene; a third display module 4653 is used to automatically adjust the firing direction of the virtual weapon in response to the crosshair moving from the outside of the first adsorption area to the inside of the first adsorption area, so that the crosshair of the virtual weapon automatically adsorbs onto the second adsorption area in the second virtual object; wherein the first adsorption area is the area surrounding the second virtual object, and the second adsorption area is bound to the second virtual object along a direction that penetrates at least a portion of the skeleton of the second virtual object.

[0200] In some embodiments, the type of the second adsorption region includes: a line segment passing through the head skeleton of the second virtual object, a line segment passing through the torso skeleton of the second virtual object, a bounding box surrounding the head skeleton of the second virtual object, and a bounding box surrounding the torso skeleton of the second virtual object.

[0201] In some embodiments, the direction through at least a portion of the bones of the second virtual object is the direction from the center point of the at least a portion of the bones to a critical point, where the critical point is the center point of the line connecting the at least a portion of the bones to adjacent bones.

[0202] In some embodiments, when there are multiple second adsorption areas, the third display module 4653 is further configured to automatically adjust the firing direction of the virtual weapon so that the crosshair of the virtual weapon is automatically adsorbed onto the target adsorption area closest to the crosshair; wherein, the target adsorption area is a second adsorption area among multiple second adsorption areas that includes the adsorption point closest to the crosshair.

[0203] In some embodiments, adsorption points in the second adsorption region are determined according to the priority order of candidate adsorption points in the second adsorption region from high to low, so that the crosshair is automatically adsorbed onto the adsorption points in the second adsorption region; wherein, the priority order of the candidate adsorption points from high to low is as follows: the intersection of the horizontal line of the second adsorption region and the crosshair, the intersection of the vertical line of the second adsorption region and the crosshair, the point on the second adsorption region closest to the crosshair, and the vertex on the second adsorption region closest to the crosshair.

[0204] In some embodiments, the third display module 4653 is further configured to display a plurality of candidate types of the second adsorption region; in response to a selection operation for the candidate type, the selected candidate type is used as the type of the second adsorption region.

[0205] In some embodiments, when the object parameter of the first virtual object is greater than the object parameter threshold, the type of the second adsorption region is determined to be a bounding box; wherein, the type of the object parameter includes at least one of the following: the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

[0206] In some embodiments, the third display module 4653 is further configured to call a type prediction model to perform type prediction processing based on the scene data of the virtual scene, the virtual weapon, and the second virtual object to obtain the type of the second adsorption region; wherein, the type prediction model is trained using historical scene data, historical virtual weapons, historical targets being shot, and corresponding historical type annotations.

[0207] In some embodiments, the third display module 4653 is further configured to display a second adsorption region bound to the second virtual object; in response to a size adjustment operation for the second adsorption region, the size of the second adsorption region is adjusted based on a target size set by the size adjustment operation, and the adjusted second adsorption region is hidden.

[0208] In some embodiments, before displaying the second adsorption area bound to the second virtual object, the third display module 4653 is further configured to obtain object parameters of the first virtual object; when the object parameters are less than the object parameter threshold, the process of displaying the second adsorption area bound to the second virtual object is initiated; wherein, the type of the object parameters includes at least one of the following: the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health points of the first virtual object, and the win rate of the first virtual object.

[0209] In some embodiments, before displaying the second adsorption area bound to the second virtual object, the third display module 4653 is further configured to acquire associated information bound to the second virtual object in the virtual scene; wherein, the display style parameters of the associated information include at least one of the following: color, shape, and output format; when the associated information of the second virtual object meets the following triggering conditions, the operation of displaying the second adsorption area bound to the second virtual object is triggered: the number of associated information is greater than a quantity threshold; the area of ​​the associated information is greater than an area threshold; the difference between the color of the associated information and the color set by the second adsorption area is greater than a color difference threshold; the area of ​​the associated information obscured by the second adsorption area is less than an area threshold.

[0210] In some embodiments, before displaying the second adsorption region bound to the second virtual object, the third display module 4653 is further configured to perform display timing prediction processing based on the scene data of the virtual scene and the second virtual object by calling a display timing prediction model to obtain a prediction result of whether the second adsorption region on the second virtual object needs to be displayed; wherein, the display timing prediction model is trained by historical scene data, historically shot virtual objects, and corresponding historical display timing annotations of adsorption regions; when the prediction result indicates that the second adsorption region needs to be displayed, the process of displaying the second adsorption region bound to the second virtual object is initiated.

[0211] In some embodiments, the triggering conditions for hiding the adjusted second adsorption area include at least one of the following: displaying a close control for the second adsorption area, receiving a trigger operation for the close control; not receiving a shooting operation for the second virtual object within a set time period; receiving a shooting operation for the second virtual object.

[0212] In some embodiments, the size adjustment operation includes a selection operation; the third display module 4653 is further configured to display a plurality of candidate sizes of the second adsorption region; in response to the selection operation for the candidate size, the size of the second adsorption region is adjusted based on the selected candidate size.

[0213] In some embodiments, the size of the first adsorption area is positively correlated with the shooting difficulty parameter of the first virtual object, or negatively correlated with the object parameter of the first virtual object; wherein the shooting difficulty parameter includes at least one of the following: the size of the second virtual object, the distance between the second virtual object and the virtual weapon; the object parameter includes at least one of the following: the shooting hit rate of the virtual weapon held by the first virtual object, the shooting accuracy of the virtual weapon held by the first virtual object, the level of the first virtual object, the historical kill count of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

[0214] In some embodiments, the third display module 4653 is further configured to display the first adsorption region; in response to a size adjustment operation for the first adsorption region, adjust the size of the first adsorption region based on a target size set by the size adjustment operation, and hide the adjusted first adsorption region.

[0215] In some embodiments, the third display module 4653 is further configured to emit a detection ray from the firing port of the virtual weapon in the same direction as the firing direction, wherein the crosshair is the endpoint of the detection ray; when the detection ray intersects with the first adsorption area, it is determined that the crosshair moves from the outside of the first adsorption area to the inside of the first adsorption area.

[0216] In some embodiments, before the crosshair moves from outside the first adsorption area to inside the first adsorption area, the third display module 4653 is further configured to adjust the firing direction of the virtual weapon in response to an adjustment operation for the firing direction of the virtual weapon, so that the crosshair of the virtual weapon moves from outside the first adsorption area to inside the first adsorption area; or, in response to the firing direction of the virtual weapon remaining unchanged and the second virtual object moving in the firing direction, control the crosshair of the virtual weapon to move from outside the first adsorption area to inside the first adsorption area.

[0217] This application provides a computer program product or computer program that includes computer instructions stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the electronic device to perform the processing method in the virtual scene described above in this application embodiment.

[0218] This application provides a computer-readable storage medium storing executable instructions. When these executable instructions are executed by a processor, they cause the processor to execute a processing method in a virtual scene provided in this application, for example... Figures 4A-4B The processing method shown in the virtual scene.

[0219] In some embodiments, the computer-readable storage medium may be a memory such as FRAM, ROM, PROM, EPROM, EEPROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or it may be a variety of devices including one or any combination of the above-mentioned memories.

[0220] In some embodiments, executable instructions may take the form of a program, software, software module, script, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a standalone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.

[0221] As an example, executable instructions may, but do not necessarily, correspond to files in a file system. They may be stored as part of a file that holds other programs or data, for example, in one or more scripts in a Hyper Text Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple collaborating files (e.g., a file that stores one or more modules, subroutines, or code sections).

[0222] As an example, executable instructions can be deployed to execute on a single computing device, or on multiple computing devices located in one location, or on multiple computing devices distributed across multiple locations and interconnected via a communication network.

[0223] It is understood that in the embodiments of this application, data such as user information are involved. When the embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.

[0224] The above description is merely an embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, and improvements made within the spirit and scope of this application are included within the scope of protection of this application.

Claims

1. A processing method in a virtual scene, characterized in that, include: Displaying a virtual scene, wherein the virtual scene includes a first virtual object and a second virtual object; In response to triggering the operation of the first virtual object holding a virtual weapon, the system controls the first virtual object to hold the virtual weapon and displays the crosshair of the virtual weapon in the virtual scene; The crosshair corresponds to the firing direction of the virtual weapon and is used to indicate the landing point of the projectile of the virtual weapon in the virtual scene; In response to the crosshair moving from outside the first adsorption area to inside the first adsorption area, the firing direction of the virtual weapon is automatically adjusted so that the crosshair of the virtual weapon automatically adsorbs onto the adsorption point of the second adsorption area in the second virtual object; Wherein, the first adsorption region is the region surrounding the second virtual object, and the second adsorption region is bound to the second virtual object along a direction that penetrates at least a portion of the skeleton of the second virtual object; Specifically, when the horizontal line of the collimator intersects with the second adsorption area, the intersection of the second adsorption area and the horizontal line is taken as the adsorption point; when the horizontal line of the collimator does not intersect with the second adsorption area, but the vertical line of the collimator intersects with the second adsorption area, the intersection of the second adsorption area and the vertical line is taken as the adsorption point; when neither the vertical line nor the horizontal line of the collimator intersects with the second adsorption area, the point on the second adsorption area closest to the collimator or the vertex on the second adsorption area closest to the collimator is taken as the adsorption point.

2. The method according to claim 1, characterized in that, The types of the second adsorption region include: A line segment passing through the head skeleton of the second virtual object, a line segment passing through the torso skeleton of the second virtual object, a bounding box surrounding the head skeleton of the second virtual object, and a bounding box surrounding the torso skeleton of the second virtual object.

3. The method according to claim 1 or 2, characterized in that, The direction through at least a portion of the bones of the second virtual object is the direction from the center point of the at least a portion of the bones to the critical point, where the critical point is the center point of the line connecting the at least a portion of the bones to the adjacent bones.

4. The method according to claim 1 or 2, characterized in that, When there are multiple second adsorption regions, the second adsorption region to which the crosshair is automatically adsorbed is the second adsorption region of the adsorption point closest to the crosshair among the multiple second adsorption regions.

5. The method according to claim 1 or 2, characterized in that, The method further includes: Displays multiple candidate types for the second adsorption region; In response to the selection operation for the candidate type, the selected candidate type is taken as the type of the second adsorption region.

6. The method according to claim 1 or 2, characterized in that, When the object parameter of the first virtual object is greater than the object parameter threshold, the type of the second adsorption region is determined to be a bounding box; The object parameters include at least one of the following types: the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

7. The method according to claim 1 or 2, characterized in that, The method further includes: Based on the scene data of the virtual scene, the virtual weapon, and the second virtual object, a type prediction model is invoked to perform type prediction processing to obtain the type of the second adsorption region; The type prediction model is trained using historical scene data, historical virtual weapons, historical targets being shot at, and corresponding historical type annotations.

8. The method according to claim 1 or 2, characterized in that, The method further includes: Display the second adsorption area bound to the second virtual object; In response to the size adjustment operation for the second adsorption region, the size of the second adsorption region is adjusted based on the target size set by the size adjustment operation, and the adjusted second adsorption region is hidden.

9. The method according to claim 8, characterized in that, Before displaying the second adsorption region bound to the second virtual object, the method further includes: Obtain the object parameters of the first virtual object; When the object parameter is less than the object parameter threshold, the process of displaying the second adsorption region bound to the second virtual object is initiated. The object parameters include at least one of the following types: the shooting hit rate of the virtual weapon held by the first virtual object, the number of remaining projectiles of the virtual weapon held by the first virtual object, the attack capability of the first virtual object, the level of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

10. The method according to claim 8, characterized in that, Before displaying the second adsorption region bound to the second virtual object, the method further includes: Obtain the association information bound to the second virtual object in the virtual scene; The parameters of the display style of the associated information include at least one of the following: color, shape, and output format; When the association information of the second virtual object meets the following triggering conditions, the operation of displaying the second adsorption area bound to the second virtual object is triggered: The number of associated information is greater than the quantity threshold; The area of ​​the associated information is greater than the area threshold; The difference between the color of the associated information and the color set in the second adsorption region is greater than the color difference threshold. The area of ​​the second adsorption region that obscures the associated information is less than the area threshold.

11. The method according to claim 8, characterized in that, Before displaying the second adsorption region bound to the second virtual object, the method further includes: Based on the scene data of the virtual scene and the second virtual object, the display timing prediction model is called to perform display timing prediction processing to obtain the prediction result of whether the second adsorption area on the second virtual object needs to be displayed; The display timing prediction model is trained using historical scene data, historically shot virtual objects, and corresponding historical adsorption areas with display timing annotations. When the prediction result indicates that the second adsorption region needs to be displayed, the process of displaying the second adsorption region bound to the second virtual object is initiated.

12. The method according to claim 8, characterized in that, The triggering condition for the hidden adjusted second adsorption region includes at least one of the following: Display a close control for the second adsorption area, and receive a trigger operation for the close control; No shooting operation was received against the second virtual object within the set time period; A firing command was received targeting the second virtual object.

13. The method according to claim 8, characterized in that, The size adjustment operation includes a selection operation; The step of adjusting the size of the second adsorption region in response to a size adjustment operation for the second adsorption region, based on a target size set by the size adjustment operation, includes: This displays multiple candidate sizes for the second adsorption region; In response to the selection operation for the candidate size, the size of the second adsorption region is adjusted based on the selected candidate size.

14. The method according to claim 1, characterized in that, The size of the first adsorption region is positively correlated with the shooting difficulty parameter of the first virtual object, or negatively correlated with the object parameter of the first virtual object; The shooting difficulty parameter includes at least one of the following: the size of the second virtual object, and the distance between the second virtual object and the virtual weapon; The object parameters include at least one of the following types: the shooting hit rate of the virtual weapon held by the first virtual object, the shooting accuracy of the virtual weapon held by the first virtual object, the level of the first virtual object, the historical kill count of the first virtual object, the health of the first virtual object, and the win rate of the first virtual object.

15. The method according to claim 1 or 14, characterized in that, The method further includes: The first adsorption region is shown; In response to the size adjustment operation for the first adsorption region, the size of the first adsorption region is adjusted based on the target size set by the size adjustment operation, and the adjusted first adsorption region is hidden.

16. The method according to claim 1, characterized in that, The method further includes: A detection ray is emitted from the firing port of the virtual weapon in the same direction as the firing, and the crosshair is the endpoint of the detection ray; When the detection ray intersects with the first adsorption region, it is determined that the collimator has moved from the outside of the first adsorption region to the inside of the first adsorption region.

17. The method according to claim 1, characterized in that, Before the collimator moves from the outside of the first adsorption region to the inside of the first adsorption region, the method further includes: In response to an adjustment operation on the firing direction of the virtual weapon, the firing direction of the virtual weapon is adjusted so that the crosshair of the virtual weapon moves from outside the first adsorption area to inside the first adsorption area; or, In response to the virtual weapon's firing direction remaining unchanged and the second virtual object moving in the firing direction, the aiming point of the virtual weapon is controlled to move from outside the first adsorption area to inside the first adsorption area.

18. A processing device for a virtual scene, characterized in that, The device includes: A first display module is used to display a virtual scene, wherein the virtual scene includes a first virtual object and a second virtual object; The second display module is used to respond to the operation of triggering the first virtual object to hold the virtual weapon, control the first virtual object to hold the virtual weapon, and display the crosshair of the virtual weapon in the virtual scene; The crosshair corresponds to the firing direction of the virtual weapon and is used to indicate the landing point of the projectile of the virtual weapon in the virtual scene; The third display module is used to automatically adjust the firing direction of the virtual weapon in response to the crosshair moving from the outside of the first adsorption area to the inside of the first adsorption area, so that the crosshair of the virtual weapon automatically adsorbs onto the adsorption point of the second adsorption area in the second virtual object; Wherein, the first adsorption region is the region surrounding the second virtual object, and the second adsorption region is bound to the second virtual object along a direction that penetrates at least a portion of the skeleton of the second virtual object; Specifically, when the horizontal line of the collimator intersects with the second adsorption area, the intersection of the second adsorption area and the horizontal line is taken as the adsorption point; when the horizontal line of the collimator does not intersect with the second adsorption area, but the vertical line of the collimator intersects with the second adsorption area, the intersection of the second adsorption area and the vertical line is taken as the adsorption point; when neither the vertical line nor the horizontal line of the collimator intersects with the second adsorption area, the point on the second adsorption area closest to the collimator or the vertex on the second adsorption area closest to the collimator is taken as the adsorption point.

19. The apparatus according to claim 18, characterized in that, The third display module is also used to display multiple candidate types of the second adsorption region; in response to a selection operation for the candidate type, the selected candidate type is used as the type of the second adsorption region.

20. The apparatus according to claim 18, characterized in that, The third display module is also used to call a type prediction model to perform type prediction processing based on the scene data of the virtual scene, the virtual weapon, and the second virtual object to obtain the type of the second adsorption area; wherein, the type prediction model is trained by historical scene data, historical virtual weapons, historical shot objects, and corresponding historical type annotations.

21. The apparatus according to claim 18, characterized in that, The third display module is also used to display the first adsorption area; in response to the size adjustment operation of the first adsorption area, the size of the first adsorption area is adjusted based on the target size set by the size adjustment operation, and the adjusted first adsorption area is hidden.

22. The apparatus according to claim 18, characterized in that, The third display module is also used to display the second adsorption area bound to the second virtual object; in response to the size adjustment operation of the second adsorption area, the size of the second adsorption area is adjusted based on the target size set by the size adjustment operation, and the adjusted second adsorption area is hidden.

23. An electronic device, characterized in that, The electronic device includes: Memory, used to store executable instructions; A processor, when executing executable instructions stored in the memory, implements the processing method in the virtual scene according to any one of claims 1 to 17.

24. A computer-readable storage medium, characterized in that, It stores executable instructions for implementing the processing method in the virtual scene as described in any one of claims 1 to 17 when executed by a processor.

25. A computer program product comprising a computer program or instructions, characterized in that, When the computer program or instructions are executed by a processor, they implement the processing method in the virtual scene as described in any one of claims 1 to 17.