Method for selecting a virtual object, and apparatus, terminal, and storage medium therefor

The method and apparatus for selecting a virtual object in games ensure accurate target selection by determining an effective application area within the user's visual range, addressing the issue of reduced accuracy due to undisplayed targets.

JP7686914B2Active Publication Date: 2025-06-03TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
JP2023186068
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2020-05-12
Filing Date
2023-10-31
Publication Date
2025-06-03
Estimated Expiration
2041-03-30

AI Technical Summary

Technical Problem

In existing game technologies, the selected attack target may not be displayed on the terminal display, leading to reduced selection accuracy due to mismatch between the user's situation and the displayed interface.

Method used

A method and apparatus for selecting a virtual object on a user interface, which involves displaying a user interface with a virtual environment, obtaining a predetermined application area and visible boundary range, determining an effective application area, and selecting a target virtual object within this area to ensure it is within the user's visual range.

Benefits of technology

This solution improves the accuracy of selecting the action target by ensuring it is within the user's visible range, preventing misjudgments caused by the target being out of sight, and enhancing the overall user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007686914000004
    Figure 0007686914000004
  • Figure 0007686914000005
    Figure 0007686914000005
  • Figure 0007686914000006
    Figure 0007686914000006
Patent Text Reader

Abstract

To provide methods, devices, terminals, and storage media, for selecting virtual objects on user interfaces of the terminals.SOLUTION: In an application execution environment where multiple terminals and servers communicate with each other via a network, a method includes: displaying a user interface; acquiring a predetermined application area of a first operation of a first virtual object within a virtual environment; acquiring a visible boundary range of the virtual environment; determining, based on the predetermined application area and the visible boundary range, an effective application area of the first operation within the virtual environment; and determining a target virtual object based on the effective application area.SELECTED DRAWING: Figure 3
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application claims the benefit of Chinese Patent Application No. 202010398569.3, titled "Method, Apparatus, Terminal, and Storage Medium for Selecting a Virtual Object", filed on May 12, 2020, the entire content of which is incorporated herein by reference.

[0002] This application relates to computer and Internet technologies, and more particularly, to a method, apparatus, terminal, and storage medium for selecting a virtual object.

Background Art

[0003] Currently, the types of skills of virtual objects in game applications are increasing more and more.

[0004] In related technologies, in a game, a user can control a first virtual object to attack a second virtual object using a skill, where the second virtual object and the first virtual object are in different camps. When the first virtual object releases a skill, the client can obtain the attack range of the skill and use the second virtual object within the attack range as the attack target of the first virtual object.

[0005] However, in the aforementioned related technologies, the selected attack target may not be displayed on the terminal display, which does not match the user's situation, so the selection accuracy of the attack target is reduced.

Summary of the Invention

[0006] Embodiments of this application provide a method, apparatus, terminal, and storage medium for selecting a virtual object on a user interface of a terminal, thereby ensuring that the action target of a first action is within the user's visual range and improving the accuracy of selecting the action target of the first action. The technical solutions are as follows.

[0007] In one aspect, an embodiment of the present application provides a method for a terminal to select a virtual object on a user interface of the terminal. The method includes: displaying a user interface, where the user interface includes a display screen corresponding to a virtual environment and further includes a first virtual object located within the virtual environment; obtaining a predetermined application area of a first operation of the first virtual object within the virtual environment; obtaining a visible boundary range of the virtual environment, where virtual objects existing within the visible boundary range are visible on the user interface; determining an effective application area of the first operation within the virtual environment based on the predetermined application area and the visible boundary range; and determining a target virtual object based on the effective application area.

[0008] In another aspect, an embodiment of the present application provides an apparatus for selecting a virtual object on a user interface of a terminal. The apparatus includes: an interface display module configured to display a user interface, where the user interface includes a display screen corresponding to a virtual environment and further includes a first virtual object located within the virtual environment; a range obtaining module configured to obtain a predetermined application area of a first operation of the first virtual object within the virtual environment; a boundary obtaining module configured to obtain a visible boundary range of the virtual environment, where virtual objects existing within the visible boundary range are visible on the user interface; a range determining module configured to determine an effective application area of the first operation within the virtual environment based on the predetermined application area and the visible boundary range; and an object determining module configured to determine a target virtual object based on the effective application area.

[0009] In yet another aspect, an embodiment of the present application provides a terminal including a processor and a memory. The memory stores at least one instruction, at least one program, a code set, or an instruction set, and when loaded and executed by the processor, causes the processor to execute the above method for selecting a virtual object.

[0010] In yet another aspect, an embodiment of the present application provides a computer-readable storage medium. The computer-readable storage medium stores at least one instruction, at least one program, a code set, or an instruction set, and when loaded and processed by the processor, causes the processor to execute the above method for selecting a virtual object.

[0011] In yet another aspect, a computer program product is provided. When executed on a terminal, the computer program product causes the terminal to execute the above-described method for selecting a virtual object.

Brief Description of the Drawings

[0012] To more clearly illustrate the technical solutions in the embodiments of the present application, the accompanying drawings necessary for describing the embodiments are briefly described below. It is obvious that the accompanying drawings described below are only some embodiments of the present application. Those skilled in the art can obtain other accompanying drawings based on these accompanying drawings without creative efforts.

Figure 1

Figure 2

Figure 3

Figure 4

Figure 5

Figure 6

Figure 7

Figure 8

Figure 9

Figure 10

Figure 11

Figure 12

Embodiments for Carrying Out the Invention

[0013] To make the purpose, technical solution and advantages of the present application clearer, a detailed description of the implementation form of the present application is provided below together with the accompanying drawings.

[0014] Referring to FIG. 1, FIG. 1 is a schematic diagram showing an execution environment of an application according to an embodiment of the present application. The application execution environment may include a terminal 10 and a server 20.

[0015] The terminal 10 may be an electronic device (UE) such as a mobile phone, a tablet computer, a game host, an e - book reader, a multimedia playback device, a wearable device, a personal computer (PC), etc. The client of the application may be installed on the terminal 10.

