Thoughts in new reward/medal system?
Posted: Tue Jun 19, 2012 5:44 am
I have quickly thought up of a nice customizable reward system.
Formatting of this post be changed if needed.
I would like some thoughts on this before I suggest it on the tracker.
- My idea on how it will work
- Template:
Reward Number or Identifier
{
type: RWD_KILL / RWD_FIRSTKILL / RWD_DEATH / RWD_ACCURACY / RWD_PICKUP / RWD_DROP / RWD_CAPTURE / RWD_DENIED / RWD_ASSIST / RWD_DEFEND / RWD_WIN / RWD_LOSE / RWD_CUSTOM
spree: True/False, Sprees are for things that happen in a row. Usually without deaths. Usable with all types. RWD_WIN and RWD_LOSE aren't affected by deaths but their opposite.
name: Used for easy formatting. Also good for printing to console without having the broadcast message set. "%o gained %n!"
amount: Amount required to achieve. Not for Accuracy and similar types.
threshold: Threshold of how often or how many is required to earn this reward. RWD_ACCURACY will instead count from the center of the hitbox out in units, not percentage.
theiritem: Used so either your ally (For defensive/assistance types) or enemy must have an Inventory object. Multiple objects separated with commas, group objects in brackets.
youritem: Used so you require an Inventory object. Multiple objects separated with commas, group objects in brackets.
broadcast: True/False
message: Message shown to you.
broadcastmessage: Message shown to other players. Best not used with RWD_LOSE.
sound: Sound played to you.
broadcastsound: Sound broadcasted to other players. Best not used with RWD_LOSE.
icon: The icon to show above someone's head.
reward: Can be used to reward points or an inventory object, or take them or even execute an ACS script on the player. Points: points($1), Give/Take: give($1) / take($1), ACS: execute($1). Separate multiple definitions with commas.
punishment: Same as above but affects the victim, not the rewarded.
rewardglobal: True/False, Affects all team players, or execute an ACS script globally.
punishglobal: True/False, Same as above but also used for all enemy players in non team games.
gametype: To be used in which hard coded gametypes. Separated with a comma for each.
spawn: Spawns the defined actors at the player. Each separated by commas. Heights and offsets can be used in brackets. otherwise spawn at default height. Ie. (Actor,X,Y,Z,Angle,Pitch,Absolute/Relative(0/1 thing))
}
RWD_KILL: Multiple kills in a short amount of time.
RWD_FIRSTKILL: First Kill of the match/round.
RWD_DEATH: When you die. Reward and Punishment identifiers are reversed when this type is used.
RWD_ACCURACY: Accuracy to your firing.
RWD_PICKUP: Pickup an item, get a reward.
RWD_CAPTURE: Capture the flag or skull.
RWD_DENIED: Die when close to a capture or just lose the match.
RWD_ASSIST: Assist the flag, skull or stone carrier. Could also be used with the "item" parameter.
RWD_DEFEND: Kill the enemy flag, skull or stone carrier. Or kill your ally flag, skull or stone carrier's attaker. Could also be used with the "item" parameter.
RWD_WIN: When you win the round or match. Best just for the announcement that you won the match.
RWD_LOSE: Same as above but when you lose.
RWD_CUSTOM: Used for when calling via ACS or Decorate. Local inventory items, requirements and messages will be applied to the caller or the defined TID.
RWD_CAPTURE, RWD_DENIED, RWD_ASSIST and RWD_DEFEND would only mainly apply to CTF, Skulltag and Posession. RWD_ASSIST for Posession could apply for Team Posession.
RWD_ASSIST and RWD_DEFEND could also probably be applied to Team Deathmatch.
The "Random" function may also be useful with the "reward" and "punishment" parameters.
%n = Name of the reward, defined in the "Name" parameter. If not defined, use the Type's default.
%o = The one who got the reward.
%k = The victim.
%r = The points or inventory item they got/taken.
%a = The amount of points or inventory items they got/taken.
%p = The points or inventory item the victim got/taken.
%c = The amount of points or inventory items the victim got/taken.
%w = The weapon used.
cl_rewards = Replaces cl_medals. If False, will disable all sounds, icons and messages, but not any other identifiers.
cl_rewardbroadcast = If False, disables receiving of all broadcast messages and sounds.
sv_forcerewards = If True, indirectly forces cl_rewards true.
sv_forcerewardbroadcast = If True, indirectly forces cl_rewardbroadcast true.
The force svars can be useful in some mods that perhaps should use it, such as WDI.
This could also be allowed client side, as in loading via autoexec.cfg or your skins directory. This can be done by disabling all inventory checks and broadcasting to other players.
This makes it so it's just extra sounds and messages shown to the client. Should still pick up on other player sprees/deaths on the client because the server sends the kill/death data anyway.
- A stupid Idea
- Also stupid idea, but what if this also applied to monsters?
"A Cyberdemon is on a Killing Spree"
Or
"Player is on a Rampage" after killing a few monsters, but have the spree thresholds perhaps 2-10x bigger than defined by default.
Or
"A Zombieman defended a Shotgunguy from Player"
I would like some thoughts on this before I suggest it on the tracker.