Method and device for locking a target object in a game scene, electronic device and storage medium

DE602018085280T2Active Publication Date: 2025-09-03TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
DE602018085280
Authority / Receiving Office
DE · DE
Patent Type
Patents
Current Assignee / Owner
Priority Date
2017-07-19
Filing Date
2018-07-18
Publication Date
2025-09-03
Estimated Expiration
2038-07-18

AI Technical Summary

Technical Problem

Existing methods for locking onto a target object in game scenes, such as in MOBA and sports action games, are inefficient and time-consuming due to the need for precise joystick adjustments, leading to potential misapplication of skills when there are slight deviations in joystick direction and object movement.

Method used

The method involves dividing the joystick active area into sub-areas corresponding to the number of to-be-applied objects, allowing the joystick to be dragged to any location within the target sub-area, eliminating the need for precise alignment with the object direction, and using coordinate mapping to determine the target object based on relative locations.

Benefits of technology

This approach enhances the speed and precision of locking onto target objects, reducing the time required and minimizing the likelihood of skill misapplication due to slight deviations, thereby improving user experience.

✦ Generated by Eureka AI based on patent content.
Patent Text Reader
Need to check novelty before this filing date? Find Prior Art

Description

RELATED APPLICATION

[0001] This application claims priority to Chinese Patent Application No. 201710591055.8, filed with the Chinese Patent Office on July 19, 2017, and entitled "METHOD AND APPARATUS FOR LOCKING TARGET OBJECT IN GAME SCENE, AND ELECTRONIC DEVICE".FIELD OF THE TECHNOLOGY

[0002] This application relates to the field of data processing technologies, and more specifically, to a method and an apparatus for locking on to a target object in a game scene, an electronic device, and a storage medium.BACKGROUND OF THE DISCLOSURE

[0003] Currently, an application (APP) can implement a function that a user applies a skill to one or more objects (persons or things). For example, in a multiplayer online battle arena (MOBA) game, a skill that may be applied to an enemy includes spell casting, or the like. In a sports action game, a skill that may be applied includes ball passing, or the like. In a process of applying a skill to an object, precisely locking the object is the key.

[0004] CA 2 981 553 A1 concerns an information processing method and terminal, and computer storage medium. The method comprises: upon detection of a skill launch trigger gesture of at least one skill object located in at least one skill operation region of a graphic user interface, rendering the graphic user interface, and obtaining a skill launch aid control object, wherein the skill launch aid control object comprises a skill launch operation halo object and a virtual joystick object within a cover range of the skill launch operation halo object; and determining whether the virtual joystick object is outside of a threshold region, and if the virtual joystick object is not outside of the threshold region, then selecting, according a detected release operation of a drag operation, a target character object satisfying a first predetermined policy from at least one character object in a skill launchable range of the skill object, and performing a skill launch operation on the target character object.

[0005] The paper "X-O Arch Menu: Combining Precise Positioning with Efficient Menu Selection on Touch Devices" by M. Heckel, et.al. provices background art on radial menus.SUMMARY

[0006] The present invention concerns a method for locking on a target object in a game scene using a terminal according to claim 1, and a terminal apparatus for locking on to a target object in a game scene according to the corresponding independent apparatus claim. Further aspects of the present invention are defined in the dependent claims.BRIEF DESCRIPTION OF THE DRAWINGS

[0007] To describe the technical solutions in the embodiments of this application or in the existing technology more clearly, the following briefly introduces the accompanying drawings for describing the embodiments or the existing technology. Apparently, the accompanying drawings in the following description show merely aspects of this application. FIG. 1 is a schematic diagram of applying a skill in an MOBA game according to an embodiment of this application. FIG. 2 is a structural diagram of an electronic device according to an embodiment of this application. FIG. 3 is a schematic interface diagram of a sports action game according to an embodiment of this application. FIG. 4 is a flowchart of a method for locking on to a target object in a game scene according to an embodiment of this application. FIG. 5 is a schematic diagram of sub-areas in an joystick active area according to an embodiment of this application. FIG. 6 is another schematic diagram of sub-areas in an joystick active area according to an embodiment of this application. FIG. 7 is a schematic diagram of mapping a terminal object and two to-be-applied objects to a drawing area in FIG. 3. FIG. 8 is another schematic diagram of mapping a terminal object and two to-be-applied objects to a drawing area in FIG. 3. FIG. 9 is still another schematic diagram of mapping a terminal object and to-be-applied objects to a drawing area according to an embodiment of this application. FIG. 10 is a schematic diagram of a correspondence between sub-areas in an joystick active area and the to-be-applied objects in FIG. 9. FIG. 11 is a schematic structural diagram of an apparatus for locking on to a target object in a game scene according to an embodiment of this application. DESCRIPTION OF EMBODIMENTS

[0008] The technical solutions in the embodiments of this application will be clearly and completely described in the following with reference to the accompanying drawings in the embodiments of this application. It is obvious that the embodiments to be described are only some rather than all of the embodiments of this application.

[0009] A method for locking on to a target object in a game scene according to an embodiment of this application may be applied to a plurality of types of APPs, for example, game APPs for an MOBA game (such as the Super NBA game) and a sports action game. An electronic device or a terminal on which the foregoing types of APPs are installed may have a function shown in the method for locking the target object in the game scene. The electronic device or the terminal may be a notebook computer, a mobile phone, a PAD (a tablet computer), an in-vehicle terminal, an intelligent wearable device, or the like.

[0010] In some embodiments, a user may determine a direction of an object by using a joystick displayed on an APP. Accordingly, the joystick is an operation controller displayed on the APP. For example, the joystick is dragged to a location that indicates the direction of the object and that is in an joystick active area. The following provides descriptions by using a specific example. FIG. 1 is a schematic diagram of applying a skill in an MOBA game. It is assumed that a user object A indicates a user. If the user object A needs to apply a skill to an object B, the user object A may drag, in an joystick active area 11, a joystick 12 to a location indicating a direction of the object B. The location may be specifically a location of the joystick 12 in FIG. 1. After releasing the joystick 12, the user may apply the skill to a dragging direction of the joystick 12. A skill application effect is shown in FIG. 1. In the foregoing process of precisely locking on to an object, the user needs to repeatedly adjust the location of the joystick, increasing a time spent by the user on locking on to the object.