[0016] In an embodiment of the present application, the aforementioned application can be any application that can provide a virtual environment such that virtual objects selected and operated by a user perform activities within the virtual environment. Usually, the application is a game application such as a multiplayer online battle arena (MOBA) game, a battle royale (BR) game, a third-person shooting game (TPS), a first-person shooting game (FPS), and a multiplayer gun battle survival game. Of course, in addition to game applications, other types of applications can also display virtual objects to the user and provide functions corresponding to the virtual objects. For example, there are virtual reality (VR) applications, augmented reality (AR) applications, 3D map programs, military simulation programs, social applications, interactive entertainment applications, etc., which are not limited by the embodiments of the present application. Furthermore, for different applications, the forms of the provided virtual objects and the corresponding functions are different, which can be pre-configured according to actual needs and are not limited by the embodiments of the present application. The client of the aforementioned application is executed on the terminal 10. In some embodiments, the aforementioned application is developed based on a three-dimensional virtual environment engine. For example, such a virtual environment engine is the Unity engine. The virtual environment engine can construct a three-dimensional virtual environment, virtual objects, and virtual props, etc., so that the user can obtain a more immersive game experience.

[0017] The above virtual environment is a scene displayed (or provided) by the client of an application (such as a game application) when the client is executed on a terminal. Such a virtual environment refers to a scene in which virtual objects such as virtual houses, virtual islands, virtual maps, and virtual buildings are created for performing activities (such as game competitions). Such a virtual environment can be a simulation environment of the real world, a semi-simulation and semi-fictional environment, or a purely fictional environment. The virtual environment may be a two-dimensional virtual environment, or a 2.5-dimensional virtual environment, or a three-dimensional virtual environment, which is not limited by the embodiments of the present application.

[0018] The above virtual object can be a virtual character controlled by a user account in the application, or a virtual character controlled by a computer program in the application. In one example, when the application is a game application, the virtual object can be a game character controlled by a user account in the game application, or a game monster controlled by a computer program in the game application. The virtual object may be in the form of a character, an animal, a comic, or other forms, which is not limited by the embodiments of the present application. The virtual object may be displayed in a three-dimensional form or a two-dimensional form, which is not limited by the embodiments of the present application. When the virtual environment is a three-dimensional environment, the virtual object is a three-dimensional model created based on animation skeletal technology. In a three-dimensional environment, each virtual object has its own shape and volume and occupies a part of the space in the three-dimensional virtual environment. In the embodiments of the present application, the terminal 10 can receive an operation from the virtual object, determine a valid application area based on a predetermined application area of the operation and the visible boundary range of the virtual environment, and determine a target virtual object corresponding to the operation within the valid application area.

[0019] In a possible implementation form, the above virtual objects include virtual objects within the same camp and virtual objects within different camps. That is, in the application, virtual objects are divided into different camps. As an example, taking a MOBA game as an example, 10 users play a matching game and are divided into two teams, namely the red team and the blue team. That is, they form groups of 5 people each. At this time, the virtual objects of the red team are within the same camp and are teammates, and the virtual objects of the blue team are within the same camp and are teammates. However, the virtual objects of the red team and the virtual objects of the blue team are in different camps and are hostile to each other.

[0020] Server 20 is configured to provide background services to the client of the application within terminal 10. For example, server 20 may be the background server of the aforementioned application. Server 20 may be a server, or a server cluster composed of multiple servers, or a cloud computing service center. Server 20 can simultaneously provide background services to the applications of various terminals 10.

[0021] Terminal 10 and server 20 can communicate with each other via network 30.

[0022] Referring to FIG. 2, FIG. 2 is a schematic diagram showing the structure of a terminal according to an embodiment of the present application. Terminal 10 may include a main board 110, an external output / input device 120, a memory 130, an external interface 140, a touch control system 150, and a power supply 160.

[0023] Main board 110 integrates processing elements such as a processor and a controller.

[0024] In the case of a terminal, the external output / input device 120 can include a display component (such as a display), an audio playback component (such as a speaker), an audio collection component (such as a microphone), and various types of buttons. In the case of a PC terminal, the external output / input device 120 can include a display component (such as a display), an audio playback component (such as a speaker), an audio collection component (such as a microphone), and various types of buttons (such as a mouse and a keyboard).

[0025] The memory 130 stores program codes and data.

[0026] The external interface 140 may include a headphone interface, a charging interface, a data interface, etc.

[0027] The touch control system 150 may be integrated into the display component or the buttons of the external output / input device 120. The touch control system 150 is configured to detect touch control operations performed by the user on the display component or the buttons.

[0028] The power supply 160 is configured to supply power to other components within the terminal 10.

[0029] In the embodiments of the present application, the processor within the main board 110 generates a user interface (such as a game interface) by executing or calling the program code or data within the memory, and can display the generated user interface (such as a game interface) via the external output / input device 120. During the process of displaying the user interface (such as a game interface), touch operations performed when the user interacts with the user interface (such as a game interface) can be detected via the touch control system 150, and responses to the touch control operations can be performed via the touch control system 150.

[0030] Referring to FIG. 3, FIG. 3 is a flowchart showing a method for selecting a virtual object on the user interface of a terminal according to an embodiment of the present application. This method can be applied to a terminal. For example, the execution entity of each block can be the terminal 10 (hereinafter referred to as the "client") within the application execution environment shown in FIG. 1. This method can include the following blocks (301-305).

[0031] In block 301, display the user interface.

[0032] The user interface can be an image of an application displayed to the user by the client. The application may be a computer program that needs to be downloaded and installed, or it may be a quick execution computer program. The aforementioned application can be any application that can provide a virtual environment, such as a game application program. The above user interface includes a display screen of the virtual environment. The display screen can include virtual items, such as virtual buildings, virtual environments, virtual maps, etc. The user can control the first virtual object so as to interact with various virtual items within the virtual environment.

[0033] In an embodiment of the present application, when receiving an instruction for triggering the application startup from the user, the client can also control the execution of the application and display the user interface corresponding to the application. The above user interface includes a display screen corresponding to the virtual environment and further includes a first virtual object located within the virtual environment. The first virtual object can be a virtual object controlled by the user.

[0034] In block 302, obtain a predetermined application area of the first operation of the first virtual object within the virtual environment.

