Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 3 4 [5] 6 7 ... 12

Author Topic: [44.12] Musket-Mod v0.5c: Experimental Wall Breaching  (Read 40821 times)

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #60 on: August 24, 2018, 12:30:39 pm »

Perfect. :-)

Mind if I do the rest?
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

Vordak

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #61 on: August 24, 2018, 12:37:51 pm »

Perfect. :-)

Mind if I do the rest?
No problem.
Logged

zaporozhets

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #62 on: August 24, 2018, 12:46:32 pm »



Великолепная пушка, у вас есть моя благодарность. Извините за обязательство.
Logged

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #63 on: August 24, 2018, 01:04:36 pm »

I present: The VoMeZa-Cannon!



What do you think? It's mostly Vordaks sprites, even the tracks are his. ^^ He improved the ones I had in my tileset once.

With TWBTnext you have transparency, so the workshop appears round, the corners will look like the floor below it.
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

Vordak

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #64 on: August 24, 2018, 01:11:17 pm »

Great idea.
But track stops maybe can make narrower? So that it does not stand out against the background of the gun's nose.
And add for example a blue tint to the metal of cannon for better contrast.

In general, on such a floor does not look contrasted - everything merges.


Upd. Perhaps it is worth to divide into two types:
1) My, stationary.
2) by Meph - the same cannon, only with a swivel device, costs more materials
« Last Edit: August 24, 2018, 01:44:29 pm by Vordak »
Logged

thefriendlyhacker

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #65 on: August 24, 2018, 01:29:44 pm »

I present: The VoMeZa-Cannon!



What do you think? It's mostly Vordaks sprites, even the tracks are his. ^^ He improved the ones I had in my tileset once.

With TWBTnext you have transparency, so the workshop appears round, the corners will look like the floor below it.
When you said a circle with tracks on it, I thought you were going to do a little railway loop with the gun facing outwards and perpendicular to the tracks, so rotating the gun would just be a matter of pushing the rail cart through 90 deg of track, and the firer would stand in the center of the rail loop while firing the gun. I just figured I would bring it up as an alternative design you could try if you wanted.
Logged
Fallout Equestria Redux - that's right, it's back

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #66 on: August 24, 2018, 01:50:31 pm »



More contrast. Blue hue on the gun, and smaller track-stops.

afriendlyhacker: That sounds more logical, but when was logic ever the strong suit of dwarves? :D Won't make a second design now. ^^
« Last Edit: August 24, 2018, 01:52:47 pm by Meph »
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

Vordak

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #67 on: August 24, 2018, 01:54:34 pm »

« Last Edit: August 24, 2018, 02:05:17 pm by Vordak »
Logged

zaporozhets

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #68 on: August 24, 2018, 03:22:38 pm »



That was impressive to watch, like a collaborative argument between artists.
I probably won't add both types in at once as separate cannons to make the scripting easier on myself, but to respect Vordak's wish and to give players a choice of which they prefer, I'll include both in separate install folders.
Thanks, guys. I'm very lucky to have your assistance.

Edit:
I could just be suffering from sleep deprivation but the 'swivel' one doesn't appear to be centered. Is it a problem with creating a circle with so few pixels or a mishap?
« Last Edit: August 24, 2018, 03:36:40 pm by zaporozhets »
Logged

Vordak

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #69 on: August 24, 2018, 05:00:35 pm »

I could just be suffering from sleep deprivation but the 'swivel' one doesn't appear to be centered. Is it a problem with creating a circle with so few pixels or a mishap?
I corrected the offset.


That was impressive to watch, like a collaborative argument between artists.
I probably won't add both types in at once as separate cannons to make the scripting easier on myself, but to respect Vordak's wish and to give players a choice of which they prefer, I'll include both in separate install folders.
Do not be so tense - choose one at your discretion.
« Last Edit: August 24, 2018, 05:17:50 pm by Vordak »
Logged

zaporozhets

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4c (Now with ingame customization menu!)
« Reply #70 on: August 25, 2018, 06:37:21 am »

I corrected the offset.

Do not be so tense - choose one at your discretion.

Appreciate it.
I can't help being tense. I don't want to upset anyone, especially if they are doing me a favour.