[0011] FIG. 2 is a structural diagram of an electronic device according to an embodiment of this application. The electronic device may include: a display 21, a memory 22, and a processor 23. The display 21 is configured to display an interface of an APP, where a joystick and an joystick active area may be displayed on the interface. For example, the display 21 may display an interface shown in FIG. 1, or may display an interface of a sports action game such as the example shown in FIG. 3.

[0012] The memory 22 is configured to store data and a program that correspond to the APP installed on the electronic device.

[0013] The processor 23 is configured to execute the program. The program is configured to determine at least one to-be-applied object (namely, at least one to-be-applied object corresponding to a skill triggered by a user by using the terminal) corresponding to a skill currently triggered by the terminal. The program is further configured to generate, in an joystick active area, at least one sub-area whose total number equals the total number of the at least one to-be-applied object. The program is further configured to determine, in at least one sub-area, a target sub-area indicated by a joystick corresponding to the skill. The program is further configured to determine, as a target object, a to-be-applied object corresponding to the target sub-area, where one to-be-applied object corresponds to one sub-area. In some embodiments, a quantity of to-be-applied objects is equal to a quantity of sub-areas.

[0014] A terminal object marked by using a triangle in FIG. 3 is an object that is selected on the terminal by the user and that represents the user. The terminal object may pass a basketball to teammates of the terminal object, namely, a to-be-applied object A and a to-be-applied object B. Because there are two to-be-applied objects, the joystick active area may be divided into at least two sub-areas. For example, an area boundary line L1 in FIG. 3 divides the joystick active area 11 into two sub-areas.

[0015] In some embodiments, the terminal object can accurately pass the basketball to the to-be-applied object A only when the joystick 12 is located at a location 1 shown in 301 in FIG. 3. The terminal object can accurately pass the basketball to the to-be-applied object B only when the joystick 12 is located at a location 2 shown in 302 in FIG. 3.

[0016] In some embodiments, when the joystick 12 is at any location in a sub-area to the left of an area boundary line L1, the processor 23 may determine that the user may pass the ball to the to-be-applied object A. When the joystick 12 is at any location in a sub-area to the right of an area boundary line L1, the processor 23 may determine that the user may pass the ball to the to-be-applied object B. Each sub-area includes a plurality of locations indicating different directions, and the locations that indicate the different directions and that are included in each sub-area all correspond to corresponding to-be-applied objects. Therefore, in a process of locking on to the target object, the user may drag the joystick to any location in the target sub-area, without needing to accurately drag the joystick to a location indicating a direction of the target object. Therefore, a fault tolerance range is relatively large. In addition, the technical solution can enable the user to quickly and precisely lock on to one of a plurality of to-be-applied objects, reducing a time spent by the user on locking on to the object. A phenomenon that a skill is not applied to a to-be-applied object and that is caused by a slight deviation between a direction in which the user drags the joystick in the joystick active area and a direction of the to-be-applied object and a slight movement of the to-be-applied object is avoided.

[0017] With reference to the foregoing structure, the following describes in detail the method for locking the target object in the game scene according to various embodiments of this application. FIG. 4 is a flowchart of a method for locking on to a target object in a game scene according to various embodiments. The method includes the following steps.

[0018] Sep S401: Determine at least one to-be-applied object corresponding to a skill currently triggered by a terminal.

[0019] There are a plurality of methods for implementing the "determining at least one to-be-applied object corresponding to a skill currently triggered by a terminal". This embodiment of this application provides but is not limited to the following methods:

[0020] First method: Obtain a category of the currently triggered skill; and determine, as a to-be-applied object, an object to which a skill of the category can be applied.

[0021] In some cases, different skills have different to-be-applied objects. For example, if a skill is "ball passing", a to-be-applied object is a member of one's own team, but not necessarily a teammate member of an opposite team. For example, if a skill is "spell casting attack", a to-be-applied object is an "enemy", but not necessarily one's own teammate.

[0022] Second method: Obtain an application range corresponding to the skill; and determine the at least one to-be-applied object according to the application range.

[0023] There are a plurality of implementations of "determining the at least one to-be-applied object according to the application range". This embodiment of this application provides but is not limited to the following implementations:

[0024] First implementation: Determine, as the to-be-applied object, an object located in the application range corresponding to the skill.

[0025] In some cases, different skills may have different application ranges. For example, application ranges of some skills are an entire map, and application ranges of some skills are a circle whose center is a location at which a terminal object is located and whose radius is a preset distance. Application ranges of some skills are a range currently displayed on a display. For example, in a basketball game, when a user is preparing to pass a ball, an application range of the skill may be a range currently displayed on a display.

[0026] Second implementation: Determine, as the to-be-applied object, an object that is located in the application range corresponding to the skill and to which the skill can be applied.

[0027] In the embodiment shown in FIG. 3, because the currently triggered skill is "ball passing", the object A and the object B are teammates of the user, and the object A and the object B are both in a range currently displayed on a display, the object A and the object B are to-be-applied objects. In some embodiments, FIG. 3 may be a game scene in the Super NBA game.

[0028] Third implementation: It is assumed that, the application range corresponding to the skill includes the terminal object and at least two objects, the "determining the at least one to-be-applied object according to the application range" may include: separately connecting a location of the terminal object and locations of the objects located in the application range, to form a connection straight line; and determining, as the to-be-applied object, an object that is on the connection straight line and that is closest to the location of the terminal object.

[0029] In an example process of applying a skill to the target object, to enable the user to have a better experience effect, for a direction in which the skill is applied, a map location at which the terminal object is located may be a start point, and a direction of a connection line between the location of the terminal object and a location of the target object may be the direction in which the skill is applied. During application, a plurality of objects and the terminal object may be located on the same straight line. Because directions in which the terminal object applies the skill to the plurality of objects are the same, an object to which the skill is applied cannot be determined. Therefore, an object that is on the connection straight line and that is closest to the terminal object is determined as the to-be-applied object. This includes two cases:

