I'm pretty sure half the point of this mod is creating a more solid base for developers to work with.GAA1992 wrote:small question: Are you going to allow modders to make forks out of your version of BD? Giving proper credits, obviously. =p
BDLite [V1.2 RELEASED - 2019-12-20]
Forum rules
The Projects forums are only for projects. If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.
Got a cool project idea but nothing else? Put it in the project ideas thread instead!
Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.
Please read the full rules for more details.
The Projects forums are only for projects. If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.
Got a cool project idea but nothing else? Put it in the project ideas thread instead!
Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.
Please read the full rules for more details.
-
- Posts: 7402
- Joined: Fri Oct 22, 2004 9:22 am
- Graphics Processor: nVidia with Vulkan support
- Location: MAP33
Re: BDLite - a slimmed-down effects mod [2018-10-08]
-
- Posts: 2816
- Joined: Thu Jun 04, 2015 9:07 pm
- Preferred Pronouns: He/Him
- Location: Killing spiders.
Re: BDLite - a slimmed-down effects mod [2018-10-08]
Went through my head but you never know. I don't want DavidN to see me as some kind of freeloader.
-
- Posts: 7402
- Joined: Fri Oct 22, 2004 9:22 am
- Graphics Processor: nVidia with Vulkan support
- Location: MAP33
Re: BDLite - a slimmed-down effects mod [2018-10-08]
I'm pretty sure there was something about serving as a better base in the OP at first, but it looks like things got shortened.
I'm sure David can correct me if necessary, of course.
I'm sure David can correct me if necessary, of course.
-
- Posts: 116
- Joined: Sun Oct 02, 2016 11:37 am
- Graphics Processor: Intel (Modern GZDoom)
Re: BDLite - a slimmed-down effects mod [2018-10-08]
You beautiful person! I want to hug you! Brutal DOOM got me interested in the modern DOOM scene and I didn't just stick to BD; many aspects of it were genuinely refreshing, such as the starting rifle being a practical gun at all levels rather than something immediately forgotten, but the terrible performance, bloat and over-inflated 'edge' just wasn't necessary. I switched to using v20 Black Edition which reigned it in a bit, but I think you're going to solve all my complaints and make BD worth playing again!
-
- Vintage GZDoom Developer
- Posts: 3150
- Joined: Fri Apr 23, 2004 3:51 am
- Location: Spain
Re: BDLite - a slimmed-down effects mod [2018-10-08]
As you probably know i'm the author of that unofficial v20c patch to fix bugs. I wonder if this is based on v21.
I tried the latest v21 a few days ago and the same old game breaking bugs i reported are still there (was struck by the dissapearing weapon unrecoverable bug). I've found that now balance is completely broken and it's much harder than before compared to previous betas, extremely hard and unplayable i'd say.
However there's new cool stuff to watch there.
I tried the latest v21 a few days ago and the same old game breaking bugs i reported are still there (was struck by the dissapearing weapon unrecoverable bug). I've found that now balance is completely broken and it's much harder than before compared to previous betas, extremely hard and unplayable i'd say.
However there's new cool stuff to watch there.
-
-
- Posts: 266
- Joined: Mon Dec 28, 2015 6:22 pm
Re: BDLite - a slimmed-down effects mod [2018-10-08]
I can't really remember which version BDLite is based on because I started it so long ago (I just started making a serious push at it over the last few weeks) - it's either 19 or 20 somewhere And yes, I definitely want to make this open to other people to extend and to build on - one of my update posts will be about how I'm building my own project on it, including where new monsters/weapons extend from and my build pipeline
For optimization, I was working on the theory that if my laptop can handle it then anything can, but I can definitely see that some removing of the many, many actors created over time would be a benefit. I'll have to look at what the best way to implement that is.
For optimization, I was working on the theory that if my laptop can handle it then anything can, but I can definitely see that some removing of the many, many actors created over time would be a benefit. I'll have to look at what the best way to implement that is.
-
-
- Posts: 266
- Joined: Mon Dec 28, 2015 6:22 pm
Re: BDLite - a slimmed-down effects mod [2018-10-10]
Okay, new snapshot posted with the file size trimmed down another 2MB It's now just under half the size of the full V20 PK3. It has the list of fixes on the Trello board - all the monsters are now there (not sure I'll bother with the nazis) and various other annoyances have been fixed.
Incidentally the gigantic tree in the first post looks like this now, though there's still some way to go:
Incidentally the gigantic tree in the first post looks like this now, though there's still some way to go:
-
- Posts: 3
- Joined: Tue Jun 26, 2018 1:35 pm
Re: BDLite - a slimmed-down effects mod [2018-10-10]
This is really, really cool and I'm enjoying it even if it's unfinished. I noticed the following glitches:
- The Death Camera is always on even if I have it turned off on my config.
- The pinkies are extra fast on difficulty levels other than Nightmare. Maybe it's on purpose, but I didn't notice it on the previous snapshots.
- The shotgun reloading animation sort of shakes when you are walking through stairs.
- This decoration flickers constantly. Can be found on TNT MAP02 starting room https://i.imgur.com/ciRA2EK.jpg
- The Death Camera is always on even if I have it turned off on my config.
- The pinkies are extra fast on difficulty levels other than Nightmare. Maybe it's on purpose, but I didn't notice it on the previous snapshots.
- The shotgun reloading animation sort of shakes when you are walking through stairs.
- This decoration flickers constantly. Can be found on TNT MAP02 starting room https://i.imgur.com/ciRA2EK.jpg
-
- Posts: 116
- Joined: Sun Oct 02, 2016 11:37 am
- Graphics Processor: Intel (Modern GZDoom)
Re: BDLite - a slimmed-down effects mod [2018-10-10]
Tried this with D64D2 and aside the super-fast pinkies as noted before, I noticed that the enemies hidden in the walls (for later teleportation in) were taking actual shots at me, even though they shouldn't have any line-of-sight. Screenshot here, so you can see where they're hidden above/below the starting point on the map.
Great work you're doing, this plays *so* well. I had forgotten how much fun BD can be; I had to give it up because of performance problems. Your version is significantly faster already, thank you.
Great work you're doing, this plays *so* well. I had forgotten how much fun BD can be; I had to give it up because of performance problems. Your version is significantly faster already, thank you.
You do not have the required permissions to view the files attached to this post.
-
-
- Posts: 266
- Joined: Mon Dec 28, 2015 6:22 pm
Re: BDLite - a slimmed-down effects mod [2018-10-10]
Thanks for bringing that up! I see the problem - this is actually the fault of a feature in the lowest-tier enemies that I thought was worth keeping around but didn't quite recreate properly. When the zombieman or sergeant are awake and are close to you, they take a few steps back, with a chance of going to their Missile label afterwards. The jump to Missile gets called whether the actor can actually see the player or not - the solution is to put a check in just after the Missile label for line-of-sight. I've lined that up to go out with the next snapshot
I've been thinking about the death camera and what a pain it was going to be to fix it (it used to really bother me that it swung through walls but I've sort of got used to it now) - it never really occurred to me before that I could just remove it and write my own slightly enhanced player deaths. I think that's what I'll do, unless anyone's particularly fond of the third person deaths.
I've been thinking about the death camera and what a pain it was going to be to fix it (it used to really bother me that it swung through walls but I've sort of got used to it now) - it never really occurred to me before that I could just remove it and write my own slightly enhanced player deaths. I think that's what I'll do, unless anyone's particularly fond of the third person deaths.
-
-
- Posts: 266
- Joined: Mon Dec 28, 2015 6:22 pm
Re: BDLite - a slimmed-down effects mod [2018-10-10]
New snapshot again, with some more things fixed and a bit more slimming down. I think I've removed the redundant special effects and just need to rewrite the remaining ones into a somewhat sane hierarchy, which is still a daunting task. Some time was spent on making sure all the necessary sprites existed - time for another big post!
Sprite tidying
One of the main reasons that Brutal Doom is so confusing, of course, is just how much of it there is. V20b contains 7,768 files in all, across all the added scripts, graphics and definitions. At the time of writing, I've pared down and consolidated things enough to get it down to 4,107. In both cases, the vast majority of the files are sprites, and they're in a random mixture of PNG and Doom format graphics which may or may not have file extensions.
ZDoom's state definition parsing is very permissive about the sprites that you define for each state, which can be more of a curse than a blessing - the game will still run if you're missing a sprite here and there, but it can make it very difficult to detect errors. In a project where you're just using a couple of custom actors, it's easy enough to browse through the code and match the frames mentioned in the state definitions with files in your sprites folder, but this is on another level entirely - I wrote a script to help me find references to sprites that didn't exist, and sprite files that were never referenced.
The PHP script takes two command line arguments - a DECORATE folder to examine (ZScript works equally well) and a SPRITES folder to compare it to. It recurses through the sprites folder adding the available sprites and frame letters to an array, then reads each file in the Decorate folder and does the same thing to anything that looks like a reference to a sprite.
Do you know how regex was invented? A software architect fell asleep on his keyboard during a long night, rolled his head around a bit, woke up and said "Yes! That's exactly what a language should look like". I can barely ever actually read the ones I've written, and have to rebuild them from scratch each time to refresh my memory. Nevertheless, I can vaguely tell you that the first one of these looks for lines in DECORATE that look like references to sprites - four alphanumeric characters, some space, a string of letters (or the special characters used by the Archvile), some more space and then a number.
The duration of a state can also be declared as a random range, so the "r" at the end of the pattern is a bit of a hacky way to account for this.
Similarly, the second regex searches for any file that conforms to the Doom sprite naming scheme - four alphanumeric characters, a letter or one of the other special frame characters, and then a number representing direction (followed by anything else, for files that act as more than one direction).
After gathering both of these lists, the script compares the two and spits out an error for every time a frame is mentioned in one place but not in another. You can then use that list to hunt down any sprites that are unused, or to identify places where an expected sprite doesn't exist. (After removing classes that weren't useful for BDLite, the list of unused sprites was at about 700 before I went in on a pruning mission.)
I don't think this script is perfect yet as I've bound to have forgotten some edge cases, and there are other ways to declare a sprite is needed other than in state declarations (for example, the Player.CrouchSprite). But it can be used to identify potential bloat or missing sprites that would take several months to find by looking through the state definitions manually. I run this periodically as I go through the code, and it's very satisfying to see the final size of the PK3 plummeting.
Sprite tidying
One of the main reasons that Brutal Doom is so confusing, of course, is just how much of it there is. V20b contains 7,768 files in all, across all the added scripts, graphics and definitions. At the time of writing, I've pared down and consolidated things enough to get it down to 4,107. In both cases, the vast majority of the files are sprites, and they're in a random mixture of PNG and Doom format graphics which may or may not have file extensions.
ZDoom's state definition parsing is very permissive about the sprites that you define for each state, which can be more of a curse than a blessing - the game will still run if you're missing a sprite here and there, but it can make it very difficult to detect errors. In a project where you're just using a couple of custom actors, it's easy enough to browse through the code and match the frames mentioned in the state definitions with files in your sprites folder, but this is on another level entirely - I wrote a script to help me find references to sprites that didn't exist, and sprite files that were never referenced.
Code: Select all
<?php
class SpriteUseDetector {
//Including the "r" in the last section is a hacky allowance for when a state lasts for a random() amount of time
var $state_regex = '/^\h*[A-Za-z0-9]{4}\h+[a-zA-\]"]*\h+[-]?[0-9rR]+/m';
var $sprite_file_regex = '/^[A-Za-z0-9]{4}[a-zA-\]\^]{1}[0-1]/';
var $decorate_sprites_mentioned = [];
var $sprites_available = [];
var $sprite_errors = 0;
var $sprites_unused = 0;
var $zero_length_frames = [];
public function run($decorate_folder, $sprite_folder) {
$folders_to_run = explode(",", $decorate_folder);
while(count($folders_to_run) > 0) {
$decorate_folder = array_shift($folders_to_run);
echo ("Examining DECORATE folder " . $decorate_folder . PHP_EOL);
//Get the files in the folder
$files = scandir($decorate_folder);
foreach ($files as $key => $value) {
if (!in_array($value,array(".",".."))) {
$full_file_name = $decorate_folder . DIRECTORY_SEPARATOR . $value;
if (is_dir($full_file_name)) {
//Add to the list
$folders_to_run[] = $full_file_name;
}
else {
$file_string = file_get_contents($full_file_name);
$this->examine_decorate_file($file_string);
}
}
}
}
//Now run a similar search on the sprite folder, looking for filenames.
$folders_to_run = explode(",", $sprite_folder);
while(count($folders_to_run) > 0) {
$sprite_folder = array_shift($folders_to_run);
echo ("Examining sprite folder " . $sprite_folder . PHP_EOL);
//Get the files in the folder
$files = scandir($sprite_folder);
foreach ($files as $key => $value) {
if (!in_array($value,array(".",".."))) {
$full_file_name = $sprite_folder . DIRECTORY_SEPARATOR . $value;
if (is_dir($full_file_name)) {
//Add to the list
$folders_to_run[] = $full_file_name;
echo ("Adding " . $full_file_name . PHP_EOL);
}
else {
//This might be a sprite file, if we have a match on this.
$num_results = preg_match_all($this->sprite_file_regex, $value);
if ($num_results > 0) {
$sprite_name = strtoupper(substr($value, 0, 4));
$sprite_frame = strtoupper(substr($value, 4, 1));
$this->sprites_available[$sprite_name][$sprite_frame] = true;
//Check for a double rotation
$sprite_frame_2 = strtoupper(substr($value, 6, 1));
if ($sprite_frame_2 != '.' && !empty($sprite_frame_2)) {
$this->sprites_available[$sprite_name][$sprite_frame_2] = true;
}
}
}
}
}
}
//We now have all the DECORATE mentions and sprites. Check to see if any of the DECORATE refers to a missing sprite.
foreach ($this->decorate_sprites_mentioned as $dec_sprite_name => $dec_sprite_frames) {
if (!isset($this->sprites_available[$dec_sprite_name])) {
echo ("!!! $dec_sprite_name (" . count($dec_sprite_frames) . " frames) not found among the sprite files!" . PHP_EOL);
$this->sprite_errors++;
continue;
}
foreach ($dec_sprite_frames as $dec_sprite_frame => $blah) {
if (!isset($this->sprites_available[$dec_sprite_name][$dec_sprite_frame])) {
echo ("!!! File for $dec_sprite_name frame $dec_sprite_frame was not found!" . PHP_EOL);
$this->sprite_errors++;
}
}
}
echo ("Sprites missing: " . $this->sprite_errors . PHP_EOL);
//And check to see if any sprites were never mentioned in the DECORATE.
foreach ($this->sprites_available as $sprite_name => $sprite_frames) {
if (!isset($this->decorate_sprites_mentioned[$sprite_name])) {
echo ("??? $sprite_name (" . count($sprite_frames) . " frames) present but never used in DECORATE!" . PHP_EOL);
$this->sprites_unused++;
continue;
}
foreach ($sprite_frames as $sprite_frame => $blah) {
if (!isset($this->decorate_sprites_mentioned[$sprite_name][$sprite_frame])) {
echo ("??? No use found for $sprite_name frame $sprite_frame!" . PHP_EOL);
$this->sprites_unused++;
}
}
}
echo ("Sprites unused: " . $this->sprites_unused . PHP_EOL);
echo (PHP_EOL . PHP_EOL);
echo ("Sprites available" . PHP_EOL);
//Output the full sprites available/sprites used arrays
ksort($this->sprites_available);
foreach ($this->sprites_available as $sprite_name => $sprite_frames) {
ksort($sprite_frames);
echo ($sprite_name . " ");
foreach ($sprite_frames as $frame_letter => $frame_value) {
echo $frame_letter;
}
echo PHP_EOL;
}
echo (PHP_EOL . PHP_EOL);
ksort($this->decorate_sprites_mentioned);
echo ("Sprites mentioned in DECORATE" . PHP_EOL);
foreach ($this->decorate_sprites_mentioned as $sprite_name => $sprite_frames) {
ksort($sprite_frames);
echo ($sprite_name . " ");
foreach ($sprite_frames as $frame_letter => $frame_value) {
echo $frame_letter;
}
echo PHP_EOL;
}
echo (PHP_EOL . PHP_EOL);
}
public function examine_decorate_file($file_string) {
$results = [];
preg_match_all($this->state_regex, $file_string, $results);
foreach ($results[0] as $result) {
$result = trim($result);
//If we now have fewer than 8 characters, this is a false result so discard it
if (strlen($result) < 8) {
continue;
}
//Our first four characters are the sprite name
$sprite_name = strtoupper(substr($result, 0, 4));
if ($sprite_name == 'TNT1') { //The blank sprite
continue;
}
if ($sprite_name == 'GAME') {
echo $result . PHP_EOL;
}
$result = strtoupper(substr($result, 4));
if (!isset($this->decorate_sprites_mentioned[$sprite_name])) {
$this->decorate_sprites_mentioned[$sprite_name] = [];
}
//TODO If we notice a sprite with a zero length that isn't TNT1, add it to the list
//Next characters up until the next whitespace are the sprite frames
$char = '0';
$result = trim($result);
while (!in_array($char, [' ', '\t', ''])) {
$char = substr($result, 0, 1);
$result = substr($result, 1);
if (!in_array($char, [' ', '\t', ''])) {
$this->decorate_sprites_mentioned[$sprite_name][$char] = true;
}
}
}
}
}
//
$decorate_folder = isset($argv[1]) ? $argv[1] : null;
if ($decorate_folder == null) {
die("Please provide a DECORATE folder to search as the first command line arg!");
}
$sprite_folder = isset($argv[2]) ? $argv[2] : null;
if ($sprite_folder == null) {
die("Please provide a sprite folder to search as the second command line arg!");
}
$sud = new SpriteUseDetector();
$sud->run($decorate_folder, $sprite_folder);
Code: Select all
var $state_regex = '/^\h*[A-Za-z0-9]{4}\h+[a-zA-\]"]*\h+[-]?[0-9rR]+/m';
var $sprite_file_regex = '/^[A-Za-z0-9]{4}[a-zA-\]\^]{1}[0-1]/';
Code: Select all
CACO ABCDEF 6
TNT1 a 0
poss ab random(4, 6)
Similarly, the second regex searches for any file that conforms to the Doom sprite naming scheme - four alphanumeric characters, a letter or one of the other special frame characters, and then a number representing direction (followed by anything else, for files that act as more than one direction).
Code: Select all
SPOSA2D8
BON1A0.png
SKULD1
Code: Select all
!!! PUFY (3 frames) not found among the sprite files!
!!! PUF2 (26 frames) not found among the sprite files!
!!! File for DIBR frame A was not found!
!!! File for BAL2 frame A was not found!
??? SHSL (5 frames) present but never used in DECORATE!
??? ST81 (6 frames) present but never used in DECORATE!
??? No use found for XBRN frame F!
??? No use found for DIBR frame X!
-
- Posts: 207
- Joined: Thu Apr 16, 2015 8:24 am
Re: BDLite - a slimmed-down effects mod [2018-10-10]
I wanna heap on some more praise for you actually doing this. I've wanted a redone version of the monsters for years now and broke down into tears every time looked at the code.
===================
Would it be possible to have a fire-select for the rifle? I'm kinda not a fan of burst fire that isn't actually burst fire. I realize removing full-auto is good for balance, but might I suggest a semi-auto mode so that the user can at least have some control over when the bullets come out of the barrel? Maybe even use the burst-fire for autofire --like you already have it-- and semi for spamming the trigger.
===================
Would it be possible to have a fire-select for the rifle? I'm kinda not a fan of burst fire that isn't actually burst fire. I realize removing full-auto is good for balance, but might I suggest a semi-auto mode so that the user can at least have some control over when the bullets come out of the barrel? Maybe even use the burst-fire for autofire --like you already have it-- and semi for spamming the trigger.
-
- Posts: 422
- Joined: Fri Dec 22, 2017 1:53 am
- Graphics Processor: ATI/AMD (Modern GZDoom)
Re: BDLite - a slimmed-down effects mod [2018-10-12]
@OP:
Are you planning on making another version that is pretty much solely a refactorized version of this mod? By that, no anti-features?
And yeah, gonna try this one at a later time. Looks cool.
Are you planning on making another version that is pretty much solely a refactorized version of this mod? By that, no anti-features?
And yeah, gonna try this one at a later time. Looks cool.
-
- Posts: 21706
- Joined: Tue Jul 15, 2003 7:33 pm
- Preferred Pronouns: He/Him
- Operating System Version (Optional): A lot of them
- Graphics Processor: Not Listed
Re: BDLite - a slimmed-down effects mod [2018-10-12]
....huh?Cacodemon345 wrote:anti-features?
-
- Posts: 116
- Joined: Sun Oct 02, 2016 11:37 am
- Graphics Processor: Intel (Modern GZDoom)
Re: BDLite - a slimmed-down effects mod [2018-10-12]
Found a bug! The mod is interfering with buttons / actions in D64D2.WAD. Using GZDoom 3.6.0 on MAP02 you'll find that the button on the blue key pedestal does not open the doors on the rear wall. In GZDoom 3.5.1, the switch in the centre of the dark room doesn't work. Should BDLite be loaded before the PWAD file?
Edit: Works if loaded before the PWAD!
Edit: Works if loaded before the PWAD!
Last edited by Kroc on Sat Oct 13, 2018 2:04 pm, edited 1 time in total.