Just rewriting the cannon to work with the new separate load and fire reactions now. Reactions don't seem to register as completing unless they have a product, so I'm just changing it to work on job completion instead.
Going to take chemical weapons out for now, I'm changing how they work so I can't write the cannon script to accommodate them until I'm completely set on how I'm doing that and it's done to test. I'd rather just get the updated cannon out so I can work on the chemical stuff with no pressure.

Does anyone know if there is a proper way of getting items out of buildings? Not too keen on having to clone and delete them like I've done previously. Tried items.moveToGround() and setting Item.pos manually with no luck.
Logged

Grimlocke

  • Bay Watcher
  • *kobold noises*
    • View Profile
Re: [44.12] Musket-Mod v0.4f
« Reply #71 on: August 26, 2018, 06:59:07 pm »

Nice work on the cannon improvements!

Here's where I'm at with my own efforts with the handheld firearms, which kind of sprawled into a script to modify any projectile: https://pastebin.com/j07S30Nb

Right now it modifies accuracy, velocity, firing rate, hit rate (to account for shot weapons that should be harder to dodge), chance of breaking on impact (needed that for a thrown weapon), whether it pierces through stuff or not and how many extra projectiles it spawns of which item subtype.

A few lingering issues I'm still having and could use some advice on are that I can't quite think of a way around: I'm trying to have it do stuff based on the weapon used, so that I can slow down firing rate for heavier crossbow (using the same ammunition). The projectile data structure has a 'bow_id' value, which is a number starting at 0 and increasing as more items are spawned in the map. It clearly corresponds to the specific ranged weapon used, but its not an item ID and I can't get any of the item functions to do anything useful with it. I suspect there's some obvious way of using that that I'm missing.

Also I've been trying to change the item type of projectiles, which is easy enough for the subtype (using item.setSubtype), but setType doesn't exist. Is there some other way of doing this or do I just have to delete the original and spawn a new projectile?

I'm also somewhat of a noob at lua, so if anyone spots screwups or points of improvement, I'd be much obliged if you point them out.

And as an aside, I've noticed that the 'piercing' flag behaves weirdly and causes a single projectile to hit the same target numerous times, sometimes killing them dead instantly, before passing through. Might be useful to simulate explosives? Change the material to something with huge shear value and give the projectile plenty of contact area/surface and it should make giblets easily enough.

Edit: Just found that the shot projectiles can only hit one target one time, even though a single shot can hit multiple enemies at once. Even at close range the a single enemy only gets hit by one projectile while the rest merrily goes on its way.
« Last Edit: August 26, 2018, 07:22:00 pm by Grimlocke »
Logged
I make Grimlocke's History & Realism Mods. Its got poleaxes, sturdy joints and bloomeries. Now compatible with DF Revised!

SpeardwarfErith

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4f
« Reply #72 on: August 26, 2018, 08:07:09 pm »

Could I include the rocket launchers in the dune mod I'm creating? They really are amazing, and proper credit would obviously be given.
Logged
The swordsman Smoma Acaltekud: Hello Ago. Life is, in a word, death.
The swordsman Smoma Acaltekud stabs you in the lower body with his iron scimitar, tearing apart the muscle and tearing apart the left kidney!
The iron scimitar has lodged firmly in the wound!

Battle Royale Mode: A DFHack Script

zaporozhets

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4f
« Reply #73 on: August 26, 2018, 10:45:39 pm »

Here's where I'm at with my own efforts with the handheld firearms, which kind of sprawled into a script to modify any projectile: https://pastebin.com/j07S30Nb

Right now it modifies accuracy, velocity, firing rate, hit rate (to account for shot weapons that should be harder to dodge), chance of breaking on impact (needed that for a thrown weapon), whether it pierces through stuff or not and how many extra projectiles it spawns of which item subtype.

Very impressed after a cursory reading. As a fellow noob to lua, I did not know you could set table keys like that.
I did notice you set multiProjectile.distance_flown to 6 to avoid smoke, I initially did something similar on the blunderbuss before I noticed it seemed to be teleporting the projectiles forward. It's not a problem really unless the target is nearly adjacent.
Making a general purpose projectile script is a brilliant idea.