[0030] In some cases, if the connection straight line includes a location of only one object, the object is determined as the to-be-applied object. In other words, when the connection straight line includes a location of only one object, the object is the object closet to the location of the terminal object.

[0031] In some cases, if the connection straight line includes locations corresponding to at least two objects, an object in the at least two objects that is closest to the location of the terminal object is determined as the to-be-applied object.

[0032] In some cases, the locations may be locations of the terminal object and the objects on a map, or may be locations that are in a drawing area in the background and to which locations of the terminal object and the objects are mapped.

[0033] Step S402: Generate, in an joystick active area, at least one sub-area whose total number equals the total number of the at least one to-be-applied object, where one sub-area corresponds to one to-be-applied object.

[0034] There are a plurality of methods for "generating, in an joystick active area, at least one sub-area whose total number equals the total number of the at least one to-be-applied object". This embodiment of this application provides to the following methods:

[0035] First method, not relating to the claimed invention: When the quantity of to-be-applied objects is one, the joystick active area is a sub-area corresponding to the to-be-applied object.

[0036] Second method, not relating to the claimed invention: When the quantity of to-be-applied objects is M, and M is greater than or equal to 2, the joystick active area may be evenly divided into M sub-areas.

[0037] According to the invention, a third method is provided: When the quantity of to-be-applied objects is M, wherein M equals 2 or 3, the sub-area corresponding to the quantity of the at least one to-be-applied object may be generated in the joystick active area based on a relative location relationship between the terminal object and the to-be-applied objects.

[0038] For example, in FIG. 3, because the object A is to the left of the terminal object and the object B is to the right of the terminal object, a sub-area to the left of the area boundary line L1 corresponds to the object A, and a sub-area to the right of the area boundary line L1 corresponds to the object B.

[0039] Step S403: Determine, in at least one sub-area, a target sub-area indicated by a joystick corresponding to the skill.

[0040] In this embodiment of this application, the target sub-area indicated by the joystick corresponding to the skill includes the following cases:

[0041] First case: The joystick can move only in the joystick active area, and / or on an area edge of the joystick active area, and then the target sub-area indicated by the joystick is a target sub-area in which the joystick is located.

[0042] FIG. 5 is a schematic diagram of sub-areas in an joystick active area according to an embodiment of this application. In this embodiment, descriptions are provided by using an example in which the joystick active area includes three sub-areas. The three sub-areas are respectively: a sub-area 1, a sub-area 2, and a sub-area 3.

[0043] The joystick 12 may move in the joystick active area, for example, a location 3 shown in 501 in FIG. 5; and / or the joystick 12 may move on the area edge of the joystick active area, for example, a location 4 shown in 502 in FIG. 5. No matter whether the joystick is at the location 3 or at the location 4, the processor determines that the joystick 12 is in the sub-area 1.

[0044] Second case: The joystick may move on an entire interface currently displayed on a display 21, and the target sub-area indicated by the joystick may be a target sub-area in which the joystick is located, or may be a sector radiation area of a target sub-area in which the joystick is located.

[0045] FIG. 6 is another schematic diagram of sub-areas in an joystick active area according to an embodiment of this application. In this embodiment, descriptions are provided by using an example in which the joystick active area includes three sub-areas. The three sub-areas are respectively: a sub-area 1, a sub-area 2, and a sub-area 3.

[0046] The joystick 12 may move in the joystick active area, for example, a location 3 shown in 601 in FIG. 6; and / or the joystick may move on an area edge of the joystick active area, for example, a location 4 shown in 602 in FIG. 6; and / or the joystick may move on an external side of an area edge of the joystick active area, for example, a location 5 shown in 603 in FIG. 6. In conclusion, the joystick may move at any location on an interface displayed on the display 21.

[0047] Dashed extension lines of area boundary lines (solid lines shown in 604) in FIG. 6 are sector radiation areas of the sub-areas. If the joystick 12 is located in a sector radiation area of a sub-area, the processor determines that the joystick 12 indicates the sub-area. For example, if the joystick 12 is at the location 5 shown in 603 in FIG. 6, the processor determines that the target sub-area indicated by the joystick is the sub-area 1.

[0048] Step S404: Determine, as a target object, a to-be-applied object corresponding to the target sub-area.

[0049] Because one sub-area corresponds to one to-be-applied object, after the target sub-area indicated by the joystick is determined, the to-be-applied object corresponding to the target sub-area may be determined as the target object.

[0050] Using FIG. 3 as an example, the area boundary line L1 and the area edge of the joystick active area form an area boundary that divides sub-areas. The area boundary divides the joystick active area into two sub-areas.

[0051] If the joystick 12 is located at any location in the sub-area to the left of the area boundary line L1, such as the location 1 shown in 301 in FIG. 3, the sub-area to the left of the area boundary line L1 is determined as the target sub-area, and the object A corresponding to the sub-area is the target object. If the joystick 12 is located at any location in the sub-area to the right of the area boundary line L2, such as the location 2 shown in 302 in FIG. 3, the sub-area to the right of the area boundary line L1 is determined as the target sub-area, and the object B corresponding to the sub-area is the target object.

[0052] When the user determines to apply a skill (for example, release the joystick), the corresponding skill is applied to the target object.

[0053] According to the method for locking on the target object in the game scene provided in this embodiment of this application, the at least one to-be-applied object corresponding to the skill currently triggered by the terminal is first determined. Then, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object is generated in the joystick active area; the target sub-area indicated by the joystick corresponding to the skill is determined in the at least one sub-area, and the to-be-applied object corresponding to the target sub-area is determined as the target object. Each sub-area may include a plurality of locations indicating different directions, and that locations that indicate the different directions and that are included in each sub-area all correspond to corresponding to-be-applied object. Therefore, in a process of locking the target object by using the terminal, the user may drag the joystick to any location in the target sub-area, without needing to accurately drag the joystick to a location indicating a direction of the target object. Therefore, a fault tolerance range is relatively large. In addition, the user can be enabled to quickly and precisely lock one of a plurality of to-be-applied objects, reducing a time spent by the user on locking the object. A phenomenon that a skill is not applied to a to-be-applied object and that is caused by a slight deviation between a direction in which the user drags the joystick in the joystick active area and a direction of the to-be-applied object and a slight movement of the to-be-applied object is avoided.

