CN110694277A - Method, device, medium and electronic equipment for responding to user request - Google Patents

Method, device, medium and electronic equipment for responding to user request Download PDF

Info

Publication number
CN110694277A
CN110694277A CN201910915329.3A CN201910915329A CN110694277A CN 110694277 A CN110694277 A CN 110694277A CN 201910915329 A CN201910915329 A CN 201910915329A CN 110694277 A CN110694277 A CN 110694277A
Authority
CN
China
Prior art keywords
time sequence
sequence information
user request
information
responding
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910915329.3A
Other languages
Chinese (zh)
Inventor
尚乐
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Netease Hangzhou Network Co Ltd
Original Assignee
Netease Hangzhou Network Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Netease Hangzhou Network Co Ltd filed Critical Netease Hangzhou Network Co Ltd
Priority to CN201910915329.3A priority Critical patent/CN110694277A/en
Publication of CN110694277A publication Critical patent/CN110694277A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/70Game security or game management aspects
    • A63F13/75Enforcing rules, e.g. detecting foul play or generating lists of cheating players
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F13/00Video games, i.e. games using an electronically generated display having two or more dimensions
    • A63F13/85Providing additional services to players
    • A63F13/86Watching games played by other players
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F2300/00Features of games using an electronically generated display having two or more dimensions, e.g. on a television screen, showing representations related to the game
    • A63F2300/50Features of games using an electronically generated display having two or more dimensions, e.g. on a television screen, showing representations related to the game characterized by details of game servers
    • A63F2300/57Features of games using an electronically generated display having two or more dimensions, e.g. on a television screen, showing representations related to the game characterized by details of game servers details of game services offered to the player
    • A63F2300/577Features of games using an electronically generated display having two or more dimensions, e.g. on a television screen, showing representations related to the game characterized by details of game servers details of game services offered to the player for watching a game played by other players

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Business, Economics & Management (AREA)
  • Computer Security & Cryptography (AREA)
  • General Business, Economics & Management (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the invention provides a method for responding to a user request, a device for responding to the user request, a computer readable medium and electronic equipment, and relates to the technical field of computers. The method comprises the following steps: acquiring first time sequence information, and acquiring the time sequence information according to a preset time interval to obtain second time sequence information; the timestamp corresponding to the first time sequence information is earlier than the timestamp corresponding to the second time sequence information; updating the first time sequence information and the second time sequence information according to each time sequence information acquisition result; and after receiving the user request, responding to the user request if the first time sequence information and the second time sequence information are detected to exist. Therefore, the technical scheme of the embodiment of the invention can overcome the problem of adverse effect on the fairness of the game to a certain extent, further reduce the adverse effect of the fighting function on the fairness of the game and improve the game experience of users.

Description

Method, device, medium and electronic equipment for responding to user request
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method for responding to a user request, an apparatus for responding to a user request, a computer-readable medium, and an electronic device.
Background
For competitive games, providing a spectator function may enable a player to view the battle process of other players in a third person's identity. Specifically, the spectator player needs to send a user request to the server, and the server can add the spectator player to the game list after receiving the user request, so that the spectator player can view the current battle and the real-time battle information (such as the position, skill and gain of the battle unit) of both the battle player and the battle player. However, if a player in a battle views the participating battles with multiple devices, real-time battle information of an opponent is observed, which adversely affects the fairness of the game.
It is to be noted that the information disclosed in the above background section is only for enhancement of understanding of the background of the present invention and therefore may include information that does not constitute prior art known to a person of ordinary skill in the art.
Disclosure of Invention
Embodiments of the present invention provide a method for responding to a user request, a device for responding to a user request, a computer-readable medium, and an electronic device, which can overcome the problem of adverse effects on game fairness at least to a certain extent, thereby reducing adverse effects of a fighting function on game fairness, and improving game experience of users.
A first aspect of an embodiment of the present invention provides a method for responding to a user request, including:
acquiring first time sequence information, and acquiring the time sequence information according to a preset time interval to obtain second time sequence information; the timestamp corresponding to the first time sequence information is earlier than the timestamp corresponding to the second time sequence information;
updating the first time sequence information and the second time sequence information according to each time sequence information acquisition result;
and after receiving the user request, responding to the user request if the first time sequence information and the second time sequence information are detected to exist.
In an exemplary embodiment of the present invention, the method of responding to a user request further includes:
and acquiring a data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the second time sequence information and storing the data protocol in a cache.
In an exemplary embodiment of the present invention, the method of responding to a user request further includes:
and updating the data protocol in the cache according to the updating results of the first time sequence information and the second time sequence information and the data protocol sent by the server in real time.
In one exemplary embodiment of the present invention, responding to a user request includes:
and sending the data protocol and the first time sequence information to the client sending the user request.
In an exemplary embodiment of the present invention, updating the first timing information and the second timing information according to each time of the timing information acquisition result includes:
after the second time sequence information is obtained, third time sequence information is obtained according to a preset time interval;
deleting the first time sequence information, determining the second time sequence information as new first time sequence information, and determining the third time sequence information as new second time sequence information;
and updating the first time sequence information and the second time sequence information when the time sequence information acquisition result is obtained at preset time intervals.
In an exemplary embodiment of the present invention, the method of responding to a user request further includes:
and if the first time sequence information is detected to exist and the second time sequence information is not detected to exist, sending prompt information for indicating that data transmission cannot be carried out currently to the client.
In an exemplary embodiment of the present invention, the method of responding to a user request further includes:
and if the first time sequence information is detected to exist and the second time sequence information is not detected to exist, determining the waiting time length according to the preset time interval and the current time, and responding to the user request after the waiting time length is detected to arrive.
According to a second aspect of the embodiments of the present invention, there is provided an apparatus for responding to a user request, including a timing information acquisition unit, a timing information update unit, and a user request response unit, wherein:
the time sequence information acquisition unit is used for acquiring first time sequence information and acquiring time sequence information according to a preset time interval to obtain second time sequence information; the first timestamp corresponding to the first timing information is earlier than the second timestamp corresponding to the second timing information;
the time sequence information updating unit is used for updating the first time sequence information and the second time sequence information according to each time sequence information acquisition result;
and the user request responding unit is used for responding to the user request if the first time sequence information and the second time sequence information are detected to exist after the user request is received.
In an exemplary embodiment of the present invention, the apparatus for responding to a user request further includes a data protocol acquisition unit, wherein:
and the data protocol acquisition unit is used for acquiring a data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the second time sequence information and storing the data protocol into the cache.
In an exemplary embodiment of the present invention, the apparatus for responding to a user request further includes a data protocol updating unit, wherein:
and the data protocol updating unit is used for updating the data protocol in the cache according to the updating results of the first time sequence information and the second time sequence information and the data protocol sent by the server in real time.
In an exemplary embodiment of the present invention, a manner of the user request responding unit responding to the user request may specifically be:
the user request response unit sends the data protocol and the first time sequence information to the client side sending the user request.
In an exemplary embodiment of the present invention, the manner of updating the first timing information and the second timing information by the timing information updating unit according to each time of the timing information obtaining result may specifically be:
after the second time sequence information is obtained, the time sequence information updating unit acquires third time sequence information according to a preset time interval;
the time sequence information updating unit deletes the first time sequence information, determines the second time sequence information as new first time sequence information, and determines the third time sequence information as new second time sequence information;
and the time sequence information updating unit updates the first time sequence information and the second time sequence information when obtaining the time sequence information acquisition result at preset time intervals.
In an exemplary embodiment of the present invention, the apparatus for responding to a user request further includes an information transmitting unit, wherein:
and the information sending unit is used for sending prompt information for indicating that the data transmission cannot be carried out currently to the client when the first time sequence information is detected to exist and the second time sequence information does not exist.
In an exemplary embodiment of the invention, the user request responding unit is further configured to determine a waiting duration according to a preset time interval and a current time when it is detected that the first timing information does not exist and the second timing information does not exist, and respond to the user request after it is detected that the waiting duration arrives.
According to a third aspect of embodiments of the present invention, there is provided a computer readable medium having stored thereon a computer program which, when executed by a processor, implements the method of responding to a user request as described in the first aspect of the embodiments above.
According to a fourth aspect of embodiments of the present invention, there is provided an electronic apparatus, including: one or more processors; storage means for storing one or more programs which, when executed by one or more processors, cause the one or more processors to carry out a method of responding to a user request as described in the first aspect of the embodiments above.
The technical scheme provided by the embodiment of the invention has the following beneficial effects:
in the technical solutions provided in some embodiments of the present invention, a terminal device or a server may obtain first timing information (i.e., combat snapshot information), and obtain the timing information according to a preset time interval to obtain second timing information (i.e., combat snapshot information); the timestamp corresponding to the first time sequence information is earlier than the timestamp corresponding to the second time sequence information; furthermore, the first timing information and the second timing information can be updated according to each time of the timing information acquisition result; further, the user request (e.g., the fighting request) may be responded to if the presence of the first timing information and the second timing information is detected after the user request is received. According to the scheme, on one hand, the problem of adverse effect on the fairness of the game can be overcome to a certain extent, and the adverse effect of the fighting function on the fairness of the game is further reduced, so that the game experience of a user is improved; on the other hand, the embodiment of the invention adds the double-snapshot function to support delayed spectator battle on the basis of spectator battle implementation, thereby not only ensuring the real-time performance of spectator battle to a certain extent, but also reducing the influence of more sets of standby real-time spectator battle on the fairness of games.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention, as claimed.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and together with the description, serve to explain the principles of the invention. It is obvious that the drawings in the following description are only some embodiments of the invention, and that for a person skilled in the art, other drawings can be derived from them without inventive effort. In the drawings:
FIG. 1 schematically shows a flow diagram of a method of responding to a user request according to an embodiment of the invention;
fig. 2 is a schematic diagram of a combat timeline for acquiring timing information according to a preset time interval according to an embodiment of the present invention;
fig. 3 is a schematic diagram of a combat timeline in which third timing information is acquired according to a preset time interval after the second timing information is obtained according to an embodiment of the present invention;
fig. 4 is a diagram schematically showing a battle time axis in which first timing information and second timing information are updated according to a timing information acquisition result according to an embodiment of the present invention;
FIG. 5 is a block diagram schematically illustrating an apparatus for responding to a user request according to an embodiment of the present invention;
FIG. 6 illustrates a schematic structural diagram of a computer system suitable for use with the electronic device to implement an embodiment of the invention.
Detailed Description
Example embodiments will now be described more fully with reference to the accompanying drawings. Example embodiments may, however, be embodied in many different forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the concept of example embodiments to those skilled in the art.
Furthermore, the described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to provide a thorough understanding of embodiments of the invention. One skilled in the relevant art will recognize, however, that the invention may be practiced without one or more of the specific details, or with other methods, components, devices, steps, and so forth. In other instances, well-known methods, devices, implementations or operations have not been shown or described in detail to avoid obscuring aspects of the invention.
The block diagrams shown in the figures are functional entities only and do not necessarily correspond to physically separate entities. I.e. these functional entities may be implemented in the form of software, or in one or more hardware modules or integrated circuits, or in different networks and/or processor means and/or microcontroller means.
The flow charts shown in the drawings are merely illustrative and do not necessarily include all of the contents and operations/steps, nor do they necessarily have to be performed in the order described. For example, some operations/steps may be decomposed, and some operations/steps may be combined or partially combined, so that the actual execution sequence may be changed according to the actual situation.
Referring to fig. 1, fig. 1 schematically illustrates a flowchart of a method for responding to a user request according to an embodiment of the present invention, where the method for responding to a user request may be implemented by a server or a terminal device (e.g., a mobile terminal).
As shown in fig. 1, the method for responding to a user request according to an embodiment of the present invention includes the following steps S110, S120, and S130, wherein:
step S110: acquiring first time sequence information, and acquiring the time sequence information according to a preset time interval to obtain second time sequence information; and the timestamp corresponding to the first time sequence information is earlier than the timestamp corresponding to the second time sequence information.
Step S120: and updating the first time sequence information and the second time sequence information according to the time sequence information acquisition result each time.
Step S130: and after receiving the user request, responding to the user request if the first time sequence information and the second time sequence information are detected to exist.
The embodiment of the invention can be applied to competitive games with the fighting function.
The following describes the steps in detail:
in step S110, acquiring first timing information, and acquiring timing information according to a preset time interval to obtain second timing information; and the timestamp corresponding to the first time sequence information is earlier than the timestamp corresponding to the second time sequence information.
In the embodiment of the present invention, the first time sequence information and the second time sequence information are necessary information for the client to construct a battle, and both the first time sequence information and the second time sequence information may include a position, a blood volume, a legal power value, a skill, a legal gain, and the like of a battle unit in the competitive game.
In the embodiment of the present invention, the manner of obtaining the first timing information may specifically be: a first snapshot of the battlefield information is taken to obtain first timing information. Similarly, the manner of obtaining the second timing information may be: and carrying out a second snapshot on the battlefield information to obtain second time sequence information. The battlefield information can be understood as time sequence information. In addition, the time sequence information has a precedence order according to the corresponding snapshot time.
In this embodiment of the present invention, optionally, the method for responding to the user request may further include the following steps:
and acquiring a data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the second time sequence information and storing the data protocol in a cache.
In the embodiment of the invention, the data protocol can be understood as a combat protocol in the competitive game. In addition, it can be understood that a data protocol is used to represent the change process between the first timing information and the second timing information. In addition, the data protocol may be retrieved by the server and stored in a cache.
Therefore, by implementing the embodiment of the invention, the delayed fighting can be realized through the cache data protocol, and the problem that the fairness of the game is influenced by the real-time fighting of one party in the competitive game through a plurality of pieces of equipment is solved to a certain extent.
In step S120, the first timing information and the second timing information are updated according to each timing information acquisition result.
In the embodiment of the invention, the server can carry out a plurality of times of snapshots on the current battle; each snapshot may correspond to timing information, and the timing information may be understood as the above-mentioned timing information obtaining result. Furthermore, the time intervals (i.e., preset time intervals) between two adjacent snapshots are equal; wherein, the preset time interval can be set according to the requirement.
In this embodiment of the present invention, optionally, the updating the first timing information and the second timing information according to each timing information obtaining result includes:
after the second time sequence information is obtained, third time sequence information is obtained according to a preset time interval;
deleting the first time sequence information, determining the second time sequence information as new first time sequence information, and determining the third time sequence information as new second time sequence information;
and updating the first time sequence information and the second time sequence information when the time sequence information acquisition result is obtained at preset time intervals.
In the embodiment of the invention, the time sequence information can be acquired for N times according to the time sequence information acquisition every other preset time interval; wherein N is a positive integer. The determination method of N is as follows: and determining to obtain the value of N according to the ratio of the time length corresponding to the time axis to the preset time interval.
Therefore, by implementing the embodiment of the invention, the time sequence information can be updated according to the continuous time sequence information acquisition operation, so that the problem of resource occupation caused by storing a large amount of time sequence information is solved.
In this embodiment of the present invention, optionally, the method for responding to the user request may further include the following steps:
and updating the data protocol in the cache according to the updating results of the first time sequence information and the second time sequence information and the data protocol sent by the server in real time.
In the embodiment of the present invention, the update result includes the updated first timing information and the second timing information.
In this embodiment of the present invention, the manner of updating the data protocol in the cache according to the update results of the first timing information and the second timing information and the data protocol sent by the server in real time may specifically be:
discarding a data protocol before a timestamp corresponding to the first time sequence information in the updating result, and storing the data protocol between the timestamp corresponding to the second time sequence information and the current time into a cache; wherein the current time may be a current battle time.
Therefore, by implementing the embodiment of the invention, the occupation of the fighting content corresponding to the played data protocol on the cache space can be reduced by updating the data protocol in the cache, and the resource utilization rate and the efficiency of calling the data protocol are improved.
In step S130, after receiving the user request, if it is detected that the first timing information and the second timing information exist, the user request is responded.
In this embodiment of the present invention, optionally, responding to the user request includes:
and sending the data protocol and the first time sequence information to the client sending the user request.
In the embodiment of the present invention, the sending of the data protocol and the first timing information to the client that sends the user request may specifically be:
and sending a data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the second time sequence information and a data protocol between the timestamp corresponding to the second time sequence information and the timestamp corresponding to the user request to the client.
Therefore, by implementing the embodiment of the invention, the first time sequence information and the data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the user request can be sent to the client, the client can display the first time sequence information and sequentially output the output contents corresponding to the data protocol according to the time shaft sequence, and the problem that the fairness of the game is influenced by the fact that a fighter watches the battle in real time through multiple pieces of equipment is solved to a certain extent.
In this embodiment of the present invention, optionally, the method for responding to the user request may further include the following steps:
and if the first time sequence information is detected to exist and the second time sequence information is not detected to exist, sending prompt information for indicating that data transmission cannot be carried out currently to the client.
Further, the method can also comprise the following steps: and outputting a prompt sound effect for indicating that the data transmission cannot be carried out currently.
In the embodiment of the invention, the fact that the first time sequence information is detected and the second time sequence information is not detected indicates that the time interval from the start time of the battle is short, and if the battle request of a user is responded at the moment, the problem that the fairness of the game is influenced by the fact that a party in the battle watches the battle in real time through a plurality of pieces of equipment exists. Therefore, it is necessary to respond to the user request when the presence of the first timing information and the presence of the second timing information are detected.
Therefore, the embodiment of the invention can support the delayed fighting function by adding the double-snapshot function.
In this embodiment of the present invention, optionally, the method for responding to the user request may further include the following steps:
and if the first time sequence information is detected to exist and the second time sequence information is not detected to exist, determining the waiting time length according to the preset time interval and the current time, and responding to the user request after the waiting time length is detected to arrive.
In the embodiment of the present invention, the manner of determining the waiting duration according to the preset time interval and the current time may specifically be:
determining a target timestamp corresponding to the latest time sequence information acquisition before the current time, and determining a target time interval between the current time and the target timestamp;
if the target time interval is smaller than the preset time interval, determining the difference value between the preset time interval and the target time interval as the waiting time length; wherein the waiting duration plus the target time interval equals a preset time interval.
In addition, the preset time interval may be set manually, and if the user sets it to 0, the spectator may be implemented, and if the user sets it to a value greater than 0, the time-delayed spectator may be implemented.
Therefore, by implementing the embodiment of the invention, both real-time fighting and delayed fighting can be considered, and more fighting experience can be provided for users.
Therefore, the method for responding to the user request shown in fig. 1 can be implemented by adding the double-snapshot function on the basis of implementing the spectator fighting so as to support the delayed spectator fighting, thereby not only ensuring the real-time performance of the spectator fighting to a certain extent, but also reducing the influence of more standby real-time spectator fighting on the fairness of the game.
Referring to fig. 2, fig. 2 is a schematic diagram of a battle timeline for acquiring timing information according to a preset time interval according to an embodiment of the invention. As shown in fig. 2, a first snapshot may be performed at a start position of a battle time axis, the first snapshot may obtain first timing information, and the timing information may be obtained after a preset time interval, that is, the second snapshot may obtain second timing information. The server may store a data protocol (i.e., a combat protocol) between the timestamp corresponding to the first timing information and the timestamp corresponding to the second timing information in the cache, so that the data protocol is sent to the client of the spectator player after the spectator player joins the combat list.
Referring to fig. 3 in conjunction with the schematic view of the combat timeline shown in fig. 2 for acquiring timing information according to a preset time interval, fig. 3 schematically shows the schematic view of the combat timeline for acquiring third timing information according to the preset time interval after acquiring the second timing information according to an embodiment of the present invention. As shown in fig. 3, after the second timing information is obtained, a third snapshot may be performed according to a preset time interval to obtain third timing information. Wherein, the server may store a data protocol (i.e., a combat protocol) between the timestamp corresponding to the second timing information and the timestamp corresponding to the third timing information in the cache.
Referring to fig. 4 in conjunction with the schematic view of the combat timeline shown in fig. 3, which is used for acquiring the third time sequence information according to the preset time interval after the second time sequence information is obtained, fig. 4 schematically shows the schematic view of the combat timeline in which the first time sequence information and the second time sequence information are updated according to the acquisition result of the time sequence information according to the embodiment of the present invention. As shown in fig. 4, the server may delete the first timing information corresponding to the first snapshot, and further, may determine the second timing information corresponding to the second snapshot in the graph as new first timing information, and determine the third timing information corresponding to the third snapshot in the graph as new second timing information. Thus, only two pieces of time sequence information are ensured in the fighting time axis, one is the latest fighting time sequence information (namely, the new second time sequence information), and the other is the fighting time sequence information which is preset time interval from the latest fighting time sequence information and is acquired later than the latest fighting time sequence information (namely, the new first time sequence information).
Furthermore, the data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the second time sequence information in the cache can be deleted/discarded, and only the data protocol between the timestamp corresponding to the second time sequence information and the timestamp corresponding to the third time sequence information is reserved, so that the occupation of the data protocol on the cache can be reduced. In addition, after the third snapshot, multiple snapshots (not shown in the figure) may be performed, the time interval of each snapshot is a preset time interval, and each time snapshot information (i.e., timing information) is acquired, the snapshot information with the earliest timestamp is deleted, so as to reduce the occupation of server resources and improve the resource utilization rate. In addition, when a fighting request (i.e., the user request) is received and it is detected that the first time sequence information and the second time sequence information exist, the server may add the client corresponding to the fighting request into the current fighting, and send a fighting protocol between a timestamp corresponding to the first time sequence information and a timestamp corresponding to the second time sequence information and a fighting protocol between a timestamp corresponding to the second time sequence information and a timestamp corresponding to the fighting request to the client; the time stamp corresponding to the fighting request is later than the time stamp corresponding to the second time sequence information, so that the function of delaying fighting can be realized, and the problem that the fairness of the game is influenced by the real-time fighting of a fighting party through multi-switch equipment in the competitive game is solved to a certain extent.
Note that the preset time interval described in any of fig. 2 to 4 may be set manually.
It can be seen that, when the embodiment of the invention is implemented by combining fig. 4 to fig. 5, a double snapshot function can be added on the basis of implementing the spectator fighting to support the delayed spectator fighting, so that not only can the real-time performance of the spectator fighting be ensured to a certain extent, but also the influence of more standby real-time spectator fighting on the fairness of the game can be reduced.
Referring to fig. 5, fig. 5 is a block diagram schematically illustrating a structure of an apparatus for responding to a user request according to an embodiment of the present invention. The apparatus for responding to the user request includes a timing information obtaining unit 501, a timing information updating unit 502, and a user request responding unit 503, wherein:
a timing information obtaining unit 501, configured to obtain first timing information, and obtain timing information according to a preset time interval to obtain second timing information; the first timestamp corresponding to the first timing information is earlier than the second timestamp corresponding to the second timing information;
a timing information updating unit 502, configured to update the first timing information and the second timing information according to each timing information obtaining result;
the user request responding unit 503 is configured to, after receiving the user request, respond to the user request if it is detected that the first timing information and the second timing information exist.
It can be seen that the device for responding to the user request shown in fig. 5 can add the double snapshot function to support the delayed viewing based on the viewing, not only can guarantee the real-time performance of the viewing to a certain extent, but also can reduce the influence of the multiple standby real-time viewing on the fairness of the game.
As an optional implementation manner, the apparatus for responding to the user request further includes a data protocol obtaining unit (not shown), wherein:
and the data protocol acquisition unit is used for acquiring a data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the second time sequence information and storing the data protocol into the cache.
Therefore, by implementing the embodiment of the invention, the delayed fighting can be realized through the cache data protocol, and the problem that the fairness of the game is influenced by the real-time fighting of one party in the competitive game through a plurality of pieces of equipment is solved to a certain extent.
As another optional implementation, the apparatus for responding to the user request further includes a data protocol updating unit (not shown), wherein:
and the data protocol updating unit is used for updating the data protocol in the cache according to the updating results of the first time sequence information and the second time sequence information and the data protocol sent by the server in real time.
Therefore, by implementing the embodiment of the invention, the occupation of the fighting content corresponding to the played data protocol on the cache space can be reduced by updating the data protocol in the cache, and the resource utilization rate and the efficiency of calling the data protocol are improved.
As another optional implementation manner, the manner in which the user request responding unit 503 responds to the user request may specifically be:
the user request response unit 503 sends the data protocol and the first timing information to the client that sent the user request.
Therefore, by implementing the embodiment of the invention, the first time sequence information and the data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the user request can be sent to the client, the client can display the first time sequence information and sequentially output the output contents corresponding to the data protocol according to the time shaft sequence, and the problem that the fairness of the game is influenced by the fact that a fighter watches the battle in real time through multiple pieces of equipment is solved to a certain extent.
As another optional implementation manner, the manner in which the timing information updating unit 502 updates the first timing information and the second timing information according to each timing information obtaining result may specifically be:
after the second timing information is obtained, the timing information updating unit 502 obtains third timing information according to a preset time interval;
the timing information updating unit 502 deletes the first timing information, determines the second timing information as new first timing information, and determines the third timing information as new second timing information;
the timing information updating unit 502 updates the first timing information and the second timing information every a preset time interval when obtaining the timing information acquisition result.
Therefore, by implementing the embodiment of the invention, the time sequence information can be updated according to the continuous time sequence information acquisition operation, so that the problem of resource occupation caused by storing a large amount of time sequence information is solved.
As another optional implementation, the apparatus for responding to the user request further includes an information sending unit (not shown), wherein:
and the information sending unit is used for sending prompt information for indicating that the data transmission cannot be carried out currently to the client when the first time sequence information is detected to exist and the second time sequence information does not exist.
Therefore, the embodiment of the invention can support the delayed fighting function by adding the double-snapshot function.
As another alternative implementation, the user request responding unit 503 is further configured to determine, when it is detected that the first timing information does not exist and the second timing information does not exist, a waiting duration according to a preset time interval and a current time, and respond to the user request after it is detected that the waiting duration arrives.
Therefore, by implementing the embodiment of the invention, both real-time fighting and delayed fighting can be considered, and more fighting experience can be provided for users.
For details that are not disclosed in the embodiments of the apparatus of the present invention, reference is made to the above-described embodiments of the method for responding to a user request of the present invention for details that are not disclosed in the embodiments of the apparatus of the present invention, since each functional module of the apparatus for responding to a user request of the present invention corresponds to a step of the above-described exemplary embodiment of the method for responding to a user request.
Referring to FIG. 6, a block diagram of a computer system 600 suitable for use with the electronic device implementing embodiments of the invention is shown. The computer system 600 of the electronic device shown in fig. 6 is only an example, and should not bring any limitation to the function and the scope of the use of the embodiments of the present invention.
As shown in fig. 6, the computer system 600 includes a Central Processing Unit (CPU)601 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)602 or a program loaded from a storage section 608 into a Random Access Memory (RAM) 603. In the RAM 603, various programs and data necessary for system operation are also stored. The CPU601, ROM 602, and RAM 603 are connected to each other via a bus 604. An input/output (I/O) interface 605 is also connected to bus 604.
The following components are connected to the I/O interface 605: an input portion 606 including a keyboard, a mouse, and the like; an output portion 607 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage section 608 including a hard disk and the like; and a communication section 609 including a network interface card such as a LAN card, a modem, or the like. The communication section 609 performs communication processing via a network such as the internet. The driver 610 is also connected to the I/O interface 605 as needed. A removable medium 611 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 610 as necessary, so that a computer program read out therefrom is mounted in the storage section 608 as necessary.
In particular, according to an embodiment of the present invention, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the invention include a computer program product comprising a computer program embodied on a computer-readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 609, and/or installed from the removable medium 611. The above-described functions defined in the system of the present application are executed when the computer program is executed by the Central Processing Unit (CPU) 601.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, 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 appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present invention may be implemented by software, or may be implemented by hardware, and the described units may also be disposed in a processor. Wherein the names of the elements do not in some way constitute a limitation on the elements themselves.
As another aspect, the present application also provides a computer-readable medium, which may be contained in the electronic device described in the above embodiments; or may exist separately without being assembled into the electronic device. The computer readable medium carries one or more programs which, when executed by an electronic device, cause the electronic device to implement the method for responding to a user request as described in the above embodiments.
For example, the electronic device may implement the following as shown in fig. 1: step S110, acquiring first timing information, and acquiring timing information according to a preset time interval to obtain second timing information; the timestamp corresponding to the first time sequence information is earlier than the timestamp corresponding to the second time sequence information; step S120, updating the first time sequence information and the second time sequence information according to each time sequence information acquisition result; step S130, after receiving the user request, if it is detected that the first timing information and the second timing information exist, responding to the user request.
It should be noted that although in the above detailed description several modules or units of the device for action execution are mentioned, such a division is not mandatory. Indeed, the features and functionality of two or more modules or units described above may be embodied in one module or unit, according to embodiments of the invention. Conversely, the features and functions of one module or unit described above may be further divided into embodiments by a plurality of modules or units.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiment of the present invention can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which can be a personal computer, a server, a touch terminal, or a network device, etc.) to execute the method according to the embodiment of the present invention.
Other embodiments of the invention will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the invention following, in general, the principles of the invention and including such departures from the present disclosure as come within known or customary practice within the art to which the invention pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the invention being indicated by the following claims.
It will be understood that the invention is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the invention is limited only by the appended claims.