[0035] The first virtual object is a virtual character controlled by the user within the virtual environment. The first virtual object may be in the form of a character, an animal, a cartoon, or other forms, which are not limited by the embodiments of the present application. In the embodiments of the present application, the first virtual object may be displayed in a three-dimensional or two-dimensional form.

[0036] The first action refers to an interactive action between the first virtual object and the aforementioned virtual environment. For example, the first action may be a skill release action of the first virtual object or a normal attack action of the first virtual object. The action target of the interactive action may be a virtual item within the virtual environment or another virtual object within the virtual environment, which are not limited by the embodiments of the present application.

[0037] In a possible implementation form, the aforementioned first action is triggered by the first virtual object controlled by the user. The user can start the trigger command of the first action by clicking the corresponding icon or pressing the corresponding key. Further, after receiving the trigger command, the client can control the first virtual object to execute the aforementioned first action.

[0038] In another possible implementation, the aforementioned first operation is triggered by a first virtual object controlled by a computer program. After executing the aforementioned application, the client can control the first virtual object to execute the aforementioned first operation according to a pre-set criterion. The pre-set criterion can be set flexibly. For example, the aforementioned pre-set criterion includes the online period of the first virtual object. The client can detect the online period of the first virtual object. When the online period of the first virtual object meets the requirements, the client can control the first virtual object to execute the aforementioned first operation. As another example, the aforementioned pre-set criterion includes the attribute parameters of the first virtual object, and the client can detect the attribute parameters of the first virtual object. When one or more attribute parameters of the first virtual object meet the requirements, the client can control the first virtual object to execute the aforementioned first operation. The above attribute parameters may include a lifespan value, a defense value, an attack speed, etc., and these are not limited by the embodiments of the present application. Alternatively, the aforementioned pre-set criterion includes the operation parameters of the first virtual object, and the client can detect the operation parameters of the first virtual object. When the operation parameters of the first virtual object meet the requirements, the client can control the first virtual object to execute the aforementioned first operation. The aforementioned operation parameters may be the number of defeated monsters, the number of released skills, the number of used items, etc., and these are not limited by the embodiments of the present application. It should be noted that the aforementioned introduction to the pre-set criterion is only illustrative and explanatory. In actual applications, the aforementioned pre-set criterion can be set flexibly according to the actual situation.

[0039] The specified application area refers to the action range of the aforementioned first operation. Different first operations may correspond to different specified application areas. In the embodiments of the present application, after displaying the aforementioned user interface, the client can obtain the specified application area of the first operation of the first virtual object in the virtual environment. The shape of the specified application area may be circular, rectangular, triangular, etc., and these are not limited by the embodiments of the present application.

[0040] In a possible implementation form, the aforementioned specified application area is a pre-set range. The pre-set range is set by the designer and will not be changed during the execution of the application. In another possible implementation form, the aforementioned specified application area is a requirement range. The requirement range changes according to various requirements during the execution of the application. For example, the specified application area of the first operation may be proportional or inversely proportional to the number of executions of the first operation. In actual applications, the aforementioned requirements can be flexibly set according to the actual situation, and these are not limited by the embodiments of the present application.

[0041] In the embodiments of the present application, the client can obtain the aforementioned specified application area according to the position information of the first virtual object. The aforementioned block 302 can include several blocks as follows.

[0042] 1. Obtain the position information of the first virtual object in the virtual environment.

[0043] 2. Determine the specified application area of the first operation in the virtual environment based on the position information and the specified execution distance of the first operation.

[0044] The position information is configured to indicate the position of the virtual object in the virtual environment. The position information is represented in the form of coordinates.

[0045] The specified actual travel distance refers to the maximum action distance of the aforementioned first operation. In the virtual environment, if the distance to the first virtual object is less than the maximum action distance, the virtual item or virtual object can be regarded as the action target of the first operation. In the embodiments of the present application, the client can obtain the position information of the aforementioned first virtual object and determine the specified application area of the first operation based on the position information and the specified actual travel distance of the first operation. The client can determine the boundary points of the specified application area based on the position information and the specified actual travel distance of the first operation, and then determine the specified application area. Alternatively, the client can also determine each area point within the specified application area based on the position information and the specified actual travel distance of the first operation, and then determine the specified application area, which is not limited by the embodiments of the present application. The same first operation may have one or more specified actual travel distances.

[0046] In a possible implementation form, the first operation has one specified actual travel distance. At this time, the specified application area is a circular range centered on the first virtual object. When obtaining the specified application area of the first operation, the client first obtains the position information of the first virtual object and the specified actual travel distance of the first operation, and can determine the area points in the virtual environment, where the distance between the area points and the first virtual object is less than or equal to the specified actual travel distance. The range composed of the area points is the specified application area of the first operation.

[0047] In another possible implementation, the first operation has a plurality of predetermined actual distances. At this time, the distances between the boundary points of the predetermined application area and the first virtual object are not equal. When obtaining the predetermined application area, the client can first obtain the position information of the first virtual object and the plurality of predetermined actual distances of the first operation. Based on the position information, the client can determine area points in the virtual environment from various directions in the virtual environment with reference to the direction the first virtual object is facing. Here, the distance between the area point and the first virtual object is less than or equal to the corresponding predetermined actual distance. The range consisting of the area points is the predetermined application area of the first operation. The direction the first virtual object is facing can be the real-time movement direction of the first virtual object.

[0048] In an example where the predetermined application area is rectangular, in relation to FIG. 4, in the virtual environment, the direction the first virtual object 41 is facing is the first direction 42. When obtaining the predetermined application area 43 of the first operation, the client obtains the position information of the first virtual object 41 and the plurality of predetermined actual distances of the first operation, and then obtains the plurality of boundary points 44 of the predetermined application area with reference to the first direction 42, and then can determine the predetermined application area 43 of the first operation.

[0049] It should be noted that in the embodiments of the present application, after displaying the user interface, the client can obtain the predetermined application area of the first operation in real time based on the change of the position information of the first virtual object and update the predetermined application area. Alternatively, after receiving the trigger instruction of the first operation, the client can obtain the predetermined application area of the first operation, which is not limited by the embodiments of the present application.

[0050] In block 303, obtain the visible boundary range of the virtual environment.