[0054] In a process of generating a sub-area in the joystick active area, to more comply with a behavior habit of the user, for example, if the target object is located to the upper left of the terminal object, the user usually drags the joystick to an upper left side of the joystick active area. Therefore, in some embodiments, a specific implementation of step S402 may be the foregoing third implementation. The following specifically describes this implementation.

[0055] Step S402 may specifically include: determining a relative location relationship between the at least one to-be-applied object and a terminal object that represents the terminal; and generating, in the joystick active area according to the relative location relationship, at least one sub-area whose total number equals the total number of the at least one to-be-applied object.

[0056] Accordingly, generating a sub-area in the joystick active area may include obtaining an area boundary for distinguishing each sub-area. In some cases, in a process of obtaining the area boundary of each sub-area, the electronic device may perform the obtaining in the background. Therefore, locations of the terminal object and the at least one to-be-applied object on the map may be mapped to corresponding locations in the drawing area in the background.

[0057] Accordingly, the generating, in the joystick active area according to the relative location relationship, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object includes: mapping locations of the terminal object and the at least one to-be-applied object on a map to corresponding locations in a drawing area; and generating, in the joystick active area according to the corresponding locations of the terminal object and the at least one to-be-applied object in the drawing area, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object.

[0058] The locations provided in this embodiment of this application may refer to corresponding location coordinates.

[0059] A coordinate system corresponding to the terminal object and the at least one to-be-applied object displayed on the display may be a two-dimensional coordinate system, a three-dimensional coordinate system, or the like, and a coordinate system corresponding to the joystick active area is usually a two-dimensional coordinate system. Therefore, when the locations of the terminal object and the at least one to-be-applied object are mapped to the drawing area in the background, coordinate system conversion may be further required. There are a plurality of coordinate system conversion manners. This embodiment of this application provides but is not limited to the following method: If a coordinate system corresponding to coordinates of the terminal object and the at least one to-be-applied object is a three-dimensional coordinate system, in a process of mapping the locations to the corresponding locations in the drawing area in the background, a coordinate that is used for representing a height from the ground and that is in the coordinates of the terminal object and the at least one to-be-applied object may be deleted. This may be used to obtain two-dimensional coordinates of the terminal object and the at least one to-be-applied object. If a coordinate system of the location coordinates of the terminal object and the at least one to-be-applied object is the same as a coordinate system of the joystick active area, no coordinate conversion may necessarily be performed.

[0060] In a process of mapping locations of the terminal object and the at least one to-be-applied object on a map to corresponding locations in a drawing area, the location of the terminal object on the map may be first mapped to a first preset location in the drawing area, and then the at least one to-be-applied object is mapped to the corresponding location in the drawing area based on the relative location relationship between the terminal object and the at least one to-be-applied object on the map; or a location of the first to-be-applied object in the at least one to-be-applied object on the map is first mapped to the drawing area. Then, locations of the terminal object and the other to-be-applied object on the map are mapped to the drawing area based on locations of the terminal object and the other to-be-applied object relative to the first to-be-applied object on the map.

[0061] In the process of mapping locations of the terminal object and the at least one to-be-applied object on a map to corresponding locations in a drawing area, mapping with a proportion of 1:1 may be directly performed in the drawing area according to the location coordinate of the terminal object and the location coordinate of the at least one to-be-applied object. For example, if a lateral distance is five meters and a longitudinal distance is six meters between the terminal object and the first to-be-applied object, a lateral distance is five meters and a longitudinal distance is six meters between the terminal object and the first to-be-applied object in the drawing area. Mapping with a preset proportion may be performed. For example, if a lateral distance is five meters and a longitudinal distance is six meters between the terminal object and the first to-be-applied object, a lateral distance is five centimeters and a longitudinal distance is six centimeters between the terminal object and the first to-be-applied object in the drawing area.

[0062] A specific value of the preset proportion may be determined according to an actual case, and is not limited herein.

[0063] To ensure that the relative location relationship between the terminal object and the at least one to-be-applied object is not changed, in a process of mapping, a preset proportion of a relative distance between the terminal object and the at least one to-be-applied object is the same.

[0064] Because coordinate systems of the location of the joystick active area, the location of the terminal object, and the coordinate of the at least one to-be-applied object that are mapped in the drawing area are the same coordinate system, the area boundary of each sub-area may be directly determined in the drawing area. Specifically, the generating, in the joystick active area according to the corresponding locations of the terminal object and the at least one to-be-applied object in the drawing area, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object includes: determining, based on relative locations of the terminal object and each to-be-applied object in the drawing area, an area boundary used for distinguishing each sub-area; and generating, in the joystick active area based on each area boundary, the at least one sub-area whose total number equals the total number of to-be-applied objects.

[0065] There are a plurality of manners of determining, based on relative locations of the terminal object and each to-be-applied object in the drawing area, an area boundary used for distinguishing each sub-area. This embodiment of this application provides the following manners: First manner, not relating to the claimed invention: The quantity of to-be-applied objects is one.

[0066] The sub-area is the joystick active area, and the area boundary used for distinguishing the sub-area is the area edge of the joystick active area.

[0067] Second manner, according to the invention: The quantity of each to-be-applied object is two.

[0068] First, locations of the two to-be-applied objects in the drawing area are connected.

[0069] In some cases, location coordinates of the two to-be-applied objects in the drawing area may be connected.

[0070] Second, after locations of the two to-be-applied objects in the drawing area are connected, a connection line segment may be obtained.

[0071] Because there are only two to-be-applied objects, it may be considered that only one connection line segment is obtained. Alternatively, it may be considered that two overlapped connection line segments are obtained. In this case, a start location of one connection line segment is an end location of the other connection line segment, and an end location of the one connection line segment is a start location of the other connection line segment. In this embodiment of this application, overlapped connection line segments are allowed to serve as two connection line segments only when the quantity of to-be-applied object is two, and overlapped connection line segments are one connection line segment when the quantity of to-be-applied objects is three.

[0072] Third, a target point that is not an endpoint is determined in the obtained connection line segment. Accordingly, the target point is a middle point of the connection line segment.

[0073] Then, the first preset location is connected to the target point, to form at least one quasi-boundary straight line whose total number equals the total number of connection line segments, where the first preset location is a location of the terminal object in the drawing area.

[0074] Finally, an area boundary line corresponding to each quasi-boundary straight line is formed by using a second preset location in a mapping area corresponding to the joystick active area in the drawing area, to form an area boundary.

[0075] FIG. 7 is a schematic diagram of an example mapping of a terminal object and two to-be-applied objects to an example drawing area in FIG. 3. In some embodiments, FIG. 7 may be a game scene in the Super NBA game.

[0076] Assuming that a location of the terminal object in the drawing area is a first preset location C, a location of the object A in the drawing area is a location A, and a location of the object B in the drawing area is a location B, by connecting the location A and the location B, a connection line segment AB may be obtained, or a connection line segment AB and a connection line segment BA may be obtained.

[0077] The terminal object at the preset location C may pass a basketball to the object A, or may pass a basketball to the object B.

[0078] Assuming that only the connection line segment AB is obtained and a target point of the determined connection line segment AB is a point D, the first preset location C and the point D are connected to obtain a quasi-boundary straight line L2.

[0079] The area boundary line corresponding to each quasi-boundary straight line is formed by using the second preset location in a mapping area corresponding to the joystick active area in the drawing area, for example, the location shown by the black point in FIG. 7. Accordingly, the second preset location may be a circle center of the joystick active area. A parallel line L1 of L2 is drawn by using the second preset location. L1 is an area boundary line, and two ends of the area boundary line L1 are located on the area edge of the joystick active area, for example.

[0080] The area boundary line L1 and the area edge of the joystick active area form the area boundary, and each area boundary divides the joystick active area into two sub-areas.

[0081] When the connection line segment AB and the connection line segment BA are obtained (refer to FIG. 8) the target point of the determined connection line segment AB is the point D, and a target point of the determined connection line segment BA is a point F that overlaps the point D (or that may not coincide with the point D, where this is only an example for description herein), the first preset location C and the point D are connected, and the first preset location C and the point F are connected, to obtain a quasi-boundary straight line L2 and a quasi-boundary straight line L3. An area boundary line L4 corresponding to the quasi-boundary straight line L2 and an area boundary line L5 corresponding to the quasi-boundary straight line L3 are obtained by using the second preset location. One end of the area boundary line L4 is the second preset location, and the other end is located on the area edge of the joystick active area. One end of the area boundary line L5 is the second preset location, and the other end is located the edge of the joystick active area.

[0082] The area boundary line L4, the area boundary line L5, and the area edge of the joystick active area form the area boundary, and each area boundary divides the joystick active area into two sub-areas.

[0083] Third manner, according to the invention: The quantity of each to-be-applied object is three.

[0084] This method includes: successively connecting the location of each to-be-applied object in the drawing area, to obtain a plurality of connection line segments, where one location is an endpoint of two connection line segments; respectively determining, in each connection line segment, a target point that is not the endpoint; separately connecting a first preset location and each target point, to form at least one quasi-boundary straight line whose total number equals the total number of connection line segments, where the first preset location is a location of the terminal object in the drawing area; and forming, by using a second preset location in a mapping area corresponding to the joystick active area in the drawing area, an area boundary line corresponding to each quasi-boundary straight line, to form an area boundary.

[0085] FIG. 9 is yet another schematic diagram of an example mapping of a terminal object and to-be-applied objects to a drawing area according to an embodiment of this application. Accordingly, descriptions are provided by using an example in which a quantity of to-be-applied objects is three. In some cases, locations of the to-be-applied objects in the drawing area are respectively a location A, a location B, and a location G, and a location of the terminal object in the drawing area is a first preset location C.

[0086] The locations of the to-be-applied objects in the drawing area are successively connected, to obtain a plurality of connection line segments. Accordingly, the locations of the to-be-applied objects in the drawing area may be successively connected along a clockwise direction or an anticlockwise direction. As shown in FIG. 9, AB, BG, and GA may be successively connected, to obtain three connection line segments AB, BG, and GA; GB, BA, and AG may be successively connected, to obtain three connection line segments GB, BA, and AG; AG, GB, and BA may be successively connected; or the like.

[0087] Various techniques may be used to connect the locations of the to-be-applied objects in the drawing area, provided that the method enables each location to be endpoints of two line segments. In addition, the locations of the to-be-applied objects in the drawing area are successively connected, to form a closed graph. This case is also applicable to a case in which the quantity of to-be-applied objects is two. A specific manner may be shown in FIG. 7, and details are not described herein again.

[0088] When the three obtained connection line segments are a connection line segment AB, a connection line segment BG, and a connection line segment GA, and when a target point determined in the connection line segment AB is H, a target point determined in the connection line segment BG is K, and a target point determined in the connection line segment GA is N. The first preset location C is connected to the target point H, to obtain a quasi-boundary straight line CH. The first preset location C is connected to the target point K to obtain a quasi-boundary straight line CK The first preset location C is connected to the target point N to obtain a quasi-boundary straight line CN.

[0089] Accordingly, forming, by using a second preset location in a mapping area corresponding to the joystick active area in the drawing area, an area boundary line corresponding to each quasi-boundary straight line may include successively obtaining, through the second preset location along a clockwise direction or an anticlockwise direction, the area boundary line corresponding to each quasi-boundary straight line.