Claims (10)

1. A method of responding to a user request, comprising:
acquiring first time sequence information, and acquiring the time sequence information according to a preset time interval to obtain second time sequence information; wherein the timestamp corresponding to the first timing information is earlier than the timestamp corresponding to the second timing information;
updating the first time sequence information and the second time sequence information according to each time sequence information acquisition result;
and after receiving a user request, responding to the user request if the first time sequence information and the second time sequence information are detected to exist.
2. The method of claim 1, further comprising:
and acquiring a data protocol between the timestamp corresponding to the first time sequence information and the timestamp corresponding to the second time sequence information and storing the data protocol in a cache.
3. The method of claim 2, further comprising:
and updating the data protocol in the cache according to the updating results of the first time sequence information and the second time sequence information and the data protocol sent by the server in real time.
4. The method of claim 2, wherein responding to the user request comprises:
and sending the data protocol and the first timing information to a client sending the user request.
5. The method of claim 1, wherein updating the first timing information and the second timing information according to each timing information obtaining result comprises:
after the second time sequence information is obtained, third time sequence information is obtained according to the preset time interval;
deleting the first time sequence information, determining the second time sequence information as new first time sequence information, and determining the third time sequence information as new second time sequence information;
and updating the first time sequence information and the second time sequence information when the time sequence information acquisition result is obtained at intervals of the preset time interval.
6. The method of claim 1, further comprising:
and if the first time sequence information is detected to exist and the second time sequence information is not detected to exist, sending prompt information for indicating that data transmission cannot be carried out currently to a client.
7. The method of claim 1, further comprising:
if the first time sequence information is detected to exist, and the second time sequence information is not detected to exist, determining a waiting time length according to the preset time interval and the current time, and responding to the user request after the waiting time length is detected to arrive.
8. An apparatus for responding to a user request, comprising:
the time sequence information acquisition unit is used for acquiring first time sequence information and acquiring time sequence information according to a preset time interval to obtain second time sequence information; wherein a first timestamp corresponding to the first timing information is earlier than a second timestamp corresponding to the second timing information;
a timing information updating unit, configured to update the first timing information and the second timing information according to each timing information acquisition result;
and the user request responding unit is used for responding to the user request if the first time sequence information and the second time sequence information are detected to exist after the user request is received.
9. A computer-readable medium, on which a computer program is stored which, when being executed by a processor, carries out the method of responding to a user request according to any one of claims 1 to 7.
10. An electronic device, comprising:
one or more processors;
storage means for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to carry out a method of responding to a user request according to any one of claims 1 to 7.
CN201910915329.3A 2019-09-26 2019-09-26 Method, device, medium and electronic equipment for responding to user request Pending CN110694277A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910915329.3A CN110694277A (en) 2019-09-26 2019-09-26 Method, device, medium and electronic equipment for responding to user request

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910915329.3A CN110694277A (en) 2019-09-26 2019-09-26 Method, device, medium and electronic equipment for responding to user request