[0051] The visible boundary range refers to the display range of the user interface. The display range may be a range obtained by a virtual camera from the virtual environment. That is, the virtual environment within the aforementioned visible boundary range is visible on the user interface. For example, virtual objects existing within the visible boundary range are visible on the user interface. In an embodiment of the present application, the client can determine the display range of the virtual camera based on the screen range of the client, and then obtain the visible boundary range of the virtual environment.

[0052] Due to the shooting angle of the virtual camera, the visible boundary range is not the same as the screen range of the client. Exemplarily, in relation to FIG. 5, the virtual camera 51 can obtain virtual items within the virtual environment and map the virtual items to the screen range 52 of the client. Due to the shooting angle of the virtual camera 51, the solid line portions of the first virtual object 53 and the second virtual object 54 may be displayed in the screen range 52. That is, the dashed line range 55 (i.e., the slash coverage area) in FIG. 5 is the visible boundary range.

[0053] It should be noted that the embodiment of the present application does not limit the chronological order between the block where the client obtains a predetermined application area and the block where the client obtains the visible boundary range. The client can first obtain the predetermined application area and then obtain the visible boundary range. Alternatively, the client can first obtain the visible boundary range and then obtain the predetermined application area. Of course, the client can also obtain the predetermined application area and the visible boundary range simultaneously, which is not limited by the embodiment of the present application.

[0054] In block 304, based on the predetermined application area and the visible boundary range, determine the valid application area of the first operation within the virtual environment.

[0055] The effective application area refers to the action range of the first action in the actual operation process. The effective action range includes the action target of the first action. The first action may only affect virtual items or virtual objects within the effective application area of the virtual environment, and may not affect virtual items or virtual objects outside the effective application area. After obtaining the predetermined application area of the foregoing first action and the visible boundary range of the virtual environment, the client can determine the effective application area of the first action within the virtual environment based on the predetermined application area and the visible boundary range.

[0056] In the embodiments of the present application, the client can identify the intersection area of the predetermined application area and the visible boundary range as the effective application area of the first action within the virtual environment. Exemplarily, in relation to FIG. 6, the predetermined application area 61 of the first action is a circular range. The visible boundary range 62 of the virtual environment is a rectangular range. The client identifies the intersection area (solid line range area) of the predetermined application area 61 and the visible boundary range 62 as the effective application area of the first action.

[0057] In block 305, based on the effective application area, determine the target virtual object.

[0058] The target virtual object refers to the action object of the foregoing first action. In the embodiments of the present application, after obtaining the foregoing effective application area, the client can determine the target virtual object corresponding to the first action based on the effective application area.

[0059] In a possible implementation form, in order to shorten the response period of the first operation and improve the user's execution experience, after displaying the user interface, the client can obtain the effective application area of the first operation in real time, determine the target virtual object corresponding to the first operation based on the effective application area, and update the aforementioned effective application area and target virtual object. Subsequently, after receiving the trigger instruction of the first operation, the client can quickly determine the target virtual object corresponding to the first operation and control the first virtual object to execute the first operation.

[0060] In another possible implementation form, in order to reduce the processing overhead of the terminal, after obtaining the trigger instruction of the first operation, the client can obtain the effective application area of the first operation based on the trigger instruction of the first operation, determine the target virtual object corresponding to the first operation based on the effective application area, and then control the first virtual object to execute the first operation.

[0061] In view of the above, in the technical solution provided by the embodiments of the present application, the effective application area of the first operation is determined based on the predetermined application area of the first operation and the visible boundary range of the virtual environment. The target virtual object corresponding to the first operation is determined based on the effective application area such that the target virtual object is located within the visible boundary range, thereby ensuring that the action object of the first operation is within the user's visible range, avoiding misjudgment of operations caused by the next scene, that is, the scene where the action object is within the user's invisible range, and improving the accuracy of selecting the action target of the first operation.

[0062] Furthermore, by identifying the intersection area of the predetermined application area and the visible boundary range as the effective application area of the first operation, it is effectively guaranteed that the action object of the first operation is not only within the application area of the first operation but also within the user's visible range.

[0063] The acquisition of the visible boundary range is introduced below. In an exemplary embodiment, the aforementioned block 303 includes the following blocks.

[0064] Process the three-dimensional visual representation within the virtual environment and obtain a two-dimensional visual representation of the virtual environment through the processing of the three-dimensional visual representation.

[0065] The three-dimensional visual representation refers to the visual representation during the execution of the virtual environment. In the visual representation during execution, the first virtual object interacts with the virtual environment. The two-dimensional visual representation refers to the image display diagram of the virtual object. The image display diagram may be displayed on the user interface of the client.

[0066] In the embodiments of the present application, when acquiring the visible boundary range, the client can process the three-dimensional visual representation and obtain a two-dimensional visual representation within the virtual environment through the processing of the three-dimensional visual representation.

[0067] 2. Obtain the coordinates of the feature points of the visible boundary range within the virtual environment from the two-dimensional visual representation of the virtual environment.

[0068] The feature points are configured to indicate a specific range of the visible boundary range. The feature points may be the boundary points of the visible boundary range, for example, the vertices of the visible boundary range. It should be noted that the number of feature points can be any value not limited by the embodiments of the present application.

[0069] After obtaining the aforementioned two-dimensional visual representation of the virtual environment, the client can obtain the coordinates of the feature points of the visible boundary range within the virtual environment from the two-dimensional visual representation, and then can obtain the visible boundary range. In an embodiment of the present application, the client can obtain the coordinates of the feature points of the visible boundary range within the virtual environment based on the parameters of the virtual camera. The parameters include a position parameter and a rotation parameter. The position parameter is configured to determine the position of the virtual camera in the virtual environment. The rotation parameter is configured to determine the shooting angle value of the virtual camera in the virtual environment. The client can obtain the shooting angle value of the virtual camera based on the rotation angle and shooting angle of the virtual camera.

[0070] In an embodiment of the present application, since different clients correspond to different screens, it should be noted that the client can adjust the parameters of the virtual camera based on the screen parameters, and can obtain the position parameter and rotation parameter of the virtual camera through the adjustment process. Next, the client obtains the coordinates of the feature points of the visible boundary range within the virtual environment based on the position parameter and rotation parameter so that the display screen of the virtual environment obtained by the virtual camera matches the user interface of the client. The screen parameters include the screen size and screen resolution, that is, the client can adaptively adjust the position parameter and rotation parameter of the virtual camera based on the screen size and screen resolution. Subsequently, the display screen of the virtual environment obtained by the virtual camera can conform to the screen size and screen resolution of the client.

