CN115456665A - Resource allocation method, system, electronic device and storage medium - Google Patents

Resource allocation method, system, electronic device and storage medium Download PDF

Info

Publication number
CN115456665A
CN115456665A CN202211062694.2A CN202211062694A CN115456665A CN 115456665 A CN115456665 A CN 115456665A CN 202211062694 A CN202211062694 A CN 202211062694A CN 115456665 A CN115456665 A CN 115456665A
Authority
CN
China
Prior art keywords
user
activity
resource
event
current
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
CN202211062694.2A
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.)
Guangzhou Pinwei Software Co Ltd
Original Assignee
Guangzhou Pinwei Software 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 Guangzhou Pinwei Software Co Ltd filed Critical Guangzhou Pinwei Software Co Ltd
Priority to CN202211062694.2A priority Critical patent/CN115456665A/en
Publication of CN115456665A publication Critical patent/CN115456665A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0207Discounts or incentives, e.g. coupons or rebates
    • G06Q30/0212Chance discounts or incentives
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0207Discounts or incentives, e.g. coupons or rebates
    • G06Q30/0222During e-commerce, i.e. online transactions
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/02Marketing; Price estimation or determination; Fundraising
    • G06Q30/0207Discounts or incentives, e.g. coupons or rebates
    • G06Q30/0239Online discounts or incentives

Landscapes

  • Business, Economics & Management (AREA)
  • Accounting & Taxation (AREA)
  • Finance (AREA)
  • Engineering & Computer Science (AREA)
  • Development Economics (AREA)
  • Strategic Management (AREA)
  • Game Theory and Decision Science (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The application provides a resource allocation method, which comprises the steps that when a server receives an initialization signal sent by a user side, a user number of a currently-displayed activity of the user side and a currently-logged-in user are obtained; the server determines the number of times that the current user can participate based on the user number, the activity code and a pre-stored configuration information table; when the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is stored in an event queue in advance and is displayed in the user side according to a first preset rule; and the server collects the event hit by the current user, records user resource information into the remote dictionary service according to a second preset rule, and allocates resources for the user based on the remote dictionary service. The user participation is improved, and the storage performance is optimized by using the remote dictionary service; and a set of codes for resource allocation does not need to be developed for each active service, and the method has universality.

Description

Resource allocation method, system, electronic device and storage medium
Technical Field
The present invention relates to the field of software development technologies, and in particular, to a resource allocation method, a resource allocation system, an electronic device, and a storage medium.
Background
During spring holidays, UV (Uniform Visitor) of products and transactions all fall off the cliff, therefore, in order to improve the activity of users, merchants usually launch some lottery mini games, and common coupons such as inviting new users to participate in lotteries, card scraping or lucky turn-table lotteries are sent, so that the participation of users is increased to a certain extent, and the transaction amount of commodities is increased.
The prizes in the lottery activity pool are regarded as resources in the resource pool, the lottery mode can be regarded as a resource distribution mode, the user only needs to click the option displayed on the user interface, and the server distributes the resources to the user randomly or according to a certain rule. In these resource allocation modes, the user only needs to click a static button, and finally whether the resource allocation is completely determined by the background server, so that the user participation degree is low.
Therefore, a resource allocation method is needed to improve user engagement and solve the above technical problems in the prior art.
Disclosure of Invention
In order to solve the above-mentioned problems, it is a primary objective of the present invention to provide a resource allocation method, a system, an electronic device and a storage medium, so as to solve the above-mentioned problems.
In order to achieve the above object, a first aspect of the present invention provides a resource allocation method, which relates to a user side and a server side, and the method includes:
when a server receives an initialization signal sent by a user side, acquiring an activity code of a current display activity of the user side and a user number of a current login user;
the server determines the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table;
when the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
and the server collects the event hit by the current user, records user resource information into the remote dictionary service according to a second preset rule, and allocates resources to the user based on the remote dictionary service.
In some embodiments, the configuration information table includes an activity number table and an activity configuration table;
the activity number table is used for recording the participation condition of each activity, and comprises activity codes, participation time and corresponding user numbers;
the activity configuration table is used for recording configuration information of each activity, and the configuration information comprises activity codes, activity names, activity timeliness, participation types and resource rules.
In some embodiments, the server determines the number of times the current user can participate based on the user number, the activity code, and a pre-stored configuration information table, including:
querying the activity configuration table according to the activity code to determine participation types of the current display activity, wherein the participation types comprise a first type and a second type;
if the participation type is a first type, inquiring the activity number table according to the activity code to obtain the participation time of the current display activity on the current day so as to determine the participation times of the current display activity on the current day, and determining the participation times of the current user according to the first participation total times minus the participation times on the current day;
and if the participation type is a second type, inquiring the activity number table according to the user number and the activity code to determine the participation times of the user of the current login user in the current activity displaying scene, and determining the participation times of the current user according to the second participation total times minus the participation times of the user.
In some embodiments, the event is pre-stored in an event queue and displayed in the user side according to a first preset rule, including:
the server sets the number of false events, true events and termination events according to a preset proportion, and uniformly scatters the false events, the true events and the termination events into the event queue;
and the server circularly displays each event in the event queue at the user side according to the event sequence of the event queue.
In some embodiments, the collecting, by the server, the event hit by the current user and recording user resource information in the remote dictionary service according to a second preset rule includes:
if the event hit by the current user is a false event, recording is not carried out;
if the event hit by the current user is a true event, randomly selecting a resource from a resource pool based on a normal distribution algorithm, and recording the user number, the activity game serial number, the activity serial number and the corresponding resource information of the current user to a remote dictionary service;
and if the event hit by the current user is a termination event, terminating the active game and clearing the corresponding resource information stored in the remote dictionary service according to the user number, the active game serial number and the active number.
In some embodiments, the method further comprises: the resource pool comprises a plurality of resources, and the resource rule comprises game duration, event occurrence second maximum and minimum, event occurrence interval maximum and minimum, event occurrence number per second and resource occurrence probability of each resource;
the method further comprises the following steps:
calculating the maximum value of the occurrence frequency of each resource according to a first formula, calculating the minimum value of the occurrence frequency of the resource according to a second formula to determine the range of the occurrence frequency of each resource and calculate the range of the occurrence frequency of the total resource;
determining a probability range of each resource selection based on the resource occurrence frequency range and the total resource occurrence frequency range, and ensuring that the probability of randomly selecting each resource in a resource pool based on a normal algorithm is in the corresponding resource probability range;
the first formula is game duration/(minimum number of seconds of occurrence of events + maximum value of occurrence intervals of events) × number of occurrences of events per second × probability of occurrence of resources;
the second formula is game duration/(maximum number of seconds of occurrence of events + minimum value of occurrence interval of events) × number of occurrences of events per second × probability of occurrence of resources.
In some embodiments, said allocating resources for users based on said remote dictionary service comprises:
the server side reads corresponding resource information in the remote dictionary service according to the user number, the activity game serial number and the activity number;
and the server side allocates the resources meeting the allocation conditions to the current user based on verifying whether the resources meet the allocation conditions.
In a second aspect, the present application provides a resource allocation system, including:
the server is used for acquiring the activity code of the current display activity and the user number of the current login user when receiving the initialization signal;
the user side is used for sending out an initialization signal and displaying activities;
the server is also used for determining the number of times that the current user can participate based on the user number, the activity code and a pre-stored configuration information table;
the user side is used for starting an activity game and prompting the user to click an event until a termination condition is triggered when the participation frequency of the current user is greater than 0, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
the server is further used for collecting events hit by the current user, recording user resource information to the remote dictionary service according to a second preset rule, and distributing resources for the user based on the remote dictionary service.
In a third aspect, the present application provides an electronic device, comprising:
one or more processors;
and memory associated with the one or more processors for storing program instructions that, when read and executed by the one or more processors, perform operations comprising:
when a server receives an initialization signal sent by a user side, acquiring an activity code of a current display activity of the user side and a user number of a current login user;
the server determines the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table;
when the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
the server collects the events hit by the current user, records user resource information to a remote dictionary service according to a second preset rule, and distributes resources for the user based on the remote dictionary service.
In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, the computer program causing a computer to perform the following operations:
when receiving an initialization signal sent by a user side, a server side acquires an activity code of a current display activity of the user side and a user number of a current login user;
the server determines the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table;
when the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
and the server collects the event hit by the current user, records user resource information into the remote dictionary service according to a second preset rule, and allocates resources to the user based on the remote dictionary service.
The beneficial effect that this application realized does:
the application provides a resource allocation method, which comprises the steps that when a server receives an initialization signal sent by a user side, a user number of a currently displayed activity of the user side and a currently logged-in user are obtained; the server determines the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table; when the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule; the server collects the events hit by the current user, records user resource information to a remote dictionary service according to a second preset rule, and distributes resources for the user based on the remote dictionary service. The event list is displayed on the user interface in a circulating mode, and the user can acquire the corresponding resources only by clicking the dynamic events, so that the user participation degree is improved, the resources acquired by clicking each time are random, and the attraction degree to the user is improved; in addition, the application also provides the method for optimizing the storage performance by using the remote dictionary service; according to the method and the system, a set of codes for resource allocation does not need to be developed for each active service, the universality is realized, and the development period and the development workload are reduced.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, it is obvious that the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without inventive efforts, wherein:
fig. 1 is a flowchart of a first resource allocation method provided in an embodiment of the present application;
fig. 2 is a flowchart of a second resource allocation method provided in an embodiment of the present application;
FIG. 3 is a diagram of a resource allocation system architecture provided by an embodiment of the present application;
fig. 4 is a structural diagram of an electronic device provided in an embodiment of the present application.
Detailed Description
In order to make the purpose, technical solutions and advantages of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be understood that throughout the description and claims of this application, unless the context clearly requires otherwise, the words "comprise", "comprising", and the like, are to be construed in an inclusive sense as opposed to an exclusive or exhaustive sense; that is, what is meant is "including, but not limited to".
It will be further understood that the terms "first," "second," and the like are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. In addition, in the description of the present application, "a plurality" means two or more unless otherwise specified.
It should be noted that the terms "S1", "S2", etc. are used for descriptive purposes only, are not intended to refer specifically to an order or sequential meaning, nor are they intended to limit the present application, but are merely used for convenience in describing the method of the present application and are not to be construed as indicating the order of the steps. In addition, technical solutions between the embodiments may be combined with each other, but must be based on the realization of the technical solutions by a person skilled in the art, and when the technical solutions are contradictory to each other or cannot be realized, such a combination should not be considered to exist, and is not within the protection scope claimed in the present application.
Example one
The embodiment of the present application provides a resource allocation method, and specifically, a process of performing resource allocation by using the resource allocation method disclosed in the embodiment of the present application includes:
s1, setting a configuration information table.
Configuring a resource system at a server in advance, and storing configuration information in the server to record in a configuration information table form; the configuration information table can be divided into an activity order table and an activity configuration table in terms of contents.
The activity configuration table is used for recording configuration information of each activity, and the configuration information comprises activity codes, activity timeliness, participation types and resource rules. When a new activity is created, the staff configures the name of the activity, the activity time (i.e. activity aging), the participation type, the resource rule, etc. The participation types include N times a day (i.e., a first type) and N times a person (i.e., a second type), and the value of N can be set by a worker with confidence. The resource rules comprise a resource pool, game duration, the maximum value and the minimum value of the number of seconds of occurrence of the events, the maximum value and the minimum value of the occurrence intervals of the events, the number of occurrences of the events per second and the resource occurrence probability of each resource in the resource pool. Multiple activities may be defined in the resource system and to reduce storage stress on the server, the staff may delete an activity that has failed based on the age of the activity.
The activity number table is used for recording the participation condition of each activity, and comprises an activity code, participation time and a corresponding user number. And if one activity game is started, updating and recording the activity code of the activity game, the participation time of the activity game and the corresponding number of the user participating in the activity game in real time.
And S2, initializing the active game.
Firstly, in order to ensure the validity of an activity, when the activity is initialized, after a server receives an initialization signal generated by a user terminal, validity of the activity needs to be checked once, the occurrence probability of each resource in a resource rule in a configuration information table is inquired through an activity code, whether the sum of the occurrence probabilities of each resource arranged in a resource pool is equal to 100% or not is checked, if the sum of the occurrence probabilities of the resources is not equal to 100%, the activity is invalid, and at the moment, a worker reconfigures the occurrence probability of the resource. Optionally, the server may also query resource information in the resource pool in the resource rule according to the activity code, and return the resource information to the client, and the client displays the corresponding resource information to attract the user, where the returned resource information is not required to be displayed completely, and may be selectively displayed by the client.
Secondly, the server determines the number of times that the current user can participate based on the user number, the activity code and a pre-stored configuration information table. Specifically, an activity configuration table is obtained according to activity code query to determine the participation type of the current user side display activity; if the participation type is N times a day, inquiring an activity number table according to the activity code and inquiring the participation time of the current activity on the current day to determine the participation times of the current display activity on the current day, wherein the record corresponding to the activity code of the participation time on the current day condition is the participation times of the current day of the current display activity, and the participation times of the current user on the current day is equal to the total participation times minus the participation times on the current day (namely N-the participation times on the current day); if the participation type is one person for N times, querying records in which the user number and the activity code are both in accordance in the activity number table according to the user number and the activity code, wherein the records are corresponding to the number of times that the user of the current login user participates in the current activity displaying scene, and the number of times that the user participates in at the moment is equal to the total number of times that the user participates in the current time (namely the N-number of times that the user participates in the current time) according to the current time that the user can participate in the current time. When the number of times that the current user can participate is larger than 0, the server side returns an initialization completion signal to the user side, and the user side starts the activity game after receiving the initialization completion signal.
And S3, the user side starts the activity game, displays the event according to the event queue and the first preset rule, and prompts the user to click the event.
Specifically, the user end displays a prompt page before starting the active game to prompt the user to click an event within a specified game duration. The server sets the number of false events, true events and termination events according to a preset proportion, and uniformly scatters the false events, the true events and the termination events into an event queue; and then the server circularly displays each event in the event queue at the client according to the event sequence of the event queue and the number of events occurring in each second until a termination condition is triggered, wherein the preset proportion can be set by staff to adjust the difficulty of resource acquisition. The termination conditions comprise a hit termination event and the end of the game duration, any termination condition is triggered, and the active game is terminated.
And S4, recording resource information acquired by the user on the basis of the event hit by the user by the service end to a remote dictionary service.
Specifically, the method comprises the following steps. If the event hit by the current user is a false event, the event does not need to be recorded; if the event in the current user set is a true event, randomly selecting a resource in the resource pool based on a normal distribution algorithm and recording the user number, the activity game serial number, the activity code and the corresponding resource information of the current user to a remote dictionary service; if the event in the current user set is a termination event, the current active game is immediately terminated, and new resource information recorded by the user in the remote dictionary service is cleared according to the user number, the active game serial number and the active number of the current login user. It is worth noting that the application also provides a resource selection verification method, namely, a resource selection probability range corresponding to each resource is calculated according to the game duration, the maximum value and the minimum value of the seconds of occurrence of the false, the maximum value and the minimum value of the interval of occurrence of the event, the number of occurrence of the event per second and the resource occurrence probability of each resource which are set in the resource rule. Specifically, for each resource, according to the formula: the game duration/(the minimum value of the number of seconds of occurrence of the events + the maximum value of the occurrence intervals of the events) × the number of occurrences of the events per second and the occurrence probability of the resources are calculated to obtain the maximum value of the occurrence times of each resource; according to the formula: the game duration/(the maximum value of the occurrence time of the events + the minimum value of the occurrence intervals of the events) × the number of occurrences of the events per second and the occurrence probability of the resources are calculated to obtain the minimum value of the occurrence times of each resource; and respectively summing the maximum value and the minimum value of the occurrence times of each resource to determine the maximum value and the minimum value of the total occurrence times of the resource. Aiming at each resource, calculating the minimum value of the resource occurrence times/the maximum value of the total resource occurrence times to obtain the minimum value of the resource selection probability; and calculating the maximum value of the resource selection probability by calculating the maximum value of the resource occurrence times/the minimum value of the total resource occurrence times. When selecting resources in the resource pool, the probability of selecting the resources after circulating the event list once is ensured to be between the minimum value of the resource selection probability corresponding to the resources and the maximum value of the resource selection probability.
For example, in a game scene of grabbing rats to send commodities, one rat corresponds to one event, a rat holding a real prize corresponds to a real event, a rat holding an empty prize corresponds to a false event, a rat holding a bomb corresponds to a termination event, and rats holding different prizes appear at different pit positions randomly. If a lucky mouse holding a real prize is caught, a prize is randomly selected in a prize pool according to a normal distribution algorithm, the lucky mouse sends jitter and disappears, and then generates a text prompt of 'xx prize + 1', and at the moment, the winning record of the time, including a user number, an activity game serial number and an activity number, is recorded in a remote dictionary service. If the lucky mouse holding the fake prize is grabbed, the lucky mouse directly falls into the hole and no operation is performed. If the lucky mouse holding the bomb is grabbed, the game is ended, and the previously grabbed lucky mouse prizes are all invalid, namely recorded prize information is cleared. After the activity game is finished, the user can inquire the winning record in the remote dictionary service according to the user number, the activity game serial number and the activity code
And S5, the server verifies the recorded resource information and allocates the resources meeting the allocation conditions to the current user.
Specifically, the resources in the resource pool can be set as points, game opportunities, commodities, coupons, and the like; the distribution conditions comprise inventory conditions and pickup frequency conditions; if the resource inventory is insufficient, the server returns a first error prompt signal, and the user receives the first error prompt information and generates a first error prompt to prompt that the resource cannot be exchanged, such as ' cheerful in late you ' and the prize exchange is finished '; and if the user receiving times reach the upper limit, the server returns a second error prompt signal, and the user receives the second error prompt information and generates a second error prompt to prompt that the resource cannot be redeemed, if 'sorry, the redeeming times of the prize reach the upper limit'. According to the resource exchange method and device, time conditions can be added to the distribution conditions, exchange time is set for the resources, countdown is carried out when the event corresponding to the resources is hit, and if the resource exchange time is aged, the user is prompted that the current resources cannot be exchanged. Wherein the credits may be accumulated for redemption game opportunities. In addition, the method provided by the embodiment of the application further supports a fragment collection playing method, game fragments are added in the resource pool at the moment, and staff need to stipulate a fragment exchange rule when configuring a resource system, namely, a preset number and a preset type of fragments are collected and exchanged for a preset prize, for example, a god A, a god B and a god C are set to be required to exchange for a 1000-yuan cash red packet.
The resource method provided by the embodiment of the application is flexible in configuration and pre-loads resources, so that the running of the active game is more flow, the user experience is improved, the events are displayed through the event list, the resource selection corresponding to the true events in the events is further limited, and the normal distribution algorithm is met; the user needs to click the event which disappears continuously, so that the interactivity is increased; the method also optimizes the storage performance by using the remote dictionary service, and improves the loading speed; in addition, a set of codes for resource allocation does not need to be developed for each active service, the method and the system have universality, and the development period and the development workload are reduced.
Example two
Corresponding to the first embodiment, an embodiment of the present application further provides a resource allocation method, as shown in fig. 2, specifically as follows:
2100. when a server receives an initialization signal sent by a user side, acquiring an activity code of a current display activity of the user side and a user number of a current login user;
2200. the server determines the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table;
preferably, the determining, by the service end, the number of times that the current user can participate based on the user number, the activity code, and a pre-stored configuration information table includes:
2210. querying the activity configuration table according to the activity code to determine participation types of the current display activity, wherein the participation types comprise a first type and a second type;
2220. if the participation type is a first type, inquiring the activity number table according to the activity code to obtain the participation time of the current display activity on the current day so as to determine the participation times of the current display activity on the current day, and determining the participation times of the current user according to the first participation total times minus the participation times on the current day;
2230. and if the participation type is a second type, inquiring the activity number table according to the user number and the activity code to determine the participation times of the user of the current login user in the current activity displaying scene, and determining the participation times of the current user according to the second participation total times minus the participation times of the user.
The configuration information table comprises an activity number table and an activity configuration table;
the activity number table is used for recording the participation condition of each activity, and comprises activity codes, participation time and corresponding user numbers;
the activity configuration table is used for recording configuration information of each activity, and the configuration information comprises activity codes, activity names, activity timeliness, participation types and resource rules.
2300. When the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
preferably, the event is pre-stored in an event queue and displayed in the user side according to a first preset rule, and the method includes:
2310. the server sets the number of false events, true events and termination events according to a preset proportion, and uniformly scatters the false events, the true events and the termination events into the event queue;
2320. and the server side circularly displays each event in the event queue at the user side according to the event sequence of the event queue.
2400. The server collects the events hit by the current user, records user resource information to a remote dictionary service according to a second preset rule, and distributes resources for the user based on the remote dictionary service.
Preferably, the collecting, by the server, the event hit by the current user and recording the user resource information to the remote dictionary service according to a second preset rule includes:
2410. if the event hit by the current user is a false event, recording is not carried out;
2420. if the event hit by the current user is a true event, randomly selecting a resource from a resource pool based on a normal distribution algorithm, and recording the user number, the activity game serial number, the activity serial number and the corresponding resource information of the current user to a remote dictionary service;
preferably, the resource pool comprises a plurality of resources, and the resource rule comprises game duration, maximum and minimum occurrence seconds of events, maximum and minimum occurrence intervals of events, number of occurrences per second and resource occurrence probability of each resource;
the method further comprises the following steps:
2421. calculating the maximum value of the occurrence frequency of each resource according to a first formula, calculating the minimum value of the occurrence frequency of the resource according to a second formula to determine the range of the occurrence frequency of each resource and calculating the range of the occurrence frequency of the total resource;
2422. determining a probability range of each resource selection based on the resource occurrence frequency range and the total resource occurrence frequency range, and ensuring that the probability of randomly selecting each resource in a resource pool based on a normal algorithm is in the corresponding resource probability range;
the first formula is game duration/(minimum number of seconds of occurrence of events + maximum value of occurrence intervals of events) × number of occurrences of events per second × probability of occurrence of resources;
the second formula is game duration/(maximum number of seconds of occurrence of events + minimum value of occurrence interval of events) × number of occurrences of events per second × probability of occurrence of resources.
2430. And if the event hit by the current user is a termination event, terminating the active game and clearing the corresponding resource information stored in the remote dictionary service according to the user number, the active game serial number and the active number.
Preferably, the allocating resources for the user based on the remote dictionary service includes:
2440. the server reads corresponding resource information in the remote dictionary service according to the user number, the activity game serial number and the activity number;
2450. and the server side allocates the resources meeting the allocation conditions to the current user based on verifying whether the resources meet the allocation conditions.
EXAMPLE III
As shown in fig. 3, corresponding to the first embodiment and the second embodiment, an embodiment of the present application provides a resource allocation system, where the system includes:
the server 310 is configured to obtain an activity code of a current display activity and a user number of a current login user when receiving the initialization signal;
a user end 320 for sending out an initialization signal and displaying activities;
the server 310 is further configured to determine the number of times that a current user can participate based on the user number, the activity code, and a pre-stored configuration information table;
the user end 320 is used for starting an activity game and prompting a user to click an event until a termination condition is triggered when the number of times that the current user can participate is greater than 0, wherein the event is stored in an event queue in advance and is displayed in the user end according to a first preset rule;
the server 310 is further configured to collect an event hit by a current user, record user resource information to a remote dictionary service according to a second preset rule, and allocate resources to the user based on the remote dictionary service.
The configuration information table comprises an activity number table and an activity configuration table; the activity number table is used for recording the participation condition of each activity, and comprises activity codes, participation time and corresponding user numbers; the activity configuration table is used for recording configuration information of each activity, and the configuration information comprises activity codes, activity names, activity timeliness, participation types and resource rules.
In some embodiments, the server 310 is further configured to query the activity configuration table according to the activity code to determine an engagement type of the currently presented activity, where the engagement type includes a first type and a second type; if the participation type is a first type, the server 310 queries the activity number table according to the activity code to obtain the participation time of the current display activity on the current day so as to determine the participation times of the current display activity on the current day, and determines the participation times of the current user according to the first participation total time minus the participation times of the current day; if the participation type is a second type, the server 310 queries the activity number table according to the user number and the activity code to determine the number of times that the user of the current login user participates in the current activity displaying scene, and determines the number of times that the current user can participate according to the number of times that the user participates in the current activity displaying scene is subtracted by the second total number of times that the user participates in the current activity displaying scene.
In some embodiments, the server 310 is further configured to set the number of false events, true events, and termination events according to a preset ratio, and to uniformly break the false events, the true events, and the termination events into the event queue; the server 310 is further configured to cyclically display each event in the event queue at the user end according to the event sequence of the event queue.
In some embodiments, the server 310 is further configured to not record the event hit by the current user when the event is a false event; the server 310 is further configured to randomly select a resource from the resource pool based on a normal distribution algorithm and record a user number, an activity game serial number, an activity number and corresponding resource information of the current user to a remote dictionary service when the event hit by the current user is a true event; the server 310 is further configured to terminate the active game and clear the corresponding resource information stored in the remote dictionary service according to the user number, the active game serial number, and the active number when the event hit by the current user is a termination event.
In some embodiments, the resource pool comprises a plurality of resources, and the resource rules comprise game duration, maximum and minimum occurrence seconds of events, maximum and minimum occurrence intervals of events, number of occurrences per second, and resource occurrence probability of each resource; the server 310 is further configured to calculate a maximum value of occurrence frequency of each resource according to a first formula, calculate a minimum value of occurrence frequency of the resource according to a second formula to determine a range of occurrence frequency of each resource, and calculate a range of occurrence frequency of the total resource; the server 310 is further configured to determine a probability range for selecting each resource based on the resource occurrence frequency range and the total resource occurrence frequency range, and ensure that the probability of randomly selecting each resource in the resource pool based on a normal algorithm is within the corresponding resource probability range; the first formula is game duration/(minimum number of seconds of occurrence of events + maximum value of occurrence intervals of events) × number of occurrences of events per second × probability of occurrence of resources; the second formula is game duration/(maximum number of seconds of occurrence of events + minimum value of occurrence interval of events) × number of occurrences of events per second × probability of occurrence of resources.
In some embodiments, the server 310 is further configured to read corresponding resource information in the remote dictionary service according to the user number, the activity game serial number, and the activity number; the server 310 is further configured to allocate the resource meeting the allocation condition to the current user based on verifying whether the resource meets the allocation condition.
Example four
Corresponding to all the above embodiments, an embodiment of the present application provides an electronic device, including:
one or more processors; and memory associated with the one or more processors, the memory for storing program instructions that, when read and executed by the one or more processors, perform operations comprising:
when a server receives an initialization signal sent by a user side, acquiring an activity code of a current display activity of the user side and a user number of a current login user;
the server determines the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table;
when the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
the server collects the events hit by the current user, records user resource information to a remote dictionary service according to a second preset rule, and distributes resources for the user based on the remote dictionary service.
Fig. 4 schematically shows an architecture of an electronic device, which may specifically include a processor 410, a video display adapter 411, a disk drive 412, an input/output interface 413, a network interface 414, and a memory 420. The processor 410, the video display adapter 411, the disk drive 412, the input/output interface 413, the network interface 414, and the memory 420 may be communicatively connected by a bus 430.
The processor 410 may be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an Application Specific Integrated Circuit (ASIC), or one or more Integrated circuits, and is configured to execute related programs to implement the technical solution provided by the present Application.
The Memory 420 may be implemented in the form of a ROM (Read Only Memory), a RAM (Random Access Memory), a static storage device, a dynamic storage device, or the like. The memory 420 may store an operating system 421 for controlling execution of the electronic device 400, a Basic Input Output System (BIOS) 422 for controlling low-level operation of the electronic device 400. In addition, a web browser 423, a data storage management system 424, and an icon font processing system 425, and the like, may also be stored. The icon font processing system 425 may be an application program that implements the operations of the foregoing steps in this embodiment of the application. In summary, when the technical solution provided in the present application is implemented by software or firmware, the relevant program code is stored in the memory 420 and called to be executed by the processor 410.
The input/output interface 413 is used for connecting an input/output module to realize information input and output. The i/o module may be configured as a component in a device (not shown) or may be external to the device to provide a corresponding function. The input devices may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output devices may include a display, a speaker, a vibrator, an indicator light, etc.
The network interface 414 is used to connect a communication module (not shown in the figure) to implement communication interaction between the present device and other devices. The communication module can realize communication in a wired mode (for example, USB, network cable, etc.), and can also realize communication in a wireless mode (for example, mobile network, WIFI, bluetooth, etc.).
Bus 430 includes a path that transfers information between the various components of the device, such as processor 410, video display adapter 411, disk drive 412, input/output interface 413, network interface 414, and memory 420.
In addition, the electronic device 400 may also obtain information of specific pickup conditions from the virtual resource object pickup condition information database for performing condition judgment, and the like.
It should be noted that although the above-mentioned devices only show the processor 410, the video display adapter 411, the disk drive 412, the input/output interface 413, the network interface 414, the memory 420, the bus 430 and so on, in a specific implementation, the device may also include other components necessary for normal execution. In addition, it will be understood by those skilled in the art that the above-described apparatus may also include only the components necessary to implement the embodiments of the present application, and need not include all of the components shown in the figures.
EXAMPLE six
In response to all the above embodiments, an embodiment of the present application further provides a computer-readable storage medium, which stores a computer program, where the computer program causes a computer to operate as follows:
when a server receives an initialization signal sent by a user side, acquiring an activity code of a current display activity of the user side and a user number of a current login user;
the server determines the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table;
when the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
the server collects the events hit by the current user, records user resource information to a remote dictionary service according to a second preset rule, and distributes resources for the user based on the remote dictionary service.
From the above description of the embodiments, it is clear to those skilled in the art that the present application can be implemented by software plus necessary general hardware platform. Based on such understanding, the technical solutions of the present application or portions contributing to the prior art may be embodied in the form of a software product, which may be stored in a storage medium, such as a ROM/RAM, a magnetic disk, an optical disk, or the like, and includes several instructions for enabling a computer device (which may be a personal computer, a cloud service end, or a network device) to execute the method according to the embodiments or some portions of the embodiments of the present application.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, the system or system embodiments, which are substantially similar to the method embodiments, are described in a relatively simple manner, and reference may be made to some descriptions of the method embodiments for relevant points. The above-described system and system embodiments are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
The above description is only a preferred embodiment of the present application and should not be taken as limiting the present application, and any modifications, equivalents, improvements and the like that are made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (10)

1. A resource allocation method relates to a user side and a server side, and the method comprises the following steps:
when a server receives an initialization signal sent by a user side, acquiring an activity code of a current display activity of the user side and a user number of a current login user;
the server determines the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table;
when the number of times that the current user can participate is larger than 0, the user side starts an active game and prompts the user to click an event until a termination condition is triggered, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
the server collects the events hit by the current user, records user resource information to a remote dictionary service according to a second preset rule, and distributes resources for the user based on the remote dictionary service.
2. The method of claim 1,
the configuration information table comprises an activity number table and an activity configuration table;
the activity number table is used for recording the participation condition of each activity, and comprises an activity code, participation time and a corresponding user number;
the activity configuration table is used for recording configuration information of each activity, and the configuration information comprises activity codes, activity names, activity timeliness, participation types and resource rules.
3. The method of claim 2, wherein the server determines the number of times the current user can participate based on the user number, the activity code, and a pre-stored configuration information table, and comprises:
querying the activity configuration table according to the activity code to determine participation types of the current display activity, wherein the participation types comprise a first type and a second type;
if the participation type is a first type, inquiring the activity number table according to the activity code to obtain the participation time of the current display activity on the current day so as to determine the participation times of the current display activity on the current day, and determining the participation times of the current user according to the first participation total times minus the participation times on the current day;
if the participation type is a second type, inquiring the activity times table according to the user number and the activity code to determine the user participation times of the current login user in the current activity displaying scene, and determining the participation times of the current user according to the second participation total times minus the user participation times.
4. The method according to claim 3, wherein the event is pre-stored in an event queue and is displayed in the user side according to a first preset rule, and the method comprises:
the server sets the number of false events, true events and termination events according to a preset proportion, and uniformly scatters the false events, the true events and the termination events into the event queue;
and the server side circularly displays each event in the event queue at the user side according to the event sequence of the event queue.
5. The method according to claim 4, wherein the server collects the event hit by the current user and records the user resource information to the remote dictionary service according to a second predetermined rule, comprising:
if the event hit by the current user is a false event, recording is not carried out;
if the event hit by the current user is a true event, randomly selecting a resource from the resource pool based on a normal distribution algorithm, and recording the user number, the activity game serial number, the activity number and the corresponding resource information of the current user to a remote dictionary service;
and if the event hit by the current user is a termination event, terminating the active game and clearing the corresponding resource information stored in the remote dictionary service according to the user number, the active game serial number and the active number.
6. The method of claim 5, wherein the resource pool comprises a plurality of resources, and the resource rules comprise game duration, maximum and minimum number of seconds of occurrence of events, maximum and minimum number of intervals of occurrence of events, number of occurrences of events per second, and probability of occurrence of resources per resource;
the method further comprises the following steps:
calculating the maximum value of the occurrence frequency of each resource according to a first formula, calculating the minimum value of the occurrence frequency of the resource according to a second formula to determine the range of the occurrence frequency of each resource and calculate the range of the occurrence frequency of the total resource;
determining a probability range of each resource selection based on the resource occurrence frequency range and the total resource occurrence frequency range, and ensuring that the probability of randomly selecting each resource in a resource pool based on a normal algorithm is in the corresponding resource probability range;
the first formula is game duration/(minimum number of seconds of occurrence of events + maximum value of occurrence intervals of events) × number of occurrences of events per second × probability of occurrence of resources;
the second formula is game duration/(maximum number of seconds of occurrence of events + minimum value of occurrence interval of events) × number of occurrences of events per second × probability of occurrence of resources.
7. The method of claim 6, wherein allocating resources for a user based on the remote dictionary service comprises:
the server reads corresponding resource information in the remote dictionary service according to the user number, the activity game serial number and the activity number;
and the server side allocates the resources meeting the allocation conditions to the current user based on verifying whether the resources meet the allocation conditions.
8. A resource allocation system, the system comprising:
the server is used for acquiring the activity code of the current display activity and the user number of the current login user when the initialization signal is received;
the user side is used for sending out an initialization signal and displaying activities;
the server is also used for determining the participation times of the current user based on the user number, the activity code and a pre-stored configuration information table;
the user side is used for starting an activity game and prompting the user to click an event until a termination condition is triggered when the participation frequency of the current user is greater than 0, wherein the event is pre-stored in an event queue and displayed in the user side according to a first preset rule;
the server is further used for collecting events hit by the current user, recording user resource information to the remote dictionary service according to a second preset rule, and distributing resources for the user based on the remote dictionary service.
9. An electronic device, characterized in that the electronic device comprises:
one or more processors;
and memory associated with the one or more processors, the memory for storing program instructions that, when read and executed by the one or more processors, perform the method of any of claims 1-7.
10. A computer-readable storage medium, characterized in that it stores a computer program which causes a computer to execute the method of any one of claims 1-7.
CN202211062694.2A 2022-08-31 2022-08-31 Resource allocation method, system, electronic device and storage medium Pending CN115456665A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211062694.2A CN115456665A (en) 2022-08-31 2022-08-31 Resource allocation method, system, electronic device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211062694.2A CN115456665A (en) 2022-08-31 2022-08-31 Resource allocation method, system, electronic device and storage medium

Publications (1)

Publication Number Publication Date
CN115456665A true CN115456665A (en) 2022-12-09

Family

ID=84299873

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211062694.2A Pending CN115456665A (en) 2022-08-31 2022-08-31 Resource allocation method, system, electronic device and storage medium

Country Status (1)

Country Link
CN (1) CN115456665A (en)

Similar Documents

Publication Publication Date Title
RU2434295C2 (en) Advertisement method and system, advertisement control server and mobile device
US8177632B2 (en) Information flow control for gaming machines requiring server support
US9272205B2 (en) Non-transitory computer-readable storage medium storing game program, and game system
KR101487842B1 (en) Method and System of On-Line Challenge Game, and Method for Calculating Advertisement Cost based in On-Line Challenge Game
US20120252558A1 (en) Method for distributing promotional offers using an electronic game application
US20070077993A1 (en) Method and apparatus for collecting user game play data and crediting users in a gaming environment
CN104379225A (en) Game control device, game control method, program, recording medium and game system
US8167725B1 (en) System and method for using a game to interact with television programs
KR20080056257A (en) Method and apparatus for monitoring user game-playing behavior and reporting game play data in a gaming environment
CN113262494A (en) Task processing method and device in game and electronic equipment
US20150352447A1 (en) Information processing device
KR101188125B1 (en) Method and apparatus for lottery of item in online game
CN117379789A (en) Interaction control method and device in game, electronic equipment and storage medium
CN115456665A (en) Resource allocation method, system, electronic device and storage medium
CN114862426A (en) Customer service recommendation method, device, equipment and medium
JP5526295B1 (en) GAME PROGRAM AND INFORMATION PROCESSING DEVICE
JP5499208B1 (en) Program and information processing apparatus
AU2009201986A1 (en) Gaming method and gaming system
CN113769411B (en) Game task distribution method and device, storage medium and electronic device
KR20060105970A (en) Method and system for providing reward in on-line game
CN110852806A (en) Data processing method and device, storage medium and electronic equipment
JP2019141618A (en) Information processor, game program and information processing method
JP7307912B2 (en) SERVER DEVICE CONTROL METHOD, SERVER DEVICE, AND PROGRAM
KR101264629B1 (en) Method and server for providing service of using item
KR20010067847A (en) Method for matching game using game client having card reader in game center

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