Message sending method, medium, electronic device and program product
By determining the target message based on the location and messages of the virtual character in the game, and simulating message attenuation in the real scene, the problem of messages being easily ignored in the world chat channel is solved, and the authenticity and immersion of the game are improved.
Patent Information
- Application Number
- CN202411368344.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-27
- Publication Date
- 2025-08-15
- Estimated Expiration
- 2044-09-27
AI Technical Summary
In game scenarios, chat messages in the World Chat Channel are dense and refreshed quickly, which makes the messages easily ignored, lack of differences, and cannot be effectively conveyed.
By determining the target message based on the spatial position of the virtual character in the virtual scene and the original message, and displaying it in the screen corresponding to the first virtual character, the effect of message attenuation in the real scene is simulated.
It improves the authenticity and immersion of the game, enhances the communication experience between players, reduces useless information in public chat channels, and reduces the cost of players communicating with other players.
Smart Images

Figure CN119139710B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer technology, and in particular to a message sending method, a medium, an electronic device, and a program product. Background Art
[0002] In gaming scenarios, there are generally two ways for players to communicate with each other. The first is to send messages through the game's world chat channel or, after establishing a social relationship, through private chat channels. However, the high density of messages in the world chat channel, the rapid refresh rate of messages, and the fact that messages in the world chat channel are intended for all players make it extremely easy for messages to be overlooked, resulting in ineffective communication. Furthermore, messages are all sent directly to the world chat channel, lacking differentiation. Summary of the Invention
[0003] This summary is provided to briefly introduce concepts that will be described in detail in the detailed description below. This summary is not intended to identify key features or essential features of the claimed technical solution, nor is it intended to limit the scope of the claimed technical solution.
[0004] In a first aspect, the present disclosure provides a message sending method, comprising:
[0005] Displaying a first virtual scene image corresponding to a first virtual character, where the first virtual character is a virtual character controlled by a first client;
[0006] In response to an original message sent by the second virtual character in the virtual scene, a target message is displayed in the first virtual scene screen, wherein the target message is determined according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message.
[0007] In a second aspect, the present disclosure provides a message sending method, the method comprising:
[0008] Displaying a second virtual scene image corresponding to the second virtual character;
[0009] In response to a message sending operation triggered in the second virtual scene screen, the second virtual character is controlled to send an original message in the virtual scene, wherein the original message is used to display a target message in the first virtual scene screen corresponding to the first virtual character, and the target message is determined based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, and the first virtual character is a virtual character controlled by the first client.
[0010] In a third aspect, the present disclosure provides a message sending method, the method comprising:
[0011] receiving an original message sent by the second virtual character in the virtual scene;
[0012] Obtaining a target message according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, wherein the first virtual character is a virtual character controlled by the first client;
[0013] The target message is sent to the first client, so that the first client displays the target message through a first virtual scene screen corresponding to the first virtual character.
[0014] In a fourth aspect, the present disclosure provides a computer-readable medium having a computer program stored thereon, which, when executed by a processing device, implements the steps of the method described in the first aspect, and / or implements the steps of the method described in the second aspect, and / or implements the steps of the method described in the third aspect.
[0015] In a fifth aspect, the present disclosure provides an electronic device, including:
[0016] a storage device having a computer program stored thereon;
[0017] A processing device, used to execute the computer program in the storage device to implement the steps of the method described in the first aspect, and / or, to implement the steps of the method described in the second aspect, and / or, to implement the steps of the method described in the third aspect.
[0018] In a sixth aspect, the present disclosure provides a computer program product, comprising a computer program, which, when executed by a processor, implements the steps of the method described in the first aspect, and / or implements the steps of the method described in the second aspect, and / or implements the steps of the method described in the third aspect.
[0019] Based on the above technical solution, by displaying the first virtual scene screen corresponding to the first virtual character, in response to the original message sent by the second virtual character in the virtual scene, the target message determined according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message is displayed in the first virtual scene screen. The effect of message attenuation in the real scene can be simulated in the virtual scene, making the game more realistic and immersive, and improving the user's gaming experience.
[0020] Other features and advantages of the present disclosure will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] The above and other features, advantages and aspects of the various embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and that the originals and elements are not necessarily drawn to scale. In the drawings:
[0022] Figure 1 is a flowchart of a message sending method according to some embodiments.
[0023] Figure 2 FIG. 1 is a schematic diagram illustrating determining a first virtual character according to some embodiments.
[0024] Figure 3 is a schematic diagram illustrating determining a target word according to some embodiments.
[0025] Figure 4 is a schematic diagram of a second virtual scene screen according to some embodiments.
[0026] Figure 5 is a schematic diagram showing displaying a target message according to some embodiments.
[0027] Figure 6 is a flowchart of a message sending method according to some other embodiments.
[0028] Figure 7 is a flowchart of a message sending method according to some further embodiments.
[0029] Figure 8 The figure is a schematic structural diagram of a message sending device according to an exemplary embodiment.
[0030] Figure 9 FIG. 4 is a schematic structural diagram of a message sending device according to another exemplary embodiment.
[0031] Figure 10 FIG. 4 is a structural diagram of a message sending device according to another exemplary embodiment.
[0032] Figure 11 It is a schematic structural diagram of an electronic device according to an exemplary embodiment. DETAILED DESCRIPTION
[0033] The following describes embodiments of the present disclosure in more detail with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as limited to the embodiments described herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are for illustrative purposes only and are not intended to limit the scope of protection of the present disclosure.
[0034] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0035] As used herein, the term "including" and its variations are open-ended, i.e., "including but not limited to." The term "based on" means "based, at least in part, on." The term "one embodiment" means "at least one embodiment," the term "another embodiment" means "at least one additional embodiment," and the term "some embodiments" means "at least some embodiments." Other terms are defined in the following description.
[0036] It should be noted that the concepts of "first" and "second" mentioned in this disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0037] It should be noted that the modifications of "one" and "multiple" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, they should be understood as "one or more".
[0038] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.
[0039] It is understandable that before using the technical solutions disclosed in the various embodiments of this disclosure, the type, scope of use, usage scenarios, etc. of the personal information involved in this disclosure should be informed to the user and the user's authorization should be obtained in an appropriate manner in accordance with relevant laws and regulations.
[0040] For example, in response to a user's active request, a prompt message is sent to the user to clearly inform the user that the operation requested will require the acquisition and use of the user's personal information. This allows the user to independently choose whether to provide personal information to the electronic device, application, server, storage medium, or other software or hardware that performs the operations of the disclosed technical solution based on the prompt message.
[0041] As an optional but non-limiting implementation, in response to receiving a user's active request, the prompt information may be sent to the user in the form of a pop-up window, in which the prompt information may be presented in text form. Furthermore, the pop-up window may also contain a selection control for the user to select "agree" or "disagree" to provide personal information to the electronic device.
[0042] It is understandable that the above notification and user authorization process are merely illustrative and do not limit the implementation of the present disclosure. Other methods that comply with relevant laws and regulations may also be applied to the implementation of the present disclosure.
[0043] At the same time, it is understood that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and relevant provisions.
[0044] Figure 1 FIG. 1 is a flow chart of a message sending method according to some embodiments. Figure 1 As shown, the embodiment of the present disclosure provides a message sending method, which can be executed by an electronic device, specifically by a message sending device, which can be implemented by software and / or hardware and configured in the electronic device. It should be understood that the electronic device can be the first client. Figure 1 As shown, the method may include the following steps.
[0045] In step 110 , a first virtual scene image corresponding to the first virtual character is displayed.
[0046] Here, the first virtual character is a virtual character controlled by the first client. The first virtual character may be a player-controlled character. For example, the player controls the first virtual character in a virtual scene through the first client. The virtual scene may be a game scene, such as a two-dimensional game scene, a three-dimensional game scene, or a virtual reality scene.
[0047] The first virtual scene image may refer to an image of a virtual scene displayed from the perspective of the first virtual character. Taking a game as an example, the first virtual scene image may be a game image from the perspective of the first virtual character obtained through a virtual camera.
[0048] In step 120, in response to the original message sent by the second virtual character in the virtual scene, a target message is displayed in the first virtual scene screen, wherein the target message is determined according to the spatial positions of the first and second virtual characters in the virtual scene and the original message.
[0049] Here, the original message may refer to a message sent by a second virtual character to a first virtual character in a virtual scene. The second virtual character may be a player-controlled character other than the first virtual character in the virtual scene. Of course, the second virtual character may also be a non-player-controlled character (NPC) in the virtual scene.
[0050] It should be noted that the original message can be a public message sent by the second virtual character in the virtual scene. In other words, the original message can be a message sent by the second virtual character to multiple first virtual characters in the virtual scene. For example, the original message can be a message sent by the second virtual character to first virtual characters within a certain range of the second virtual character.
[0051] In the embodiment of the present disclosure, the original message may be a text message or a voice message. That is, the message sending method provided by the embodiment of the present disclosure is applicable to both sending text messages and sending voice messages.
[0052] When the second virtual character sends an original message in the virtual scene, a target message is displayed in the first virtual scene screen, wherein the target message is obtained by processing the original message.
[0053] The spatial positions of the first virtual character and the second virtual character in the virtual scene may refer to the first position information of the first virtual character in the virtual scene and the second position information of the second virtual character in the virtual scene. Of course, the spatial positions of the first virtual character and the second virtual character in the virtual scene may refer to the distance between the first virtual character and the second virtual character in the virtual scene, and the distance may be determined based on the first position information of the first virtual character in the virtual scene and the second position information of the second virtual character in the virtual scene.
[0054] The original message can be processed according to the spatial positions of the first virtual character and the second virtual character in the virtual scene to obtain the target message. It should be noted that the first client can determine the target message based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, or the server can determine the target message based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message. Of course, in the case where the second virtual character is a non-player character controlled by the second client, the second client can also determine the target message based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message. After the second client obtains the target message, the second client sends the target message to the server, and the server sends the target message to the first client.
[0055] It is worth noting that when the first and second virtual characters are located in different spatial positions in the virtual scene, the target message displayed in the first virtual scene will be different. For example, if the first and second virtual characters are far apart, the target message may include part of the original message or not contain the original message. If the first and second virtual characters are close together, the target message may be the original message.
[0056] By processing the original message sent by the second virtual character according to the spatial positions of the first virtual character and the second virtual character in the virtual scene, different original messages are displayed in different spatial positions, thereby simulating the effect that the chat messages received in the real scene will be different depending on the distance, making the game more realistic and immersive.
[0057] Therefore, by displaying the first virtual scene screen corresponding to the first virtual character, in response to the original message sent by the second virtual character in the virtual scene, the target message determined according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message is displayed in the first virtual scene screen, the effect of message attenuation in the real scene can be simulated in the virtual scene, making the game more realistic and immersive, and improving the user's gaming experience.
[0058] In an embodiment of the present disclosure, the first virtual character may be a virtual character in a virtual scene that can receive the original message sent by the second virtual character. For example, the first virtual character may be a virtual character in the virtual scene that is no more than the message receiving distance corresponding to the original message from the second virtual character.
[0059] The message receiving distance corresponding to the original message may refer to the maximum distance indicated by the second virtual character at which the original message can be received. By comparing the distance between the virtual character and the second virtual character in the virtual scene and the message receiving distance, the first virtual character in the virtual scene that can receive the original message sent by the second virtual character is determined.
[0060] A virtual character whose distance from the second virtual character in the virtual scene is less than or equal to the message receiving distance can receive the original message sent by the second virtual character. A virtual character whose distance from the second virtual character in the virtual scene is greater than the message receiving distance cannot receive the original message sent by the second virtual character.
[0061] Therefore, the second avatar can choose to communicate with avatars at different distances in the virtual scene by specifying different message receiving distances. For example, the second avatar can specify 10 units of the virtual scene as the message receiving distance, so that avatars within 10 units of the virtual scene from the second avatar can receive the original message sent by the second avatar.
[0062] For example, in a specific implementation, the message receiving range can be determined with the position information of the second virtual character as the origin and the message receiving distance as the radius, and then the virtual character in the virtual scene within the message receiving range is determined as the first virtual character.
[0063] Figure 2FIG. 1 is a schematic diagram illustrating determining a first virtual character according to some embodiments. Figure 2 As shown, the distance between virtual character A and second virtual character 202 in virtual scene 201 is less than message receiving distance 203, the distance between virtual character B and second virtual character 202 in virtual scene 201 is less than message receiving distance 203, and the distance between virtual character C and second virtual character 202 in virtual scene 201 is greater than message receiving distance 203. Therefore, virtual characters A and B are first virtual characters. In other words, the original message sent by second virtual character 202, which indicates that virtual characters within message receiving distance 203 can receive it, can be received by virtual characters A and B in virtual scene 201, but cannot be received by virtual character C.
[0064] Based on this, players can select a specific message receiving distance, which not only meets the player's need to communicate with players at a specific distance, but also prevents the public chat channel from generating too much useless information, thereby reducing the disturbance to players by messages on the public chat channel. Moreover, the message sending method provided by the disclosed embodiment also enables players to communicate with people nearby in the virtual scene without establishing social relationships with other players, reducing the cost of players communicating with other players and greatly improving the gaming experience.
[0065] In some feasible implementations, the original message may be determined as the target message in response to the distance between the first virtual character and the second virtual character in the virtual scene being no greater than a preset distance threshold.
[0066] In some other feasible implementations, in response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than a preset distance threshold, part of the information in the original message may be determined as the target message.
[0067] Here, the distance between the first virtual character and the second virtual character in the virtual scene may be determined by a first position message of the first virtual character in the virtual scene and a second position message of the second virtual character in the virtual scene.
[0068] After receiving the original message sent by the second virtual character, if the distance between the first virtual character and the second virtual character is not greater than a preset distance threshold, the target message is the original message. If the distance between the first virtual character and the second virtual character is greater than the preset distance threshold, the target message is part of the original message.
[0069] According to the different distances between the first virtual character and the second virtual character, the target message displayed by the corresponding first virtual character may be different, thereby simulating the effect in a real scene that users at different distances hear different contents of messages sent from the same location.
[0070] It is worth noting that, since the first virtual character is a virtual character whose distance is not greater than the message receiving distance, the preset distance threshold is less than the message receiving distance. Figure 2 As shown, the preset distance threshold 204 is smaller than the message receiving distance 203. It should be understood that the size of the preset distance threshold can be set according to actual conditions, or different sizes of preset distance thresholds can be set for different message sending modes for sending original messages.
[0071] like Figure 2 As shown, the distance between the virtual character A and the second virtual character 202 is less than the preset distance threshold 204 , and the distance between the virtual character B and the second virtual character 202 is less than the preset distance threshold 204 .
[0072] When the distance between the first virtual character and the second virtual character is less than or equal to a preset distance threshold, the original message is displayed in the first virtual scene screen corresponding to the first virtual character.
[0073] When the distance between the first virtual character and the second virtual character is greater than a preset distance threshold, part of the information in the original message is displayed in the first virtual scene screen corresponding to the first virtual character.
[0074] That is, although both avatar A and avatar B can receive the message sent by the second avatar 202, due to the different distances, the content of the original message received by avatar A and avatar B is different. For example, the target message displayed to avatar A is the original message sent by the second avatar 202, while the target message displayed to avatar B is part of the original message.
[0075] For example, assuming that the original message sent by the second virtual character 202 is "Have you heard, Xiao Li from the next class confessed to my friend Dahua, and hit her after being rejected", when virtual character A acts as the first virtual character, the target message "Have you heard, Xiao Li from the next class confessed to my friend Dahua, and hit her after being rejected" is displayed in the first virtual scene screen of virtual character A; when virtual character B acts as the first virtual character, the target message "...confession..." is displayed in the first virtual scene screen of virtual character B.
[0076] It is worth noting that, when the distance between the first virtual character and the second virtual character in the virtual scene is greater than a preset distance threshold, the content of the corresponding target message may also be different for the first virtual characters at different distances. In other words, when the distance between the first virtual character and the second virtual character in the virtual scene is greater than the preset distance threshold, the target message displayed by the first virtual character that is closer to the second virtual character may include more content in the partial message of the original message than the target message displayed by the first virtual character that is farther away from the second virtual character.
[0077] Therefore, through the above implementation, the effect of information attenuation with distance in a real scene can be simulated in a virtual scene, making the game more realistic and immersive.
[0078] In some feasible implementations, based on the character attribute information of the first virtual character, information matching the character attribute information can be determined from the original information, and the target message can be determined according to the matching information.
[0079] Here, the character attribute information may refer to the identity information, age information, etc. of the first virtual character. It is worth noting that the identity information corresponding to the first virtual character may refer to the game profession of the first virtual character in the virtual scene, such as teacher, worker, shooter, assistant, warrior, mage, etc.
[0080] When the distance between the first virtual character and the second virtual character is greater than a preset distance threshold, information matching the character attribute information is determined from the original information according to the character attribute information corresponding to the first virtual character, and a target message is determined according to the matching information.
[0081] In some embodiments, the words included in the original message can be determined, and according to the role attribute information corresponding to the first virtual character, target words matching the role attribute information can be determined among the words, and then a target message can be obtained based on the target words.
[0082] If the original message is a text message, the text message can be segmented to obtain the individual words in the original message. If the original message is a voice message, the voice message can be subjected to language recognition to convert the voice message into text, and then the text can be segmented to obtain the individual words in the original message.
[0083] Taking the role attribute information as identity information as an example, first virtual characters with different identity information have different interests in various words in the same original message. Therefore, at least one target word related to the identity information can be determined from among the various words.
[0084] For example, if the original message sent by the second avatar is "Have you heard? Xiao Li from the next class confessed his love to my friend Da Hua, and after being rejected, he hit her." If the identity information of the first avatar A is "Teacher," and the "teacher" identity information is more interested in the word "confession," the target message displayed to the first avatar A is "...confessed...". If the identity information of the first avatar B is "Policeman," and the "Policeman" identity information is more interested in the word "hit," the target message displayed to the first avatar B is "...hit her."
[0085] In some embodiments, the words may be ranked from high to low according to the degree of association between the identity information and the different words, and one or more words ranked high may be selected as target words.
[0086] For example, one or more words with the highest degree of correlation with the identity information can be used as target words. It should be noted that the number of target words can be determined based on other types of character attribute information. For example, for older virtual characters with lower message receiving capabilities, the number of target words can be smaller than that for younger virtual characters.
[0087] After obtaining the target word, the original message sent by the second virtual character is omitted from the display except for the target word, thereby obtaining the target message. For example, in the original message "Have you heard? Xiao Li from the next class confessed his love to my friend Da Hua, and after being rejected, he hit her," the target word in the original message is "confession," so the target message would be "...confession..."
[0088] If the original message is a voice message, the remaining audio frames in the voice message, except for the audio frames corresponding to the target word, can be blurred to obtain the target message. In other words, in the target message, the player can only clearly hear the target word, and cannot clearly hear the content other than the target word.
[0089] Figure 3 FIG. 1 is a schematic diagram showing how to determine a target word according to some embodiments. Figure 3As shown, the second virtual character sends an original message, which is then segmented to obtain word A, word B, word C, word D, and word E. Then, based on the first virtual character's attribute information, "word A, word B, word C, word D, word E" is sorted to obtain the order "word D > word B > word C > word A > word E." The original message is then processed into "...word B...word D...", and the first virtual scene corresponding to the first virtual character displays the target message "...word B...word D..."
[0090] Thus, through the above embodiment, the original message sent by the second virtual character displayed by the first virtual character at different distances will be different, thereby simulating the effect of message attenuation with distance in the real scene in the virtual scene, making communication between players more immersive and interesting. Moreover, by processing the original message based on the character attribute information, the wording of the target message displayed by the virtual character with different character attribute information can be differentiated, so that the message received by the player is more consistent with the character attribute information of the virtual character, thereby increasing the player's enthusiasm for communication in the virtual scene.
[0091] In some further achievable implementations, in response to a distance between the first virtual character and the second virtual character in the virtual scene being greater than a message receiving distance corresponding to the original message, the indication message is determined as the target message.
[0092] Here, when the distance between the first virtual character and the second virtual character in the virtual scene is greater than the message receiving distance corresponding to the original message, it means that the distance between the first virtual character and the second virtual character in the virtual scene is far, and the first virtual character cannot receive the message sent by the second virtual character.
[0093] It's worth noting that the "first virtual character" in this context can be any virtual character in the virtual scene, or a virtual character whose distance from the second virtual character in the virtual scene is greater than the message receiving distance but less than the target distance threshold. When the second virtual character sends the original message, the other virtual characters, acting as the first virtual character, display different target messages for the first virtual characters at different distances. For first virtual characters whose distance is greater than the message receiving distance, an instruction message is displayed in the corresponding first virtual scene.
[0094] It should be understood that the message receiving distance corresponding to the original message is greater than the preset distance threshold. The explanation of the message receiving distance will be explained in detail in subsequent embodiments.
[0095] The instruction message is used to instruct the second virtual character to send a message in the virtual scene, and the instruction message does not contain the message content of the original message.
[0096] For example, assuming the original message is "Have you heard that Xiao Li from the next class confessed his love to my friend Dahua, and hit her after being rejected", for the first virtual character whose distance is greater than the message receiving distance, the corresponding target message can be "[Second virtual character] sent a message" or "[Second virtual character] spoke in the virtual scene" and other indicative messages.
[0097] The instruction message does not contain any message content of the original message sent by the second virtual character. The instruction message is used to remind the first virtual character that the second virtual character has sent a message in the virtual scene.
[0098] It is worth noting that if the distance between the first virtual character and the second virtual character in the virtual scene is greater than the message receiving distance corresponding to the original message, it means that the first virtual character has exceeded the maximum distance at which the original message can be received. For the first virtual character, this is equivalent to being unable to "clearly hear" the message sent by the second virtual character. By using the instruction message as the target message, the player corresponding to the first virtual character can be prompted to the second virtual character in the virtual scene that the second virtual character in the virtual scene has sent a message in the virtual scene, but due to the long distance, the player corresponding to the first virtual character cannot receive the message sent by the second virtual character in the virtual scene, thereby prompting the first virtual character to approach the second virtual character so that the first virtual character can receive the message sent by the second virtual character.
[0099] Therefore, through the above implementation, not only can the effect of message attenuation with distance in a real scene be simulated in a virtual scene, making the communication between players more immersive and interesting, but also the distance between players can be shortened through instruction messages, thereby increasing the enthusiasm of players to interact.
[0100] It is worth noting that in the embodiment of the present disclosure, when the distance between the first virtual character and the second virtual character in the virtual scene is not greater than the preset distance threshold, the original message sent by the second virtual character is displayed in the first virtual scene screen. When the distance between the first virtual character and the second virtual character in the virtual scene is greater than the preset distance threshold and not greater than the message receiving distance, part of the information in the original message sent by the second virtual character is displayed in the first virtual scene screen. When the distance between the first virtual character and the second virtual character in the virtual scene is greater than the message receiving distance, an instruction message is displayed in the first virtual scene screen. Based on this, the effect of the message attenuation with distance in the real scene can be simulated in the virtual scene, making the communication between players more immersive and interesting.
[0101] In some feasible implementations, the message receiving distance may be determined by the second virtual character.
[0102] Exemplarily, the second client corresponding to the second virtual character may determine the message receiving distance according to the message sending mode selected for sending the original message, wherein different message sending modes correspond to different message receiving distances; or determine the message receiving distance according to a specified distance.
[0103] Here, different message sending modes correspond to different message receiving distances, and the message receiving distance corresponding to the original message sent by the second virtual character is determined by the message receiving distance corresponding to the message sending mode selected by the second virtual character for sending the original message.
[0104] In the embodiment of the present disclosure, the message sending mode may include a whisper mode, a talk mode, and a shout mode.
[0105] In whisper mode, when the distance satisfies 0<n≤a, the first virtual character can receive the original message sent by the second virtual character, and the original message can be displayed through the public chat channel and message bubble. When the distance satisfies a<n≤b, the first virtual character can receive the message sent by the second virtual character, but only part of the original message is displayed, and the partial message can be displayed through the public chat channel and message bubble. When the distance satisfies n>b, the first virtual character cannot receive the original message sent by the second virtual character. Where n is the distance between the second virtual character and the first virtual character, a is the preset distance threshold, and b is the message receiving distance.
[0106] In speaking mode, when the distance satisfies 0<n≤b, the first avatar can receive the original message sent by the second avatar, and the original message can be displayed in the public chat channel and message bubble. When the distance satisfies n>b, the first avatar cannot receive the message sent by the second avatar.
[0107] In shouting mode, when the distance satisfies 0<n≤b, the first avatar can receive the original message sent by the second avatar, and the original message can be displayed in the public chat channel and message bubble. When the distance satisfies n>b, the message sent by the second avatar can be received in the public chat channel, but not in the message bubble.
[0108] For example, in the embodiment of the present disclosure, the message sending mode corresponding to the original message may be the whisper mode shown in the above embodiment. Of course, in actual application scenarios, the message sending mode corresponding to the original message may also be a message sending mode set according to needs.
[0109] When the second virtual character sends the original message in the selected message sending mode, if the distance between the first virtual character receiving the original message and the second virtual character is greater than a preset distance threshold, then according to the character attribute information corresponding to the first virtual character, information matching the character attribute information is determined from the original message, and the target message is determined based on the matching information.
[0110] Therefore, through the above implementation, a variety of chat modes can be provided in the virtual scene, so that players can communicate in different forms according to their needs, greatly improving the player's gaming experience.
[0111] Figure 4 FIG. 1 is a schematic diagram of a second virtual scene according to some embodiments. Figure 4 As shown, when the second virtual character needs to send a message in the virtual scene, the player can select a corresponding message sending mode through the second virtual scene screen 401 corresponding to the second virtual character. For example, the player can select a message sending mode from whisper mode, talk mode, and shout mode as the mode for sending the original message.
[0112] After the player selects the message sending mode, the player can input the message to be sent, and the second client sends the target message to the corresponding first virtual character according to the message sending mode selected by the player and the original message input.
[0113] Of course, before sending the original message, the player corresponding to the second virtual character can specify a distance through the second virtual scene screen corresponding to the second virtual character, and the second client can determine the specified distance as the message receiving distance.
[0114] It should be understood that by specifying a distance as the message receiving distance, players can communicate with other players within different distances as needed. Of course, in the disclosed embodiments, the distance specified by the second virtual character can also be represented by a location in the virtual scene. For example, the player corresponding to the second virtual character can specify a specific city in the virtual scene as the message sending distance, so that all virtual characters in that city can receive the original message sent by the second virtual character.
[0115] Therefore, through the above implementation, players can specify the message receiving distance corresponding to the original message they send in different ways, so that players can communicate with other players at different distances, greatly improving the freedom and experience of the game.
[0116] In some feasible implementations, in step 120 , the target message may be displayed in a public chat channel in the first virtual scene screen, and / or the target message may be displayed in the first virtual scene screen by rendering a message bubble on the second virtual character.
[0117] Here, the first client corresponding to the first virtual character displays the target message through the public chat channel displayed in the first virtual scene screen. Figure 4 As shown, target messages that can be received by the first virtual character can be displayed in the public chat channel.
[0118] Of course, the first client corresponding to the first virtual character may also display the target message via a message bubble rendered on the second virtual character. It should be understood that when the second virtual character appears in the first virtual scene screen corresponding to the first virtual character, the first client of the first virtual character renders and displays the corresponding message bubble on the second virtual character in the first virtual scene screen based on the received target message, so as to display the message sent by the second virtual character via the message bubble.
[0119] It is worth noting that, depending on the message sending mode used by the second virtual character to send the original message, the message sent by the second virtual character may be displayed through a public chat channel and / or a message bubble.
[0120] In some embodiments, the first client may display the target message in the public chat channel of the first virtual scene screen through a target display style, where the target display style is used to indicate the message sending mode used by the second virtual character when sending the original message.
[0121] For an original message sent by the second virtual character using a different message sending mode, the first client corresponding to the first virtual character displays the target message in the public chat channel using the corresponding target display style, thereby displaying the message sending mode corresponding to the message sent by the second virtual character to the player using the target display style.
[0122] Figure 5 FIG is a schematic diagram showing a display target message according to some embodiments. Figure 5 As shown, second avatar 601 (Player C) sends the original message "You know M3?" via whisper mode. Within the message receiving distance corresponding to whisper mode, the target message that can be received by first avatar 602 is "...know...". The first client corresponding to first avatar 602 displays the target message "...know..." in a message bubble 603. In the public chat channel of first avatar 602, the target message "...know..." is displayed using the target display style of "[Player C] Whisper: ...know...", indicating that second avatar 601 sent the message "...know..." via whisper mode.
[0123] Thus, through the above implementation, a first virtual character at a different distance from a second virtual character in a virtual scene will receive messages of different styles, thereby increasing the diversity and fun of communication between players in the game.
[0124] Figure 6 FIG. 1 is a flow chart of a message sending method according to other embodiments. Figure 6 As shown, the embodiment of the present disclosure provides a message sending method, which can be executed by an electronic device, specifically by a message sending device, which can be implemented by software and / or hardware and configured in the electronic device. It should be understood that the electronic device can be a second client. Figure 6 As shown, the method may include the following steps.
[0125] In step 610 , a second virtual scene image corresponding to the second virtual character is displayed.
[0126] Here, the second virtual character is a virtual character controlled by the second client. The second virtual character may be a player-controlled character. For example, the player controls the second virtual character in the virtual scene through the second client.
[0127] The second virtual scene image may refer to an image of a virtual scene displayed from the perspective of the second virtual character. Taking a game as an example, the second virtual scene image may be a game image from the perspective of the second virtual character obtained through a virtual camera.
[0128] In step 620, in response to the message sending operation triggered in the second virtual scene screen, the second virtual character is controlled to send the original message in the virtual scene, wherein the original message is used to display the target message in the first virtual scene screen corresponding to the first virtual character, and the target message is determined based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, and the first virtual character is a virtual character controlled by the first client.
[0129] Here, the message sending operation may be an operation for sending a message triggered by the player through the second client in the second virtual scene. In response to the message sending operation, the second client controls the second virtual character to send the original message in the virtual scene.
[0130] For the player corresponding to the second virtual character, he can trigger the message sending operation by selecting the message sending mode in the second virtual scene screen and editing the corresponding message to be sent.
[0131] It should be noted that the original message can be a public message sent by the second virtual character in the virtual scene. In other words, the original message can be a message sent by the second virtual character to multiple first virtual characters in the virtual scene. For example, the original message can be a message sent by the second virtual character to a first virtual character within a certain range of the second virtual character. The original message sent by the second virtual character is used to display the target message in the first virtual scene corresponding to the first virtual character. It should be understood that the detailed description of the target message can be referred to the relevant description of the above embodiment and will not be repeated here.
[0132] Thus, the second virtual scene screen corresponding to the second virtual character is displayed, and in response to the message sending operation triggered in the second virtual scene screen, the second virtual character is controlled to send the original message in the virtual scene. The effect of message attenuation in the real scene can be simulated in the virtual scene, making the game more realistic and immersive, thereby improving the user's gaming experience.
[0133] In some feasible implementations, the first virtual character may be a virtual character whose distance from the second virtual character in the virtual scene is no greater than a message receiving distance corresponding to the original message.
[0134] Here, regarding the message receiving distance, the first virtual character, and the distance between the virtual character and the second virtual character, reference may be made to the relevant descriptions of the above embodiments, which will not be repeated here.
[0135] It is worth noting that the first virtual character may be determined by the second client or by the server.
[0136] Based on this, players can select a specific message receiving distance, which not only meets the player's need to communicate with players at a specific distance, but also prevents the public chat channel from generating too much useless information, thereby reducing the disturbance to players by messages on the public chat channel. Moreover, the message sending method provided by the disclosed embodiment also enables players to communicate with people nearby in the virtual scene without establishing social relationships with other players, reducing the cost of players communicating with other players and greatly improving the gaming experience.
[0137] In some feasible implementations, the second client may determine the message receiving distance based on the message sending mode selected for sending the original message, where different message sending modes correspond to different message receiving distances; or determine the message receiving distance based on a specified distance.
[0138] It should be understood that, for instructions on how to determine the message receiving distance, reference can be made to the relevant description of the above embodiment, which will not be repeated here.
[0139] Therefore, through the above implementation, a variety of chat modes can be provided in the virtual scene, so that players can communicate in different forms according to their needs, greatly improving the player's gaming experience.
[0140] It is worth noting that in the embodiment of the present disclosure, the roles between the first client and the second client can be switched. That is, when a client acts as a message sender, the client acts as the second client, and when a client acts as a message receiver, the client acts as the first client. Of course, when a client acts as both a message sender and a message receiver, the client acts as both a first client and a second client. For example, when a client sends a message in a virtual scene, it can also receive messages at the same time. Therefore, both the first and second clients can be executed on one client. Figure 1 The message sending method shown can also be executed Figure 6 The message sending method is shown.
[0141] Figure 7 FIG. 1 is a flow chart of a message sending method according to some further embodiments. Figure 7 As shown, the embodiment of the present disclosure provides a message sending method, which can be executed by an electronic device, specifically by a message sending device, which can be implemented by software and / or hardware and configured in the electronic device. It should be understood that the electronic device can be a server. Figure 7 As shown, the method may include the following steps.
[0142] In step 710, an original message sent by the second virtual character in the virtual scene is received.
[0143] Here, the server can receive the original message sent by the second virtual character in the virtual scene. It should be noted that when the second virtual character is a player-controlled character, the server can receive the original message sent by the second client corresponding to the second virtual character. When the second virtual character is not a player-controlled character, the server can directly obtain the original message sent by the second virtual character from the server.
[0144] In step 720, a target message is obtained according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message.
[0145] Here, the first virtual character is a virtual character controlled by the first client. How to obtain the target message according to the spatial positions of the first and second virtual characters in the virtual scene and the original message can be referred to the relevant description of the above embodiment, which will not be repeated here.
[0146] In step 730 , a target message is sent to the first client, so that the first client displays the target message through a first virtual scene screen corresponding to the first virtual character.
[0147] Here, the server sends a target message to the first client corresponding to the first virtual character, so that the first client corresponding to the first virtual character can display the target message in the virtual scene.
[0148] The server receives the original message sent by the second client corresponding to the second virtual character, processes the original message into different target messages according to the distance, and sends the target message to the first client corresponding to the first virtual character, so as to display the target message in the first client, thereby realizing communication between the player corresponding to the second virtual character and the player corresponding to the first virtual character.
[0149] Therefore, through the above steps 710 to 730, the effect of message attenuation in a real scene can be simulated in a virtual scene, making the game more realistic and immersive, thereby improving the user's gaming experience.
[0150] In some feasible implementations, the server may determine the distance between the virtual character and the second virtual character in the virtual scene, and determine the virtual character whose distance is not greater than the message receiving distance corresponding to the original message as the first virtual character.
[0151] In some embodiments, the initial distance between the virtual character and the second virtual character can be determined based on the first position information of the virtual character in the virtual scene and the second position information of the second virtual character in the virtual scene, and then the initial distance is adjusted based on the character perception capabilities corresponding to the virtual characters and / or the obstructions included between the virtual character and the second virtual character to obtain the distance between the virtual character and the second virtual character in the virtual scene.
[0152] Here, the initial distance between the virtual character and the second virtual character may refer to the actual distance between the virtual character and the second virtual character in the virtual scene. Therefore, the initial distance between each virtual character and the second virtual character in the virtual scene can be determined based on the first position information of the virtual character in the virtual scene and the second position information of the second virtual character in the virtual scene.
[0153] The character perception capability corresponding to the virtual character refers to the ability of the virtual character to receive messages. For example, the perception capability may refer to the auditory parameters and / or visual parameters corresponding to the virtual character. It should be understood that different virtual characters in a virtual scene may have different character perception capabilities. The character perception capability may be a default setting of the game or a parameter value obtained by the virtual character through learning.
[0154] Adjusting the initial distance based on the character's perception ability can be an operation of increasing, decreasing, or not adjusting the initial distance based on the character's perception ability. In the embodiment of the present disclosure, the character's perception ability is negatively correlated with the distance between the virtual character and the second virtual character. That is, the greater the character perception ability corresponding to the virtual character, the smaller the distance between the virtual character and the second virtual character after adjustment, thereby making it more likely that the virtual character will receive the original message sent by the second virtual character, and making the original message sent by the second virtual character received by the virtual character clearer.
[0155] In some embodiments, a target distance correction coefficient corresponding to the character perception ability of the virtual character can be determined according to the character perception ability corresponding to the virtual character, and the distance between the virtual character and the second virtual character can be determined according to the sum of the initial distance and the target distance correction coefficient.
[0156] A character's perception ability can be set as the standard character's perception ability, and then the corresponding target distance correction coefficient can be determined based on the difference between the character perception ability corresponding to the virtual character and the standard character's perception ability.
[0157] It is worth noting that the target distance correction coefficient corresponding to the standard character perception ability can be 0. Under the standard character perception ability, the distance between the virtual character and the second virtual character is the corresponding initial distance. If the character perception ability of the virtual character is less than the standard character perception ability, the corresponding target distance correction coefficient is a positive value, which increases the initial distance between the virtual character and the second virtual character, thereby increasing the distance between the virtual character and the second virtual character, thereby affecting whether the virtual character can receive the message and the amount of information included in the received message. If the character perception ability of the virtual character is greater than the standard character perception ability, the corresponding target distance correction coefficient is a negative value, which decreases the initial distance between the virtual character and the second virtual character, thereby decreasing the distance between the virtual character and the second virtual character, thereby affecting whether the virtual character can receive the message and the amount of information included in the received message.
[0158] For example, if virtual character A has better hearing and / or vision than other virtual characters, virtual character A will be more likely to obtain the original message sent by the second virtual character, and the amount of information in the obtained original message will be greater.
[0159] The occluder between the virtual character and the second virtual character refers to an object set between the virtual character and the second virtual character in the virtual scene. For example, the occluder can be rain, walls, trees, etc. in the virtual scene.
[0160] The initial distance can be adjusted based on any obstructions between the virtual character and the second virtual character, and the initial distance can be increased, decreased, or not adjusted. In the disclosed embodiment, the obstruction coefficient corresponding to the obstruction is positively correlated with the distance between the virtual character and the second virtual character. That is, the more obstructions there are between the virtual character and the second virtual character, the larger the adjusted distance value is, making it less likely that the virtual character will receive the original message sent by the second virtual character, and reducing the amount of information in the original message sent by the second virtual character received by the virtual character.
[0161] In some embodiments, an occlusion coefficient corresponding to the occlusion between the virtual character and the second virtual character may be determined, and then the initial distance may be adjusted using the occlusion coefficient to obtain the distance between the virtual character and the second virtual character.
[0162] The occlusion coefficient corresponding to the obstruction can be determined based on the material properties of the obstruction (e.g., density, absorption coefficient). In other words, obstructions of different material properties correspond to different occlusion coefficients. The distance between the virtual character and the second virtual character can be determined based on the occlusion coefficient and the initial distance. This allows the initial distance between the virtual character and the second virtual character to be dynamically increased when an obstruction exists between the virtual character and the second virtual character. This reduces the likelihood that the virtual character will receive the original message sent by the second virtual character when an obstruction exists between the virtual character and the second virtual character, thereby simulating the message attenuation effect in real-world scenarios.
[0163] It is worth noting that when there is no obstruction between the virtual character and the second virtual character, the distance between the virtual character and the second virtual character is equal to the initial distance between the virtual character and the second virtual character. When there is an obstruction between the virtual character and the second virtual character, the distance between the virtual character and the second virtual character is greater than the initial distance between the virtual character and the second virtual character. Thus, the distance can be dynamically determined based on the obstruction between the virtual character and the second virtual character and / or the character's perception ability, thereby simulating the attenuation effect of messages in real-world scenarios, making the game more realistic and immersive, and also allowing different virtual characters to receive different information, thereby making the game more realistic.
[0164] Figure 8 FIG. 1 is a schematic diagram showing the structure of a message sending device according to an exemplary embodiment. Figure 8 As shown, an embodiment of the present disclosure provides a message sending device 800, which includes:
[0165] A first display module 801 is configured to display a first virtual scene corresponding to a first virtual character, where the first virtual character is a virtual character controlled by a first client;
[0166] The second display module 802 is configured to display a target message in the first virtual scene screen in response to an original message sent by the second virtual character in the virtual scene, wherein the target message is determined based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message.
[0167] Optionally, in response to the distance between the first virtual character and the second virtual character in the virtual scene being no greater than a preset distance threshold, the original message is determined as the target message.
[0168] Optionally, in response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than a preset distance threshold, part of the information in the original message is determined as the target message.
[0169] Optionally, based on the role attribute information of the first virtual role, information matching the role attribute information is determined from the original information, and the target message is determined according to the matching information.
[0170] Optionally, in response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than the message receiving distance corresponding to the original message, an indication message is determined as the target message, wherein the indication message is used to instruct the second virtual character to send a message in the virtual scene, and the indication message does not contain the message content of the original message.
[0171] Optionally, the second display module 802 is specifically configured to:
[0172] The target message is displayed in the first virtual scene through a public chat channel in the first virtual scene, and / or the target message is displayed in the first virtual scene through a message bubble rendered on the second virtual character.
[0173] The logic of the method executed by each functional module in the above-mentioned message sending device 800 can refer to the part of the method related to the above-mentioned embodiment, and will not be repeated here.
[0174] Figure 9 FIG. 1 is a structural diagram of a message sending device according to another exemplary embodiment. Figure 9 As shown, an embodiment of the present disclosure provides a message sending device 900, which includes:
[0175] The third display module 901 is configured to display a second virtual scene image corresponding to the second virtual character;
[0176] The control module 902 is configured to control the second virtual character to send an original message in the virtual scene in response to a message sending operation triggered in the second virtual scene screen, wherein the original message is used to display a target message in the first virtual scene screen corresponding to the first virtual character, and the target message is determined based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, and the first virtual character is a virtual character controlled by the first client.
[0177] Optionally, the first virtual character is a virtual character whose distance from the second virtual character in the virtual scene is not greater than a message receiving distance corresponding to the original message.
[0178] Optionally, the message sending device 900 further includes:
[0179] a first determining module configured to determine the message receiving distance according to the message sending mode selected for sending the original message, wherein different message sending modes correspond to different message receiving distances; or
[0180] The second determining module is configured to determine the message receiving distance according to a specified distance.
[0181] The logic of the method executed by each functional module in the above-mentioned message sending device 900 can refer to the part of the method related to the above-mentioned embodiment, and will not be repeated here.
[0182] Figure 10 FIG. 1 is a structural diagram of a message sending device according to another exemplary embodiment. Figure 10 As shown, an embodiment of the present disclosure provides a message sending device 1000, which includes:
[0183] The receiving module 1001 is configured to receive an original message sent by the second virtual character in the virtual scene;
[0184] An obtaining module 1002 is configured to obtain a target message according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, wherein the first virtual character is a virtual character controlled by the first client;
[0185] The sending module 1003 is configured to send the target message to the first client, so that the first client displays the target message through the first virtual scene screen corresponding to the first virtual character.
[0186] Optionally, the message sending device 1000 further includes:
[0187] a third determining module, configured to determine a distance between the virtual character in the virtual scene and the second virtual character;
[0188] The fourth determining module is configured to determine the virtual character whose distance is not greater than the message receiving distance corresponding to the original message as the first virtual character.
[0189] Optionally, the third determining module is specifically configured to:
[0190] determining an initial distance between the virtual character and the second virtual character according to first position information of the virtual character in the virtual scene and second position information of the second virtual character in the virtual scene;
[0191] The initial distance is adjusted according to the character perception ability corresponding to the virtual character and / or an obstruction between the virtual character and the second virtual character to obtain the distance between the virtual character and the second virtual character in the virtual scene.
[0192] The logic of the method executed by each functional module in the above-mentioned message sending device 1000 can refer to the part of the method related to the above-mentioned embodiment, and will not be repeated here.
[0193] Reference below Figure 11 , which shows a schematic structural diagram of an electronic device (e.g., a terminal device (also referred to as a client, such as the first client or second client in the above-mentioned embodiment) or a server) 1100 suitable for implementing embodiments of the present disclosure. The terminal device in the embodiments of the present disclosure may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital TVs and desktop computers. Figure 11 The electronic device shown is only an example and should not limit the functions and scope of use of the embodiments of the present disclosure.
[0194] like Figure 11As shown, electronic device 1100 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 1101, which can perform various appropriate actions and processes based on programs stored in a read-only memory (ROM) 1102 or programs loaded from a storage device 11011 into a random access memory (RAM) 1103. RAM 1103 also stores various programs and data required for the operation of electronic device 1100. Processing device 1101, ROM 1102, and RAM 1103 are connected to each other via a bus 1104. An input / output (I / O) interface 1105 is also connected to bus 1104.
[0195] Typically, the following devices may be connected to the I / O interface 1105: an input device 1106 including, for example, a touch screen, a touchpad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 1107 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 1108 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1109. The communication device 1109 may allow the electronic device 1100 to communicate with other devices wirelessly or by wire to exchange data. Figure 11 The electronic device 1100 is shown with various devices, but it should be understood that it is not required to implement or possess all of the devices shown. More or fewer devices may be implemented or possessed instead.
[0196] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication device 1109, or installed from the storage device 11011, or installed from the ROM 1102. When the computer program is executed by the processing device 1101, the above-mentioned functions defined in the method of the embodiment of the present disclosure are performed.
[0197] It should be noted that the computer-readable medium described above in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. Computer-readable storage media may include, for example, but not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or components, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such a propagated data signal may take a variety of forms, including, but not limited to, electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer-readable medium may be transmitted using any suitable medium, including but not limited to wire, optical cable, RF (radio frequency), or any suitable combination thereof.
[0198] In some embodiments, the client and server can communicate using any currently known or later developed network protocol, such as HTTP (HyperText Transfer Protocol), and can be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or later developed network.
[0199] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0200] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device:
[0201] Displaying a first virtual scene image corresponding to a first virtual character, where the first virtual character is a virtual character controlled by a first client;
[0202] In response to an original message sent by the second virtual character in the virtual scene, a target message is displayed in the first virtual scene screen, wherein the target message is determined according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message.
[0203] Alternatively, when the one or more programs are executed by the electronic device, the electronic device:
[0204] Displaying a second virtual scene image corresponding to the second virtual character;
[0205] In response to a message sending operation triggered in the second virtual scene screen, the second virtual character is controlled to send an original message in the virtual scene, wherein the original message is used to display a target message in the first virtual scene screen corresponding to the first virtual character, and the target message is determined based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, and the first virtual character is a virtual character controlled by the first client.
[0206] Alternatively, when the one or more programs are executed by the electronic device, the electronic device:
[0207] receiving an original message sent by the second virtual character in the virtual scene;
[0208] Obtaining a target message according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, wherein the first virtual character is a virtual character controlled by the first client;
[0209] The target message is sent to the first client, so that the first client displays the target message through a first virtual scene screen corresponding to the first virtual character.
[0210] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages, or a combination thereof, including, but not limited to, object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a stand-alone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0211] The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment, or a part of code, and the module, program segment, or a part of code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order than that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of the boxes in the block diagram and / or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0212] The modules described in the embodiments of the present disclosure may be implemented in software or hardware, wherein the name of a module does not necessarily limit the module itself.
[0213] The functions described above herein may be performed, at least in part, by one or more hardware logic components. For example, and without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0214] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of machine-readable storage media may include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), optical fibers, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0215] The above description is merely a preferred embodiment of the present disclosure and an illustration of the technical principles employed. Those skilled in the art should understand that the scope of the present disclosure is not limited to technical solutions formed by specific combinations of the aforementioned technical features. It also encompasses other technical solutions formed by any combination of the aforementioned technical features or their equivalents, without departing from the scope of the above disclosure. For example, a technical solution formed by replacing the aforementioned features with (but not limited to) technical features with similar functions disclosed in this disclosure.
[0216] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details have been included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.
[0217] Although the subject matter has been described using language specific to structural features and / or methodological logical acts, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are merely example forms of implementing the claims. Regarding the apparatus in the above-described embodiments, the specific manner in which each module performs operations has been described in detail in the embodiments related to the method and will not be elaborated upon here.
Claims
1. A message sending method, characterized in that: The method comprises: Displaying a first virtual scene image corresponding to a first virtual character, where the first virtual character is a virtual character controlled by a first client; In response to an original message sent by a second virtual character in a virtual scene, displaying a target message in the first virtual scene, wherein the target message is determined according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message; The target message is determined according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, including: In response to a distance between the first virtual character and the second virtual character in the virtual scene being no greater than a preset distance threshold, determining the original message as the target message; In response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than a preset distance threshold, part of the information in the original message is determined as the target message; or, in response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than the message receiving distance corresponding to the original message, an indication message is determined as the target message, wherein the indication message is used to instruct the second virtual character to send a message in the virtual scene, and the indication message does not contain the message content of the original message.
2. The method according to claim 1, characterized in that The determining part of the information in the original message as the target message includes: Based on the role attribute information of the first virtual role, information matching the role attribute information is determined from the original message, and the target message is determined according to the matching information.
3. The method according to any one of claims 1 to 2, characterized in that The displaying of the target message in the first virtual scene screen includes: The target message is displayed in the first virtual scene through a public chat channel in the first virtual scene, and / or the target message is displayed in the first virtual scene through a message bubble rendered on the second virtual character.
4. A message sending method, characterized in that: The method comprises: Displaying a second virtual scene image corresponding to the second virtual character; In response to a message sending operation triggered in the second virtual scene, controlling the second virtual character to send an original message in the virtual scene, wherein the original message is used to display a target message in the first virtual scene corresponding to the first virtual character, the target message being determined based on the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, and the first virtual character being a virtual character controlled by the first client; The target message is determined according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, including: In response to a distance between the first virtual character and the second virtual character in the virtual scene being no greater than a preset distance threshold, determining the original message as the target message; In response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than a preset distance threshold, part of the information in the original message is determined as the target message; or, in response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than the message receiving distance corresponding to the original message, an indication message is determined as the target message, wherein the indication message is used to instruct the second virtual character to send a message in the virtual scene, and the indication message does not contain the message content of the original message.
5. The method according to claim 4, characterized in that The first virtual character is a virtual character whose distance from the second virtual character in the virtual scene is not greater than a message receiving distance corresponding to the original message.
6. The method according to claim 5, characterized in that The message receiving distance is determined by the following steps: determining the message receiving distance according to the message sending mode selected for sending the original message, wherein different message sending modes correspond to different message receiving distances; or The message receiving distance is determined according to the specified distance.
7. A message sending method, characterized in that: The method comprises: receiving an original message sent by the second virtual character in the virtual scene; Obtaining a target message according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message, wherein the first virtual character is a virtual character controlled by the first client; Sending the target message to the first client, so that the first client displays the target message through a first virtual scene screen corresponding to the first virtual character; The obtaining of the target message according to the spatial positions of the first virtual character and the second virtual character in the virtual scene and the original message includes: In response to a distance between the first virtual character and the second virtual character in the virtual scene being no greater than a preset distance threshold, determining the original message as the target message; In response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than a preset distance threshold, part of the information in the original message is determined as the target message; or, in response to the distance between the first virtual character and the second virtual character in the virtual scene being greater than the message receiving distance corresponding to the original message, an indication message is determined as the target message, wherein the indication message is used to instruct the second virtual character to send a message in the virtual scene, and the indication message does not contain the message content of the original message.
8. The method according to claim 7, characterized in that The first virtual character is determined by the following steps: determining a distance between the virtual character in the virtual scene and the second virtual character; The virtual character whose distance is not greater than the message receiving distance corresponding to the original message is determined as the first virtual character.
9. The method according to claim 8, characterized in that The determining the distance between the virtual character in the virtual scene and the second virtual character includes: determining an initial distance between the virtual character and the second virtual character according to first position information of the virtual character in the virtual scene and second position information of the second virtual character in the virtual scene; The initial distance is adjusted according to the character perception ability corresponding to the virtual character and / or an obstruction between the virtual character and the second virtual character to obtain the distance between the virtual character and the second virtual character in the virtual scene.
10. A computer-readable medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processing device, it implements the steps of the method according to any one of claims 1 to 3, and / or implements the steps of the method according to any one of claims 4 to 6, and / or implements the steps of the method according to any one of claims 7 to 9.
11. An electronic device, characterized in that: include: a storage device having a computer program stored thereon; A processing device for executing the computer program in the storage device to implement the steps of the method of any one of claims 1 to 3, and / or to implement the steps of the method of any one of claims 4 to 6, and / or to implement the steps of the method of any one of claims 7 to 9.
12. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 3, and / or implements the steps of the method according to any one of claims 4 to 6, and / or implements the steps of the method according to any one of claims 7 to 9.