[0071] 3. Obtain the visible boundary range based on the coordinates of the feature points within the virtual environment.

[0072] After obtaining the above coordinates of the feature points within the virtual environment, the client can obtain the visible boundary range based on the coordinates of the feature points within the virtual environment. For example, according to the shape of the visible boundary range, the client can connect the feature points to obtain the aforementioned visible boundary range.

[0073] As an example, assume that the virtual environment includes a three-dimensional coordinate system, and the x-axis and y-axis of the three-dimensional coordinate system are parallel to the parallel planes of the virtual environment. The angle between the x-axis and the y-axis is 90°. The z-axis is perpendicular to the parallel planes of the virtual environment. The x-axis, y-axis, and z-axis intersect at point O. Subsequently, the position of the virtual camera in the virtual environment is shown in FIG. 7. The coordinates of the virtual camera are TIFF0007686914000001.tif38). From the y-axis and the z-axis, the range of the z-axis values within the visible boundary range z min ~z max is obtained. As shown in FIG. 7, the rotation angle of the virtual camera on the x-axis is CA, and the shooting angle is FA. The client can determine that the rotation angle value of the virtual camera is CA - FA / 2 to CA + FA / 2 based on the rotation angle CA and the shooting angle FA. Further, the range of the z-axis values within the visible boundary range z min ~z max is as follows:

[0074]

Equation

[0075] Referring to FIG. 8, FIG. 8 is a flowchart showing a method for selecting a virtual object on the user interface of a terminal according to another embodiment of the present application. This method can be applied to a terminal. For example, the execution entity of each block can be the terminal 10 (hereinafter referred to as the "client") in the application execution environment shown in FIG. 1. This method can include several blocks (801~806) as follows.

[0076] In block 801, the user interface is displayed.

[0077] In block 802, obtain a predetermined application area of the first operation of the first virtual object in the virtual environment.

[0078] In block 803, obtain the visible boundary range of the virtual environment.

[0079] In block 804, based on the predetermined application area and the visible boundary range, determine the effective application area of the first operation in the virtual environment.

[0080] The above-mentioned blocks 801 to 804 are the same as blocks 301 to 304 in the embodiment shown in FIG. 3. Although not repeated here, please refer to the embodiment shown in FIG. 3.

[0081] In block 805, determine the second virtual object within the effective application area as the candidate virtual object.

[0082] The second virtual object refers to a virtual object controlled by the user or another user within the application. The candidate virtual object refers to the candidate action target of the above-mentioned first operation. After obtaining the above-mentioned effective application area, the client can use the virtual object within the effective application area as the second virtual object. The second virtual object may include virtual objects in the same camp as the first virtual object, or may include virtual objects in a different camp from the first virtual object.

[0083] In a possible implementation form, after obtaining the above-mentioned effective application area, the client can compare the coordinates of the boundary points of the effective application area with the position coordinates of the virtual object, and then obtain the second virtual object within the effective application area.

[0084] In another possible implementation, to reduce the processing overhead of the terminal, the client can directly determine the second virtual object within the valid application area based on a predetermined application area and a visible boundary range. After obtaining the predetermined application area, the client can obtain the second virtual object within the predetermined application area and obtain the position information of the second virtual object. Further, the client determines whether the second virtual object meets the requirements based on the position information. This requirement is a determination requirement used to determine whether the second virtual object is within the valid application area. If the position information of the second virtual object meets the requirement, the second virtual object is located within the valid application area. If the position information of the second virtual object does not meet the requirement, the second virtual object is not located within the valid application area.

[0085] The aforementioned requirements can include a first requirement and a second requirement. The visible boundary range is a trapezoidal area surrounded by a first edge, a second edge, a third edge, and a fourth edge. On the one hand, the first edge is parallel to the third edge. After obtaining the position information of the second virtual object within the predetermined application area, the client can analyze and detect the position information. If the position information of the aforementioned second virtual object is located between the first edge and the third edge, the client determines that the second virtual object meets the first requirement. If the position information of the aforementioned second virtual object is located between the second edge and the fourth edge, the client determines that the second virtual object meets the second requirement. If the second virtual object meets the first requirement and the second requirement, the client determines that the second virtual object is located within the valid application area.

[0086]

Number

[0087] When the position information of the second virtual object meets the first and second requirements, it is determined that the second virtual object is located within the effective application area.

[0088] The client can select at least one candidate virtual object from a plurality of second virtual objects based on the operation attributes of the aforementioned first operation. The operation attributes include an attack attribute and a gain attribute. The attack attribute means that the aforementioned first operation may reduce the attribute value of other virtual objects. The gain attribute means that the aforementioned first operation may increase the attribute value of other virtual objects. The aforementioned attribute value may include a lifespan value, a defense value, an attack speed, etc., and these are not limited by the embodiments of the present application. When the aforementioned first operation is identified as an attack operation, the client identifies a virtual object belonging to a different camp from the first virtual object within the effective application area as a candidate virtual object. When the aforementioned first operation is identified as a gain operation, the client identifies a virtual object belonging to the same camp as the first virtual object within the effective application area as a candidate virtual object.

[0089] In block 806, based on the object selection criteria, a target virtual object is selected from one or more candidate virtual objects.

[0090] The object selection criteria refer to the method of selecting the action target corresponding to the first action. The object selection criteria include the action range of the first action and the target selection index. The action range of the first action is configured to indicate the effect range of the aforementioned first action. The effect range can be represented by a range with a specific area and shape, or by the number of target virtual objects. The target selection index is configured to indicate the selection criteria for the target virtual object. The selection criteria can be the attribute value of the second virtual object. For example, the selection criteria can be the lifespan value of the second virtual object. Subsequently, the client can select the second candidate virtual object with the minimum lifespan value within the valid application area as the target virtual object.