Publications (1)

Publication Number Publication Date
CN110694277A true CN110694277A (en) 2020-01-17

Family

ID=69196445

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910915329.3A Pending CN110694277A (en) 2019-09-26 2019-09-26 Method, device, medium and electronic equipment for responding to user request

Country Status (1)

Country Link
CN (1) CN110694277A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104998412A (en) * 2015-07-14 2015-10-28 北京视博云科技有限公司 Single-player game realization method and apparatus
CN105721947A (en) * 2016-02-02 2016-06-29 上海逗屋网络科技有限公司 Method for providing target multi-user interaction video and server
CN106693367A (en) * 2017-01-25 2017-05-24 腾讯科技(深圳)有限公司 Processing method of display data at client, server and client
CN108043033A (en) * 2018-02-01 2018-05-18 网易(杭州)网络有限公司 Watch method and storage medium in games system
CN108174267A (en) * 2017-12-21 2018-06-15 平安科技(深圳)有限公司 The sending device of interactive information, method and computer readable storage medium in live streaming
CN109692480A (en) * 2019-02-02 2019-04-30 网易(杭州)网络有限公司 It watches in a kind of online game method and apparatus

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104998412A (en) * 2015-07-14 2015-10-28 北京视博云科技有限公司 Single-player game realization method and apparatus
CN105721947A (en) * 2016-02-02 2016-06-29 上海逗屋网络科技有限公司 Method for providing target multi-user interaction video and server
CN106693367A (en) * 2017-01-25 2017-05-24 腾讯科技(深圳)有限公司 Processing method of display data at client, server and client
CN108174267A (en) * 2017-12-21 2018-06-15 平安科技(深圳)有限公司 The sending device of interactive information, method and computer readable storage medium in live streaming
CN108043033A (en) * 2018-02-01 2018-05-18 网易(杭州)网络有限公司 Watch method and storage medium in games system
CN109692480A (en) * 2019-02-02 2019-04-30 网易(杭州)网络有限公司 It watches in a kind of online game method and apparatus