A few lingering issues I'm still having and could use some advice on are that I can't quite think of a way around: I'm trying to have it do stuff based on the weapon used, so that I can slow down firing rate for heavier crossbow (using the same ammunition). The projectile data structure has a 'bow_id' value, which is a number starting at 0 and increasing as more items are spawned in the map. It clearly corresponds to the specific ranged weapon used, but its not an item ID and I can't get any of the item functions to do anything useful with it. I suspect there's some obvious way of using that that I'm missing.

I've had this issue too and just sidestepped it by giving the weapon a new ammo, the only way I could think of using the same ammo was iterating through the firers inventory on distance_flown == 0, getting projectile.firer.inventory[indx].item.subtype.id and checking against the weapon name (or checking subtype.subtype, but I like strings for readability), but it was for the automusket and I was worried about the overhead and so didn't go any further with it. Hope that works for you.

Also I've been trying to change the item type of projectiles, which is easy enough for the subtype (using item.setSubtype), but setType doesn't exist. Is there some other way of doing this or do I just have to delete the original and spawn a new projectile?

I don't know of any other way of doing it, I don't think I was even aware of setSubtype until just now (will come in handy, thanks).
The next best thing would be creating a new item and changing the original projectiles .item to the new item, but my experience with trying to do stuff like that is it crashes the game. I've tried changing the general/specific_refs too but it just doesn't like it. I don't think I was trying to do that specifically though, maybe you would have better luck than myself.

And as an aside, I've noticed that the 'piercing' flag behaves weirdly and causes a single projectile to hit the same target numerous times, sometimes killing them dead instantly, before passing through. Might be useful to simulate explosives? Change the material to something with huge shear value and give the projectile plenty of contact area/surface and it should make giblets easily enough.

Edit: Just found that the shot projectiles can only hit one target one time, even though a single shot can hit multiple enemies at once. Even at close range the a single enemy only gets hit by one projectile while the rest merrily goes on its way.

Interesting stuff. I'll need have to have more of a mess around with the projectile flags, I have no idea what I'm doing with them. I just copied them in from Roses projectile script and I keep getting a weird bug on the cannon where it only causes light bruising, setting the piercing flag seemed to fix it but now I'm not so sure it did what I thought given what you've said. Maybe I should just make the cannonball use an edge attack. Has anything like that happened to you?

Could I include the rocket launchers in the dune mod I'm creating? They really are amazing, and proper credit would obviously be given.

It's lovely of you to ask, of course you can! I've been messing about with a lasgun that makes an instant beam of 'laser' and one that has a more simple 'blaster' trail as well, but I'm not happy with the results are so far (fire rate is just to make testing easier):



Your thread seems to indicate you also have a preliminary version of it as well, I'd love to see it. I want to try my hand at the beam-shield interaction.
« Last Edit: August 26, 2018, 11:34:00 pm by zaporozhets »
Logged

thefriendlyhacker

  • Bay Watcher
    • View Profile
Re: [44.12] Musket-Mod v0.4f
« Reply #74 on: August 27, 2018, 04:36:45 am »

...
I've had this issue too and just sidestepped it by giving the weapon a new ammo, the only way I could think of using the same ammo was iterating through the firers inventory on distance_flown == 0, getting projectile.firer.inventory[indx].item.subtype.id and checking against the weapon name (or checking subtype.subtype, but I like strings for readability), but it was for the automusket and I was worried about the overhead and so didn't go any further with it. Hope that works for you.
...
I wouldn't be so concerned with overhead if I was you.  If you are doing checks that only happen during combat, then any overhead caused by those checks will be hidden by the massive slowdown caused by combat.  No sane amount of searching through memory is going to compare to the herculean task of writing "The goblin lasher dodges the steel bolt" to hard drive.  Unless you are doing something that iterates through lists multiple times on a constant near tick by tick basis, don't even bother worrying about performance, because your dinky little script's overhead will be lost in the sea of RAM sundering computation cycles that is Dwarf Fortress.
Logged
Fallout Equestria Redux - that's right, it's back
Pages: 1 ... 3 4 [5] 6 7 ... 12