[0091] In the embodiments of the present application, after obtaining at least one of the aforementioned candidate virtual objects, the client can select a target virtual object from at least one candidate virtual object based on the object selection criteria of the first action. Different actions correspond to different object selection criteria.

[0092] It should be noted that the aforementioned object selection criteria may be rules preset by the designer, or rules that are flexibly changed according to the application. For example, the preset rules may be changed based on the interactive actions or attribute values of the first virtual object. For example, when the number of times the first action of the first virtual object is different, the aforementioned object selection criteria may be different. As another example, when the attack power of the first virtual object is different, the aforementioned object selection criteria may be different, which is not limited by the embodiments of the present application.

[0093] In view of the above, in the technical solution provided by the embodiments of the present application, by selecting a target virtual object corresponding to the first operation from a valid application area, the accuracy of selecting the target virtual object on the user interface of the terminal can be improved. Since the target virtual object is selected based on an object selection criterion, the selection of the target virtual object becomes more flexible.

[0094] Furthermore, based on different effects of the first operation, different target virtual objects are determined, thereby making the selection of the target virtual object more flexible.

[0095] Furthermore, in connection with FIG. 9, a complete introduction of the present application is provided.

[0096] In block 901, the client displays a user interface.

[0097] In block 902, the client obtains relevant parameters regarding a predetermined application area of the first operation of the first virtual object, where the relevant parameters of the predetermined application area include the position information of the first virtual object and a predetermined actual distance of the first operation.

[0098] In block 903, the client obtains a predetermined application area of the first operation based on the relevant parameters of the predetermined application area.

[0099] In block 904, the client obtains the position information of the second virtual object within the predetermined application area.

[0100] In block 905, the client obtains a visible boundary range.

[0101] In block 906, the client determines whether the second virtual object existing within a predetermined application area meets the requirements. If the second virtual object existing within the predetermined application area meets the requirements, the client determines that the second virtual object is located within a valid application area and executes block 907. If the second virtual object existing within the predetermined application area does not meet the requirements, the client determines that the second virtual object is not located within a valid application area and terminates the process.

[0102] In block 907, based on the operation attributes of the first operation, the client can select a virtual object from multiple second virtual objects within the valid application area and use the selected virtual object as a candidate virtual object, where the selected virtual object belongs to the same camp as the first virtual object or belongs to a different camp from the first virtual object.

[0103] In block 908, based on the object selection criteria, the client can select a target virtual object from one or more candidate virtual objects and use the selected target virtual object as the action target of the first operation.

[0104] The following is an apparatus embodiment of the present application that can be configured to execute the method embodiment of the present application. For details not disclosed in the apparatus embodiment of the present application, please refer to the method embodiment of the present application.

[0105] Referring to FIG. 10, FIG. 10 is a block diagram of an apparatus for selecting a virtual object on a user interface of a terminal according to an embodiment of the present invention. This apparatus has a function of implementing the above-described method for selecting a virtual object. Such a function may be implemented by hardware or by hardware that executes corresponding software. This apparatus may be a terminal or may be installed within a terminal. Apparatus 1000 may include an interface display module 1010, a region acquisition module 1020, a boundary acquisition module 1030, a region determination module 1040, and an object determination module 1050.

[0106] The interface display module 1010 is configured to display a user interface. The user interface includes a display screen corresponding to a virtual environment and further includes a first virtual object located within the virtual environment.

[0107] The region acquisition module 1020 is configured to acquire a predetermined application region of a first operation of a first virtual object within the virtual environment.

[0108] The boundary acquisition module 1030 is configured to acquire a visible boundary range of the virtual environment. Virtual objects existing within the visible boundary range are visible on the user interface.

[0109] The region determination module 1040 is configured to determine a valid application region of the first operation within the virtual environment based on the predetermined application region and the visible boundary range.

[0110] The object determination module 1050 is configured to determine a target virtual object based on the effective execution region.

[0111] In an exemplary embodiment, the boundary acquisition module 1030 includes a two-dimensional acquisition unit 1031, a coordinate acquisition unit 1032, and a boundary acquisition unit 1033.

[0112] The two-dimensional acquisition unit 1031 is configured to process a three-dimensional visual representation in a virtual environment and obtain a two-dimensional visual representation of the virtual environment by processing the three-dimensional visual representation.

[0113] The coordinate acquisition unit 1032 is configured to acquire the coordinates of feature points of a visible boundary range in the virtual environment from the two-dimensional visual representation of the virtual environment.

[0114] The boundary acquisition unit 1033 is configured to acquire a visible boundary range based on the coordinates of feature points in the virtual environment.

[0115] In an exemplary embodiment, the boundary acquisition unit 1033 includes a coordinate acquisition subunit.

[0116] The coordinate acquisition subunit is configured to acquire the coordinates of feature points of a visible boundary range in the virtual environment based on the parameters of a virtual camera. The parameters include a position parameter and a rotation parameter. The position parameter is configured to determine the position of the virtual camera in the virtual environment. The rotation parameter is configured to determine the shooting angle value of the virtual camera in the virtual environment.

[0117] In an exemplary embodiment, the coordinate acquisition subunit is configured to adjust the parameters of the virtual camera based on screen parameters and obtain the position parameter and the rotation parameter of the virtual camera through the adjustment process. The screen parameters include parameters of screen size and screen resolution. The coordinate acquisition subunit is configured to acquire the coordinates of feature points of a visible boundary range in the virtual environment based on the position parameter and the rotation parameter.

[0118] In an exemplary embodiment, the area acquisition module 1020 is configured to acquire the position information of a first virtual object in the virtual environment and determine a predetermined application area of a first operation in the virtual environment based on the position information and a predetermined actual travel distance of the first operation.

[0119] In an exemplary embodiment, the object determination module 1050 includes a candidate determination unit 1051 and a target determination unit 1052.

[0120] The candidate determination unit 1051 is configured to determine a second virtual object within a valid application area as a candidate virtual object.

[0121] The target determination unit 1052 is configured to select a target virtual object from one or more candidate virtual objects based on object selection criteria.

[0122] In an exemplary embodiment, the visible boundary range is a trapezoidal area surrounded by a first edge, a second edge, a third edge, and a fourth edge. The first edge is parallel to the third edge. As shown in FIG. 11, the apparatus 1000 further includes a positioning module 1060.