Similar Documents

Publication Publication Date Title
CN110166791B (en) Connection establishing method, device, equipment and storage medium
CN110099134B (en) Video file downloading method and device, electronic equipment and storage medium
CN106453667B (en) Update data cached method and device
CN109224435B (en) Online game acceleration method and device, electronic equipment and storage medium
CN110765744A (en) Multi-person collaborative document editing method and system
CN108452525B (en) Method and system for monitoring chat information in game
CN112337102B (en) Live broadcast data processing method and device, electronic equipment and storage medium
CN111629224B (en) Live broadcast information processing method and device, computer storage medium and electronic equipment
JP7476327B2 (en) AUDIO DATA PROCESSING METHOD, DELAY TIME ACQUISITION METHOD, SERVER, AND COMPUTER PROGRAM
CN112337101A (en) Live broadcast-based data interaction method and device, electronic equipment and readable medium
CN110025958B (en) Voice sending method, device, medium and electronic equipment
US20220312078A1 (en) Method and apparatus for interaction in live streaming room, readable medium and electronic device
CN111135586B (en) Game matching method, game matching device, storage medium and electronic equipment
CN112337104A (en) Live broadcast data processing method and device, electronic equipment and readable medium
CN114173139B (en) Live broadcast interaction method, system and related device
CN106971296B (en) Method for processing information object, electronic equipment and storage medium
CN113144620A (en) Detection method, device, platform, readable medium and equipment for frame synchronization game
CN110694277A (en) Method, device, medium and electronic equipment for responding to user request
CN107277640A (en) Interactive approach, device and storage medium based on live platform
CN112312151B (en) Data updating method, device and storage medium
CN111625375B (en) Account reservation method and device, storage medium and electronic equipment
CN115022106A (en) Group information processing method, device, equipment and medium
CN110251943B (en) Game player matching method, device, equipment and storage medium
CN109847341B (en) Cloud game method and equipment
CN106934655B (en) Advertisement pushing method and device based on user feedback

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination