Virtual character control method and apparatus, device, storage medium, and program product
A virtual character control method performed by a computer device. The method includes: displaying a virtual scene, the virtual scene comprising at least one virtual character; in response to receiving a target operation on a target region in the virtual scene, displaying a station control in the virtual scene; and in response to receiving a trigger operation on the station control, adjusting a station of the at least one virtual character based on a target adjustment mode, at least one of the target adjustment mode and the at least one virtual character being determined based on a user-customized operation of the station control. The method can realize collective adjustment of stations of a plurality of virtual characters based on a station control during the station adjustment of the virtual characters in a virtual scene, and also ensure the flexibility of the station adjustment of the virtual characters in the virtual scene.
1 . A virtual character control method performed by a computer device, the method comprising:
displaying a virtual scene on a display, the virtual scene comprising at least one virtual character;
in response to receiving a target operation on a target region in the virtual scene by a user of the computer device, displaying a station control in the virtual scene;
in response to displaying the station control, generating a plurality of sub-controls within the station control, each sub-control configured to adjust a unique positional arrangement of the at least one virtual character by deploying the at least one virtual character in the virtual scene;
receiving a trigger operation on the station control to select a respective sub-control of the plurality of sub-controls by the user of the computer device; and
in response to receiving the trigger operation on the station control, adjusting a station of the at least one virtual character based on a target adjustment mode corresponding to the respective sub-control, at least one of the target adjustment mode and the at least one virtual character being determined based on a user-customized operation of the station control, further including:
receiving a first trigger operation on the station control to select a virtual character selection sub-control of the plurality of sub-controls by the user of the computer device;
in response to the trigger operation to select the virtual character selection sub-control:
detecting a range selection operation by the user of the computer device on the virtual scene; and
drawing a contour line surrounding the at least one virtual character in the virtual scene according to the range selection operation;
receiving a second trigger operation on the station control to select a mirror line selection sub-control of the plurality of sub-controls by the user of the computer device;
in response to the trigger operation to select the mirror line selection sub-control:
detecting a mirror line drawing operation by the user of the computer device on the virtual scene;
drawing a straight line in the virtual scene according to the range selection operation as a mirror line such that the contour line surrounding the at least one virtual character in the virtual scene is located on a first side of the mirror line; and
mirror switching each of the at least one virtual character surrounded by the contour line from an old position in the virtual scene on the first side of the mirror line to a new position on a second side of the mirror line, wherein the new position is mirror symmetric to the old position relative to the mirror line.
2 . The method according to claim 1 , wherein the station control comprises at least two sub-controls; and
the adjusting a station of the at least one virtual character based on a target adjustment mode comprises:
in response to receiving a respective trigger operation on a target sub-control, adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control, the target sub-control being one of the at least two sub-controls.
3 . The method according to claim 2 , wherein the adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control comprises:
adjusting a selection state of the at least one virtual character as an optional state in response to receiving a first respective trigger operation on a first sub-control in the at least two sub-controls;
in response to receiving a character selection operation, obtaining a virtual character selected based on the character selection operation as the at least one virtual character; and
switching the station of the at least one virtual character from a first position to a second position in response to the character selection operation, whereby the station of a target virtual character before and after the position switching is symmetrical about a target axis of the virtual scene.
4 . The method according to claim 2 , wherein the adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control comprises:
displaying a layout display region in response to receiving a second respective trigger operation on a second sub-control in the at least two sub-controls, the layout display region including at least one station layout determined based on user-defined layout settings; and
in response to receiving a selection operation on a target station layout, adjusting the station of the at least one virtual character based on the target station layout, the target station layout being one of the at least one station layout.
5 . The method according to claim 4 , wherein the adjusting the station of the at least one virtual character based on the target station layout comprises:
obtaining an attack range of the at least one virtual character; and
adjusting the station of the at least one virtual character based on the attack range of the at least one virtual character and the target station layout.
6 . The method according to claim 4 , wherein the adjusting the station of the at least one virtual character based on the target station layout comprises:
in response to a quantity of stations corresponding to the target station layout being greater than a quantity of a target virtual character, adjusting the station of the at least one virtual character to the stations in the target station layout according to a target station order.
7 . The method according to claim 1 , wherein the station control is superimposed on an upper layer of the virtual scene.
8 . A computer device, comprising a processor and a memory, the memory storing at least one computer program, and the at least one computer program, when loaded and executed by the processor, causing the computer device to implement a virtual character control method including:
displaying a virtual scene on a display of the computer device, the virtual scene comprising at least one virtual character;
in response to receiving a target operation on a target region in the virtual scene by a user of the computer device, displaying a station control in the virtual scene;
in response to displaying the station control, generating a plurality of sub-controls within the station control, each sub-control configured to adjust a unique positional arrangement of the at least one virtual character by deploying the at least one virtual character in the virtual scene;
receiving a trigger operation on the station control to select a respective sub-control of the plurality of sub-controls by the user of the computer device; and
in response to receiving the trigger operation on the station control, adjusting a station of the at least one virtual character based on a target adjustment mode corresponding to the respective sub-control, at least one of the target adjustment mode and the at least one virtual character being determined based on a user-customized operation of the station control, further including:
receiving a first trigger operation on the station control to select a virtual character selection sub-control of the plurality of sub-controls by the user of the computer device;
in response to the trigger operation to select the virtual character selection sub-control:
detecting a range selection operation by the user of the computer device on the virtual scene; and
drawing a contour line surrounding the at least one virtual character in the virtual scene according to the range selection operation;
receiving a second trigger operation on the station control to select a mirror line selection sub-control of the plurality of sub-controls by the user of the computer device;
in response to the trigger operation to select the mirror line selection sub-control:
detecting a mirror line drawing operation by the user of the computer device on the virtual scene;
drawing a straight line in the virtual scene according to the range selection operation as a mirror line such that the contour line surrounding the at least one virtual character in the virtual scene is located on a first side of the mirror line; and
mirror switching each of the at least one virtual character surrounded by the contour line from an old position in the virtual scene on the first side of the mirror line to a new position on a second side of the mirror line, wherein the new position is mirror symmetric to the old position relative to the mirror line.
9 . The computer device according to claim 8 , wherein the station control comprises at least two sub-controls; and
the adjusting a station of the at least one virtual character based on a target adjustment mode comprises:
in response to receiving a respective trigger operation on a target sub-control, adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control, the target sub-control being one of the at least two sub-controls.
10 . The computer device according to claim 9 , wherein the adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control comprises:
adjusting a selection state of the at least one virtual character as an optional state in response to receiving a first respective trigger operation on a first sub-control in the at least two sub-controls;
in response to receiving a character selection operation, obtaining a virtual character selected based on the character selection operation as the at least one virtual character; and
switching the station of the at least one virtual character from a first position to a second position in response to the character selection operation, whereby the station of a target virtual character before and after the position switching is symmetrical about a target axis of the virtual scene.
11 . The computer device according to claim 9 , wherein the adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control comprises:
displaying a layout display region in response to receiving a second respective trigger operation on a second sub-control in the at least two sub-controls, the layout display region including at least one station layout determined based on user-defined layout settings; and
in response to receiving a selection operation on a target station layout, adjusting the station of the at least one virtual character based on the target station layout, the target station layout being one of the at least one station layout.
12 . The computer device according to claim 11 , wherein the adjusting the station of the at least one virtual character based on the target station layout comprises:
obtaining an attack range of the at least one virtual character; and
adjusting the station of the at least one virtual character based on the attack range of the at least one virtual character and the target station layout.
13 . The computer device according to claim 11 , wherein the adjusting the station of the at least one virtual character based on the target station layout comprises:
in response to a quantity of stations corresponding to the target station layout being greater than a quantity of a target virtual character, adjusting the station of the at least one virtual character to the stations in the target station layout according to a target station order.
14 . The computer device according to claim 8 , wherein the station control is superimposed on an upper layer of the virtual scene.
15 . A non-transitory computer-readable storage medium, storing at least one computer program, and the computer program, when loaded and executed by a processor of a computer device, causing the computer device to implement a virtual character control method including:
displaying a virtual scene on a display of the computer device, the virtual scene comprising at least one virtual character;
in response to receiving a target operation on a target region in the virtual scene by a user of the computer device, displaying a station control in the virtual scene;
in response to displaying the station control, generating a plurality of sub-controls within the station control, each sub-control configured to adjust a unique positional arrangement of the at least one virtual character by deploying the at least one virtual character in the virtual scene;
receiving a trigger operation on the station control to select a respective sub-control of the plurality of sub-controls by the user of the computer device; and
in response to receiving the trigger operation on the station control, adjusting a station of the at least one virtual character based on a target adjustment mode corresponding to the respective sub-control, at least one of the target adjustment mode and the at least one virtual character being determined based on a user-customized operation of the station control, further including:
receiving a first trigger operation on the station control to select a virtual character selection sub-control of the plurality of sub-controls by the user of the computer device:
in response to the trigger operation to select the virtual character selection sub-control:
detecting a range selection operation by the user of the computer device on the virtual scene; and
drawing a contour line surrounding the at least one virtual character in the virtual scene according to the range selection operation;
receiving a second trigger operation on the station control to select a mirror line selection sub-control of the plurality of sub-controls by the user of the computer device;
in response to the trigger operation to select the mirror line selection sub-control:
detecting a mirror line drawing operation by the user of the computer device on the virtual scene;
drawing a straight line in the virtual scene according to the range selection operation as a mirror line such that the contour line surrounding the at least one virtual character in the virtual scene is located on a first side of the mirror line; and
mirror switching each of the at least one virtual character surrounded by the contour line from an old position in the virtual scene on the first side of the mirror line to a new position on a second side of the mirror line, wherein the new position is mirror symmetric to the old position relative to the mirror line.
16 . The non-transitory computer-readable storage medium according to claim 15 , wherein the station control comprises at least two sub-controls; and
the adjusting a station of the at least one virtual character based on a target adjustment mode comprises:
in response to receiving a respective trigger operation on a target sub-control, adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control, the target sub-control being one of the at least two sub-controls.
17 . The non-transitory computer-readable storage medium according to claim 16 , wherein the adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control comprises:
adjusting a selection state of the at least one virtual character as an optional state in response to receiving a first respective trigger operation on a first sub-control in the at least two sub-controls;
in response to receiving a character selection operation, obtaining a virtual character selected based on the character selection operation as the at least one virtual character; and
switching the station of the at least one virtual character from a first position to a second position in response to the character selection operation, whereby the station of a target virtual character before and after the position switching is symmetrical about a target axis of the virtual scene.
18 . The non-transitory computer-readable storage medium according to claim 16 , wherein the adjusting the station of the at least one virtual character based on an adjustment mode corresponding to the target sub-control comprises:
displaying a layout display region in response to receiving a second respective trigger operation on a second sub-control in the at least two sub-controls, the layout display region including at least one station layout determined based on user-defined layout settings; and
in response to receiving a selection operation on a target station layout, adjusting the station of the at least one virtual character based on the target station layout, the target station layout being one of the at least one station layout.
19 . The non-transitory computer-readable storage medium according to claim 18 , wherein the adjusting the station of the at least one virtual character based on the target station layout comprises:
obtaining an attack range of the at least one virtual character; and
adjusting the station of the at least one virtual character based on the attack range of the at least one virtual character and the target station layout.
20 . The non-transitory computer-readable storage medium according to claim 18 , wherein the adjusting the station of the at least one virtual character based on the target station layout comprises:
in response to a quantity of stations corresponding to the target station layout being greater than a quantity of a target virtual character, adjusting the station of the at least one virtual character to the stations in the target station layout according to a target station order.