[0090] For example, successively along the clockwise direction or the anticlockwise direction, an area boundary line L6 corresponding to the quasi-boundary straight line CH is obtained. For example, a parallel line L6 of CH is drawn by using the second preset location and an area boundary line L7 corresponding to the quasi-boundary straight line CK is obtained. For example, a parallel line L7 of CK is drawn by using the second preset location, and an area boundary line L8 corresponding to the quasi-boundary straight line CN is obtained. For example, a parallel line L8 of CN is drawn by using the second preset location.

[0091] Accordingly, forming, by using a second preset location in a mapping area corresponding to the joystick active area in the drawing area, an area boundary line corresponding to each quasi-boundary straight line may include determining, as a sequence of obtaining the area boundary line corresponding to each quasi-boundary straight line, a sequence of successively going through each connection line segment along the clockwise direction or the anticlockwise direction. The area boundary line corresponding to each quasi-boundary straight line is successively obtained along the clockwise direction or the anticlockwise direction according to the sequence of obtaining the area boundary line, by using the second preset location as an endpoint of the area boundary line.

[0092] For example, if the sequence of successively going through each connection line segment along the clockwise direction is the connection line segment AB, the connection line segment BG, and the connection line segment GA, the sequence of obtaining the area boundary line includes:

[0093] First, an area boundary line of the quasi-boundary straight line CH corresponding to the connection line segment AB is obtained. Then, quasi-boundary straight line CK corresponding to the connection line segment BG is obtained. Then, an area boundary line of the quasi-boundary straight line CN corresponding to the connection line segment GA is obtained.

[0094] In a process of obtaining the area boundary lines through the second preset location, the area boundary line L6 of the quasi-boundary straight line CH is first obtained. When the area boundary line corresponding to each quasi-boundary straight line is obtained along the clockwise direction, the obtained area boundary line L7 of the quasi-boundary straight line CK is to the right of the area boundary line L6, and the obtained area boundary line L8 of the quasi-boundary straight line CN is to the right of the area boundary line L7. For an example case, the area boundary line L6, the area boundary line L7, and the area boundary line L8 that are obtained are shown in FIG. 9.

[0095] One endpoint of the area boundary line L6, the area boundary line L7, and the area boundary line L8 is the second preset location, and the other endpoint is on the area edge of the joystick active area. The area boundary line L6, the area boundary line L7, the area boundary line L8, and the edge of the joystick active area form area boundaries used for distinguishing sub-areas. The joystick active area is divided into three sub-areas, respectively: a sub-area A corresponding to a to-be-applied object located at a location A; a sub-area B corresponding to a to-be-applied object located at a location B; and a sub-area G corresponding to a to-be-applied object located at a location G.

[0096] An area boundary line corresponding to each quasi-boundary straight line is formed by using a second preset location in the joystick active area located in the drawing area, to form an area boundary includes: successively drawing, in the mapping area corresponding to the joystick active area in the drawing area, an area boundary line respectively parallel to each quasi-boundary straight line by using the second preset location as an endpoint of the area boundary line, where the other endpoint of the area boundary line is on an area edge of the joystick active area.

[0097] Accordingly, the area boundary line respectively parallel to each quasi-boundary straight line is successively drawn along the clockwise direction or the anticlockwise direction by using the second preset location as the endpoint of the area boundary line.

[0098] In some embodiments, the first preset location and the second preset location are the same location, and certainly, the first preset location and the second preset location may be different locations.

[0099] In some embodiments, to remind a user which to-be-applied object is a currently locked on target object, a preset identifier used for representing that the target object is a locked on to-be-applied object may be displayed at a preset location of the target object.

[0100] As shown in FIG. 3, when the joystick 12 is located at the location 1 shown in 301, the target object is an object A, and preset identifiers such as five-pointed stars and arrows may be displayed on the top, the bottom, a left side, and a right side of the target object A.

[0101] Information, such as a profile picture and a name, used for representing each to-be-applied object may be further displayed surrounding the joystick active area. FIG. 10 is a schematic diagram of a correspondence between sub-areas in an joystick active area and the to-be-applied objects in FIG. 9.

[0102] The joystick active area shown in FIG. 10 includes: a sub-area A, a sub-area B, and a sub-area G. Information (such as a profile picture) about a to-be-applied object corresponding to each sub-area may float, surrounding the joystick active area, on a side of the corresponding sub-area. When a user drags a joystick, a sub-area corresponding to a to-be-applied object may be quickly determined, so that a target area may be quickly determined in a plurality of sub-area, and the joystick may be dragged to the target area.

[0103] An embodiment of this invention further provides a terminal apparatus for locking on to a target object in a game scene corresponding to a method for locking on to a target object in a game scene. A plurality of modules in the apparatus for locking on to a target object in a game scene that are described in the following may be correspondingly cross-referenced with the steps in the method for locking on to a target object in a game scene that are described in the foregoing.

[0104] FIG. 11 is a schematic structural diagram of an apparatus for locking on to a target object in a game scene. The apparatus for locking the target object in the game scene includes: a first determining module 111, configured to determine at least one to-be-applied object corresponding to a skill currently triggered by a terminal; a generation module 112, configured to generate, in an joystick active area, at least one sub-area whose total number equals the total number of the at least one to-be-applied object, one sub-area corresponding to one to-be-applied object; a second determining module 113, configured to determine, in at least one sub-area, a target sub-area indicated by a joystick corresponding to the skill; and a third determining module 114, configured to determine, as a target object, a to-be-applied object corresponding to the target sub-area.

[0105] Accordingly, the generation module includes: a first determining unit, configured to determine a relative location relationship between the at least one to-be-applied object and a terminal object that represents the terminal; and a generation unit, configured to generate, in the joystick active area according to the relative location relationship, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object.

[0106] Accordingly, the generation unit includes: a mapping subunit, configured to map locations of the terminal object and the at least one to-be-applied object on a map to corresponding locations in a drawing area; and a generation subunit, configured to generate, in the joystick active area according to the corresponding locations of the terminal object and the at least one to-be-applied object in the drawing area, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object.

