Page 1 of 1

[ZScript] Lazy Points: basic scoring system

PostPosted: Wed Dec 04, 2019 2:00 pm
by m8f

Playable Demo

Introducing Lazy Points, the most basic scoring system.
Requires GZDoom 4.3.3 or newer.

- uses standard player score variable, so it's easy to read and write score outside from Lazy Points;
- absolutely no impact on gameplay whatsoever;
- shows other players' scores in multiplayer;
- top 10 map scores that are saved between games* (accessed by assigned key).

1. Damage: players get points for the amount of damage they inflict on monsters.
2. Kills: players get points for 10% of killed monsters;
3. Chain kills: 10 points for each monster killed in 3 seconds after previous kill.
4. Secrets: finding a secret gives 250 points.
5. Map items: collecting an item that counts for item counts gives 5 points.
6. Keys: collectiog a key gives 250 points.
7. Barrels: destroying an explosive barrel gives 5 points.
8. Player with 50% and more health gets kill points (with chain kill bonus) multiplied by 1.5, with 100% and more - by 2.

I'm open to suggestions, but cannot promise they will be implemented, because this is all I need for my other project.

Re: [ZScript] Scoring

PostPosted: Wed Dec 04, 2019 3:49 pm
by Xim
Hey, this is pretty neat! I know it doesn't directly have an impact on game-play but it does encourage me to switch up my play style. Only played a couple of levels but it's pretty cool.

One minor suggestion, if it's possible or if you'd even want to do it. What if your score got reset after using cheat codes? Kind of like in Wolfenstein 3D. It might be more effort than it's worth but it might be a nice touch, or pointless I dunno. :P

I could see a lot of potential in other modders using this for RPG-style mods, or mods that simply give rewards when certain scores are reached. Not sure what I could personally do with it, but there's some cool ideas out there.

Re: [ZScript] Scoring

PostPosted: Thu Dec 05, 2019 12:27 am
by mrtaterz
Yes. Thank you so much for making this!

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Sat Dec 07, 2019 8:06 am
by m8f
v0.2 is out. Playable demo.


- renamed from Zcore to Lazy Points;
- use original Big Font instead of replacement Big Font, because there are Big Fonts without numbers;
- no more showing on titlemaps;
- fixed floating point truncation warnings;
- made timer animation smooth.

New stuff:
- scoring for keys;
- health multiplier bonus;
- displaying other players' scores in multiplayer.

Multiplayer is checked, but not thoroughly tested. It would be great if someone played in multiplayer with Lazy Points and reported if it desyncs or not.

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Tue Jan 07, 2020 8:39 am
by m8f
Lazy Points updated to 0.3. Changes:
- fixed scoring on telefragging;
- added top map scores.

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Tue Jan 14, 2020 11:48 pm
by Carrotear
been getting this error on LZDoom

Script error, "lazy-points-0.3.pk3:zscript/zc_optionmenuscoreitem.zs" line 65:
Call to unknown function 'drawValue'

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Wed Jan 15, 2020 10:35 am
by amdcrash
i'm getting a different error on gzdoom 4.2.4

Code: Select allExpand view
Script error, "lazy-points-0.2.pk3:cvarinfo.txt" line 1:
Unknown cvar attribute 'nosave'

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Wed Jan 15, 2020 10:39 am
by m8f
Oh, I forgot to add version dependency. This needs GZDoom v4.3.2.

LZDoom lags behind in features a bit, so LZDoom users have to wait until drfrag updates it.

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Wed Jan 15, 2020 12:19 pm
by Carrotear
No worries then. I'll use GZDoom in the meantime then.

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Wed Jan 15, 2020 7:26 pm
by m8f
Important notice: Lazy Points data storage system is stable only in devbuilds currently. This is due to an oversight that was found only after GZDoom 4.3.2 release. The problem is handling large amounts of data. You aren't likely to reach data limits, but if you will, GZDoom will crash or freeze.

-To be clear: the oversight is mine, not GZDoom devs'.

Requires GZDoom 4.3.3 or newer.

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Sat Jul 25, 2020 4:13 pm
by -Rei-Anon
will you have more options for the score mod?

ie: increase the timer for the chain from 3 seconds to 7 seconds ect.
Have a monster have a score amount something like zombieman with 10 points and cyberdemon being 150 points
remove the 500 points cap and go beyond
have an option to choose how the combo multiplier would be (health style combo (100hp = X 2.0) vs points style combo (100 points = X 2.0, 500 points = X 5.0))

Overall I love this combo mod keep up the amazing work.

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Sat Jul 25, 2020 9:05 pm
by m8f
I won't be working on this mod unless a major bug is found.

However, if someone wants to modify the mod, here are some pointers:
  1. Timer duration can be easily changed in zscript/zc_Parameters.zs, BONUS_COUNTDOWN constant.
  2. Monster score calculation is in zscript/zc_Counter.zs, calculatePointsFor(Actor died) function. Right now the scores is based on enemy's base health. It can be changed to look like this:
  3. Max timer bonus is in zscript/zc_TimerBonus.zs, MAX_TIMER_BONUS constant.
  4. This again requires modification of calculatePointsFor(Actor died) function in zscript/zc_Counter.zs. Look for _timerBonus and _healthBonus.


Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Sun Oct 04, 2020 8:20 pm
by Neophyte_Ronin

Doom players live to ride on the edge of danger. The Multiplier should increase as your health depreciates. Taking a medicinal item should also earn points on the side, but the trick is when and where you recover and how long you manage to ride that wave. It gives score-obsessed completionists something of a personal dilemma: do they go for broke with low health and pray the hit-scanners get clipped first, or do they retake some health just to make sure they survive with what little score they have?

Re: [ZScript] Lazy Points: basic scoring system

PostPosted: Mon Oct 05, 2020 7:31 am
by m8f
Lazy Points is a script library first and a playable demo second. Anybody can take it as a base and implement any score system they desire.

Looking forward to Neophyte_Ronin's Points Mod!