[0123] The positioning module 1060 is configured to obtain position information of a second virtual object within a predetermined application area. When the position information of the second virtual object is located between the first edge and the third edge, the positioning module 1060 is configured to determine that the second virtual object meets the first requirement. When the position information of the second virtual object is located between the second edge and the fourth edge, the positioning module 1060 is configured to determine that the second virtual object meets the second requirement. When the second virtual object meets the first requirement and the second requirement, the positioning module 1060 is configured to determine that the second virtual object is located within a valid application area.

[0124] In an exemplary embodiment, when the first operation is identified as an attack operation, the candidate determination unit 1051 is configured to determine, as candidate virtual objects, virtual objects that belong to a different camp from the first virtual object within the valid application area. Alternatively, when the first operation is identified as a gain operation, the candidate determination unit 1051 is configured to determine, as candidate virtual objects, virtual objects that belong to the same camp as the first virtual object within the valid application area.

[0125] In view of the above, in the technical solution provided by the embodiment of the present application, the valid application area of the first operation is determined based on the predetermined application area of the first operation and the visible boundary range of the virtual environment. The target virtual object corresponding to the first operation is determined based on the valid application area. Subsequently, the target virtual object is located within the visible boundary range, thereby ensuring that the action object of the first operation is within the user's visible range, avoiding misjudgment of operations caused by the next scene, i.e., the scene where the action object is within the user's invisible range, and improving the accuracy of selecting the action target of the first operation.

[0126] Regarding the device provided by the foregoing embodiment, when implementing its functions, it should be noted that only the part of the foregoing functional modules is taken as an example. In actual applications, the foregoing functions may be assigned to different functional modules as needed to achieve them. That is, the internal structure of the device is divided into different functional modules to achieve all or part of the above functions. Furthermore, the devices provided by the foregoing embodiments and method embodiments belong to the same concept. The specific implementation process is not repeated here, but reference can be made to the method embodiments.

[0127] Referring to FIG. 12, FIG. 12 is a block diagram showing the structure of terminal 1200 according to an embodiment of the present application. Terminal 1200 can be an electronic device such as a mobile phone, a tablet computer, a game host, an e - book reader, a multimedia playback device, a wearable device, and a personal computer (PC). The terminal is configured to implement a method for selecting a virtual object provided by the foregoing embodiments. The terminal can be terminal 10 in the game execution environment shown in FIG. 1.

[0128] Generally, terminal 1200 includes a processor 1201 and a memory 1202.

[0129] Processor 1201 can include one or more processing cores, for example, a 4 - core processor, an 8 - core processor, etc. Processor 1201 can be implemented by at least one hardware form, for example, digital signal processing (DSP), field - programmable gate array (FPGA), programmable logic array (PLA). Processor 1201 can also include a main processor and a coprocessor. The main processor is an awake - state processor that processes data and may also be called a central processing unit (CPU). The coprocessor is a low - power processor configured to process data in a standby state. In some embodiments, processor 1201 may be integrated with a graphics processing unit (GPU). The GPU is configured to render and draw the content that needs to be displayed on the display. In some embodiments, processor 1201 may also include an artificial intelligence (AI) processor. The AI processor is configured to process computing operations related to machine learning.

[0130] Memory 1202 may include one or more computer-readable storage media. The computer-readable storage media may be non-transitory. Memory 1202 may also include high-speed random access memory (RAM) and non-transitory memory, such as one or more disk storage devices, flash storage devices. In some embodiments, the non-transitory computer-readable storage media in Memory 1202 is configured to store at least one instruction, at least one program, a code set or an instruction set, wherein at least one instruction, at least one program, a code set or an instruction set is configured and processed by one or more processors to implement the foregoing method for selecting virtual objects.

[0131] In some embodiments, terminal 1200 may also include a peripheral interface 1203 and at least one peripheral device. Processor 1201, Memory 1202, and peripheral interface 1203 may be connected via a bus or signal lines. Each peripheral device may be connected to peripheral interface 1203 via a bus, signal lines, or a circuit board. Specifically, the peripheral device may include at least one of a radio frequency (RF) circuit, a display (e.g., a touch screen) 1205, a camera component 1206, an audio circuit 1207, a positioning component 1208, and a power supply 1209.

[0132] Those skilled in the art can understand that the structure shown in FIG. 12 does not limit terminal 1200. Terminal 1200 may include more or fewer components than those shown in FIG. 12, or some components may be combined, or a different component layout may be adopted.

[0133] In an exemplary embodiment, a computer-readable storage medium is also provided. The storage medium stores at least one instruction, at least one program, a code set, or an instruction set, where when the at least one instruction, at least one program, code set, or instruction set is executed by a processor, the above method for selecting a virtual object is implemented.

[0134] The computer-readable storage medium may include, for example, a read-only memory (ROM), a random access memory (RAM), a solid state drive (SSD), or a compact disc (CD). The RAM may include a resistive random access memory (ReRAM) and a dynamic random access memory (DRAM).

[0135] In an exemplary embodiment, a computer program product is also provided. When the computer program product is executed by a processor, the foregoing method for selecting a virtual object is achieved.

[0136] It should be understood that the "plurality" referred to in this application refers to two or more. "And / or" describes the relevant relationship of the relevant objects, indicating that there can be three relationships. For example, A and / or B can indicate three situations: A exists independently, A and B exist simultaneously, and B exists independently. The character " / " generally represents that there is an "or" relationship between the previous object and the subsequent relevant object. Further, the block numbers described in this application only exemplify one possible execution order between the blocks. In some other embodiments, the foregoing blocks may be executed without following the order of the numbers. For example, two blocks with different numbers may be executed simultaneously, or two blocks with different numbers may be executed in the reverse order shown in the figure, and these are not limited by the embodiments of this application.

[0137] The above is merely an exemplary embodiment of the present application and is not intended to limit the present application. Modifications, equivalent substitutions or improvements made within the scope of the spirit and principle of the present application should be included in the protection scope of the present application.

Claims