[0107] According to the invention, the quantity of the at least one to-be-applied object is 2 or 3, and the generation subunit includes: a first determining submodule, configured to determine, based on relative locations of the terminal object and each to-be-applied object in the drawing area, an area boundary used for distinguishing each sub-area; and a generation submodule, configured to generate, in the joystick active area based on each area boundary, the at least one sub-area whose total number equals the total number of to-be-applied objects.

[0108] Accordingly, the first determining submodule includes: a first obtaining submodule, configured to successively connect the location of each to-be-applied object in the drawing area, to obtain a plurality of connection line segments, where one location is an endpoint of two connection line segments; a target point determining submodule, configured to respectively determine, in each connection line segment, a target point that is not the endpoint; a first formation submodule, configured to separately connect a first preset location and each target point, to form at least one quasi-boundary straight line whose total number equals the total number of connection line segments, where the first preset location is a location of the terminal object in the drawing area; and a second formation submodule, configured to form, by using a second preset location in a mapping area corresponding to the joystick active area in the drawing area, an area boundary line corresponding to each quasi-boundary straight line, to form an area boundary.

[0109] Accordingly, the second formation submodule includes: a second obtaining submodule, configured to successively draw, in a mapping area corresponding to the joystick active area in the drawing area, an area boundary line respectively parallel to each quasi-boundary straight line by using the second preset location as an endpoint of the area boundary line, where the other endpoint of the area boundary line is on an area edge of the joystick active area.

[0110] Accordingly, the second obtaining submodule is specifically configured to: in a mapping area corresponding to the joystick active area in the drawing area, successively draw, along a clockwise direction or an anticlockwise direction, the area boundary line respectively parallel to each quasi-boundary straight line by using the second preset location as the endpoint of the area boundary line.

[0111] Accordingly, a target point is a middle point of a corresponding connection line segment, and / or the second preset location is a circle center of the joystick active area.

[0112] In some embodiments, the first determining module includes: a first obtaining unit, configured to obtain an application range corresponding to the skill; and a second determining unit, configured to determine the at least one to-be-applied object according to the application range.

[0113] In some embodiments, the second determining unit is specifically configured to determine, as the to-be-applied object, an object that is in the application range and to which the skill may be applied.

[0114] In some embodiments, the application range includes the terminal object and at least two objects, and the second determining unit includes: a formation subunit, configured to separately connect a location of the terminal object and locations of the objects located in the application range, to form a connection straight line; and a determining subunit, configured to determine, as the to-be-applied object, an object that is on the connection straight line and that is closest to the location of the terminal object.

[0115] In some embodiments, the apparatus further includes: a display module, configured to display, at a preset location of the target object, a preset identifier used for representing that the target object is a locked to-be-applied object.

[0116] An embodiment of this application further provides an electronic device. A structural diagram of the electronic device is shown in FIG. 2. In addition to a display 21, a memory 22, and a processor 23 shown in FIG. 2, the electronic device may further include: a communications interface and a communications bus. The display 21, the processor 23, the communications interface, and the memory 22 communicate with each other by using the communications bus.

[0117] In some embodiments, the communication interface may be an interface of a communications module, for example, an interface of a GSM module.

[0118] The processor 23 may be a central processing unit (CPU) or an application-specific integrated circuit (ASIC), or may be one or more integrated circuits configured to implement the embodiments of this application.

[0119] The memory 22 may include a high-speed RAM memory, and may further include a non-volatile memory, for example, at least one magnetic disk memory.

[0120] The processor 23 may execute a program stored in the memory 22, and the program is specifically configured to perform a method according to any of claims 1 to 5.

[0121] At last, it should be noted that the relational terms herein such as first and second are used only to differentiate an entity or operation from another entity or operation, and do not require or imply any actual relationship or sequence between these entities or operations. Moreover, the term "include", "include", or any variant thereof is intended to cover a non-exclusive inclusion. Therefore, in the context of a process, a method, an object, or a device that includes a series of elements, the process, method, object, or device not only includes such elements, but also includes other elements not specified expressly, or may include inherent elements of the process, method, object, or device. When there is no more restriction, an element limited by "include a / an..." does not exclude other same elements existing in the process, the method, the article, or the device that includes the element.

[0122] The embodiments in this specification are all described in a progressive manner. Descriptions of each embodiment focus on differences from other embodiments, and same or similar parts among the embodiments may be mutually referenced.

Claims

1. A computer-implemented method for locking on to a target object in a game scene using a terminal, the method comprising: determining (S401) at least one to-be-applied object corresponding to a skill currently triggered by the terminal, the skill being a game skill; generating (S402), in a joystick active area (11) of a joystick (12), at least one sub-area whose total number equals a total number of the at least one to-be-applied object, each sub-area corresponding to a to-be-applied object, wherein the joystick (12) is an operation controller displayed on an application installed on the terminal and operable by a finger of a user, and the application is a game; determining (S403), in the at least one sub-area, a target sub-area indicated by the joystick (12) corresponding to the skill; and determining (S404) a to-be-applied object corresponding to the target sub-area as a target object, wherein the generating (S402), in a joystick active area, at least one sub-area whose total number equals a total number of the at least one to-be-applied object comprises: determining a relative location relationship between the at least one to-be-applied object and a terminal object that represents the terminal; and generating, in the joystick active area according to the relative location relationship, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object, wherein the generating (S402), in the joystick active area according to the relative location relationship, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object comprises: mapping locations of the terminal object and the at least one to-be-applied object in a map onto corresponding locations in a drawing area of the application; and generating, in the joystick active area according to the corresponding locations of the terminal object and the at least one to-be-applied object in the drawing area, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object, wherein the total number of the at least one to-be-applied object is 2 or 3, and the generating (S402), in the joystick active area according to the corresponding locations of the terminal object and the at least one to-be-applied object in the drawing area, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object comprises: determining, based on relative locations of the terminal object and each to-be-applied object in the drawing area, at least one area boundary for distinguishing each sub-area; and generating, in the joystick active area based on each area boundary, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object, wherein the determining, based on relative locations of the terminal object and each to-be-applied object in the drawing area, at least one area boundary used for distinguishing each sub-area comprises: successively connecting a location of each to-be-applied object in the drawing area, to obtain a plurality of connection line segments, wherein the location is an endpoint of two connection line segments; respectively determining, in each connection line segment, a target point that is not an endpoint; respectively connecting a first preset location with each target point, to form at least one quasi-boundary straight line whose total number equals a total number of the connection line segments, wherein the first preset location is a location of the terminal object in the drawing area; and forming, by using a second preset location in a mapping area corresponding to the joystick active area in the drawing area, an area boundary line corresponding to each quasi-boundary straight line, to form an area boundary, wherein the second preset location is a circle center of the joystick active area, wherein the forming, by using a second preset location mapped to the drawing area from the joystick active area, an area boundary line corresponding to each quasi-boundary straight line comprises: successively drawing, in the mapping area corresponding to the joystick active area in the drawing area, an area boundary line parallel to each quasi-boundary straight line respectively by using the second preset location as an endpoint of the area boundary line, wherein the other endpoint of the area boundary line is on an area edge of the joystick active area, wherein the successively drawing an area boundary line parallel to each quasi-boundary straight line respectively by using the second preset location as an endpoint of the area boundary line comprises: successively drawing, along a clockwise direction or an anticlockwise direction, the area boundary line parallel to each quasi-boundary straight line respectively by using the second preset location as the endpoint of the area boundary line, and wherein a target point is a middle point of a corresponding connection line segment, and the second preset location is a circle center of the joystick active area.

2. The method according to claim 1, wherein the determining at least one to-be-applied object corresponding to a skill currently triggered by the terminal comprises: obtaining an application range corresponding to the skill; and determining the at least one to-be-applied object according to the application range.

3. The method according to claim 2, wherein the determining the at least one to-be-applied object according to the application range comprises: determining, as the to-be-applied object, an object that is in the application range and to which the skill may be applied.

4. The method according to claim 2, wherein the application range comprises the terminal object and at least two objects, and the determining the at least one to-be-applied object according to the application range comprises: separately connecting a location of the terminal object and locations of the objects located in the application range, to form a connection straight line; and determining, as the to-be-applied object, an object that is on the connection straight line and that is closest to the location of the terminal object.

5. The method according to claim 1, further comprising: displaying, at a preset location of the target object, a preset identifier used for representing that the target object is a locked on to-be-applied object.

6. A terminal apparatus for locking on to a target object in a game scene, the terminal comprising: a processor, a memory, and a display, the processor configured to provide: a first determining module (111), configured to determine at least one to-be-applied object corresponding to a skill currently triggered by the terminal, the skill being a game skill; a generation module (112), configured to generate, in a joystick active area (11) of a joystick (12), at least one sub-area whose total number equals a total number of the at least one to-be-applied object, each sub-area corresponding to a to-be-applied object, wherein the joystick (12) is an operation controller displayed on an application installed on the terminal and operable by a finger of a user, and the application is a game; a second determining module (113), configured to determine, in the at least one sub-area, a target sub-area indicated by the joystick corresponding to the skill; and a third determining module (114), configured to determine a to-be-applied object corresponding to the target sub-area as a target object, wherein the generation module (112) is further configured to: determine a relative location relationship between the at least one to-be-applied object and a terminal object that represents the terminal, generate, in the joystick active area according to the relative location relationship, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object, map locations of the terminal object and the at least one to-be-applied object in a map onto corresponding locations in a drawing area of the application; and generate, in the joystick active area according to the corresponding locations of the terminal object and the at least one to-be-applied object in the drawing area, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object, wherein the total number of the at least one to-be-applied object is 2 or 3, and the generation module (112) is further configured to: determine, based on relative locations of the terminal object and each to-be-applied object in the drawing area, at least one area boundary for distinguishing each sub-area; generate, in the joystick active area based on each area boundary, the at least one sub-area whose total number equals the total number of the at least one to-be-applied object; successively connect a location of each to-be-applied object in the drawing area, to obtain a plurality of connection line segments, wherein the location is an endpoint of two connection line segments; respectively determine, in each connection line segment, a target point that is not an endpoint; respectively connect a first preset location with each target point, to form at least one quasi-boundary straight line whose total number equals a total number of the connection line segments, wherein the first preset location is a location of the terminal object in the drawing area; form, by using a second preset location in a mapping area corresponding to the joystick active area in the drawing area, an area boundary line corresponding to each quasi-boundary straight line, to form an area boundary, wherein the second preset location is a circle center of the joystick active area; and successively draw, in the mapping area corresponding to the joystick active area in the drawing area, an area boundary line parallel to each quasi-boundary straight line respectively by using the second preset location as an endpoint of the area boundary line, wherein the other endpoint of the area boundary line is on an area edge of the joystick active area, wherein the successively drawing an area boundary line parallel to each quasi-boundary straight line respectively by using the second preset location as an endpoint of the area boundary line comprises: successively draw, along a clockwise direction or an anticlockwise direction, the area boundary line parallel to each quasi-boundary straight line respectively by using the second preset location as the endpoint of the area boundary line, and wherein a target point is a middle point of a corresponding connection line segment, and the second preset location is a circle center of the joystick active area.

7. The apparatus according to claim 6, wherein the generation module (112) comprises: a first determining unit, configured to determine a relative location relationship between the at least one to-be-applied object and a terminal object that represents the terminal; and a generation unit, configured to generate, in the joystick active area according to the relative location relationship, the sub-area corresponding to the quantity of the at least one to-be-applied object.

8. An electronic device, comprising: a display; a memory, configured to store a program; and a processor, configured to execute the program, the program being specifically configured to perform the method according to any one of claims 1 to 5.

9. A non-volatile computer readable storage medium, storing a computer readable instruction that enables at least one processor to perform the method according to any one of claims 1 to 5.