Claim 1 A method for selecting a virtual object on a user interface of a terminal, the method being executed by the terminal, the method comprising: displaying a user interface, the user interface including a display screen corresponding to a virtual environment and further including a first virtual object located within the virtual environment; obtaining a predetermined application area of a first operation of the first virtual object within the virtual environment; obtaining a visible boundary range of the virtual environment by using a virtual camera within the virtual environment, wherein virtual objects existing within the visible boundary range are visible on the user interface; determining a valid application area of the first operation within the virtual environment based on the predetermined application area and the visible boundary range; determining a target virtual object corresponding to the first operation based on the valid application area; The step of determining a valid application area of the first operation within the virtual environment based on the predetermined application area and the visible boundary range includes: identifying an intersection area between the predetermined application area and the visible boundary range as the valid application area of the first operation. Claim 2 The step of obtaining the visible boundary range of the virtual environment includes: processing a three-dimensional visual representation of the virtual environment; obtaining a two-dimensional visual representation of the virtual environment by the processing of the three-dimensional visual representation; obtaining coordinates of feature points of the visible boundary range within the virtual environment from the two-dimensional visual representation; obtaining the visible boundary range based on the coordinates of the feature points. The method according to claim 1. Claim 3 The step of obtaining coordinates of feature points of the visible boundary range within the virtual environment includes: obtaining coordinates of the feature points of the visible boundary range within the virtual environment based on parameters of a virtual camera, wherein the parameters include a position parameter and a rotation parameter, the position parameter being configured to determine the position of the virtual camera within the virtual environment, and the rotation parameter being configured to determine a shooting angle value of the virtual camera within the virtual environment. The method according to claim 2. Claim 4 The step of obtaining the coordinates of the feature points in the visible boundary range in the virtual environment based on the parameters of the virtual camera includes: Adjusting the parameters of the virtual camera based on screen parameters; Obtaining the position parameters and rotation parameters of the virtual camera based on the adjustment, where the screen parameters include parameters of screen size and screen resolution; Obtaining the coordinates of the feature points in the visible boundary range in the virtual environment based on the position parameters and rotation parameters. The method according to claim 3 includes the above steps.

5. The step of obtaining a predetermined application area of the first operation of the first virtual object in the virtual environment includes: Obtaining position information of the first virtual object in the virtual environment; Determining the predetermined application area of the first operation in the virtual environment based on the position information and a predetermined implementation distance of the first operation. The method according to any one of claims 1 to 4 includes the above steps.

6. The step of determining a target virtual object corresponding to the first operation based on the effective application area includes: Determining a second virtual object in the effective application area as a candidate virtual object; Selecting the target virtual object from one or more candidate virtual objects based on object selection criteria. The method according to any one of claims 1 to 5 includes the above steps.

7. The visible boundary range is a trapezoidal area surrounded by a first edge, a second edge, a third edge, and a fourth edge. The first edge is parallel to the third edge. The method includes: Obtaining position information of the second virtual object in the predetermined application area; When the position information of the second virtual object is located between the first edge and the third edge, determining that the second virtual object meets the first requirement; When the position information of the second virtual object is located between the second edge and the fourth edge, determining that the second virtual object meets the second requirement; When the second virtual object meets the first requirement and the second requirement, determining that the second virtual object is located within the effective application area. The method according to claim 6 further includes the above steps.

8. The step of determining the second virtual object within the effective application area as the candidate virtual object is The method according to claim 6, wherein when the first action is identified as an attack action, the step of identifying, as the candidate virtual object, a virtual object within the effective application area and belonging to a different camp from the first virtual object is included.

9. The step of determining the second virtual object within the effective application area as the candidate virtual object is The method according to claim 6, wherein when the first action is identified as a gain action, the step of identifying, as the candidate virtual object, a virtual object within the effective application area and belonging to the same camp as the first virtual object is included.

10. An apparatus for selecting a virtual object on a user interface of a terminal, comprising An interface display module configured to display a user interface, wherein the user interface includes a display screen corresponding to a virtual environment and further includes a first virtual object located within the virtual environment; A range acquisition module configured to acquire a predetermined application area of a first action of the first virtual object within the virtual environment; A boundary acquisition module configured to acquire a visible boundary range of the virtual environment by using a virtual camera within the virtual environment, wherein virtual objects existing within the visible boundary range are visible on the user interface; A range determination module configured to determine an effective application area of the first action within the virtual environment based on the predetermined application area and the visible boundary range; An object determination module configured to determine a target virtual object corresponding to the first action based on the effective application area; The range determination module, when determining the effective application area of the first action within the virtual environment based on the predetermined application area and the visible boundary range, identifies an intersection area between the predetermined application area and the visible boundary range as the effective application area of the first action.

11. The boundary acquisition module includes a two-dimensional acquisition unit, a coordinate acquisition unit, and a boundary acquisition unit. The two-dimensional acquisition unit is configured to process the three-dimensional visual representation of the virtual environment and obtain a two-dimensional visual representation of the virtual environment by the processing of the three-dimensional visual representation. The coordinate acquisition unit is configured to obtain coordinates of feature points of the visible boundary range in the virtual environment from the two-dimensional visual representation of the virtual environment. The apparatus according to claim 10, wherein the boundary acquisition unit is configured to obtain the visible boundary range based on the coordinates of the feature points in the virtual environment.

12. The boundary acquisition unit includes a coordinate acquisition subunit. The coordinate acquisition subunit is configured to obtain coordinates of the feature points of the visible boundary range in the virtual environment based on parameters of a virtual camera. The parameters include a position parameter and a rotation parameter. The position parameter is configured to determine the position of the virtual camera in the virtual environment, and the rotation parameter is configured to determine a shooting angle value of the virtual camera in the virtual environment. The apparatus according to claim 11.

13. A terminal including a processor and a memory. The memory stores at least one instruction, at least one program, a code set or an instruction set. When loaded and executed by the processor, the processor is caused to execute a method for selecting a virtual object according to any one of claims 1 to 9. A terminal.

14. A computer program for causing a computer to execute a method for selecting a virtual object according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • Operating control method and device, electronic equipment and storage medium

    CN110141869A

  • Image processing program and image processor

    JP2006155442A

  • On-line game method and on-line game system

    JP2008307387A

  • Imaging apparatus and program

    JP2012100314A

  • Game program, method for providing game, and information processing device

    JP2018057463A