Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 192 193 [194] 195 196 ... 360

Author Topic: DFHack 0.43.03-r1  (Read 1087254 times)

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2895 on: June 29, 2015, 02:13:12 am »

I posted that in ~august last year IIRC, me cutting my own head off with a sword

good fun

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2896 on: June 29, 2015, 05:30:17 am »

I posted that in ~august last year IIRC, me cutting my own head off with a sword

good fun
So now we can mod in the astoundingly unsuccessful entrepreneur Cut Me Own Throat Dibbler.

More seriously, this sounds like it can simulate the martial artist who takes on several red shirts melee combatants as well as the wall-of-steel who deflects a silly number of incoming arrows with a weapon.  Good work!
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2897 on: June 29, 2015, 08:42:46 am »

I just love the idea of redirecting attacks and the possible chance to not only avoid an attack but to launch said attack back at the opponent 20 times stronger.

so yeah it's possible to set the attacking id to the same unit leading to self harm.
haven't seen what happens if you get a unit to charge after someone 3 tiles away, do they instantly warp over to there position or just fall over?
thought with dfhacking it's possible to launch.lua a man then while airborne punch him repeatedly.
to test this I guess someone needs to throw a unit at another unit then dfhack an attack action on the 'ball unit' with the 'batter unit'

When I was experimenting with attacks, they only applied to units directly next to the attacking unit. Even if I had it all set up correctly to attack a unit multiple tiles away, the game would just say "TARGET has moved away" or something like that. But you could combine the script with the teleport script and then be able to launch distant attacks.

EDIT: Interestingly enough this is only for body part attacks. It makes no check for where an item is when you attack. I had an elf in arena mode carrying a short sword on the right side of the map, and on the left side of the map I had a dwarf attack a goblin with that short sword. Note that this means an item just needs to be created, not carried in any way, to attack with. The combat report said "Dwarf 1 slashes Goblin 1 with her iron short sword"
« Last Edit: June 29, 2015, 02:17:59 pm by Roses »
Logged

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2898 on: June 29, 2015, 08:38:10 pm »

I'm thinking someone could go about checking how many tiles away a target is and then say, limiting the ranges at which an effect applies, cross check it by weapon type, and probably produce a rather functional approximation of longer and shorter ranged melee weapons.

Pikes and whips reaching across two squares, great swords, poleaxes, mauls, spears, and such reaching across one square, and other weapons having the normal requirement of being directly adjacent to your target.
Logged

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2899 on: June 29, 2015, 09:54:02 pm »

Well further testing shows that it doesn't matter where the weapon is located on the map, but the attacking unit must be adjacent to the targeted unit for an attack to be applied. Now I am still working on how to apply wounds regardless of attack (using Urist Da Vinci's formulas), and indeed I have a working script for that, but it doesn't handle things like breaking a bone through a body part and into another body part, or any other fancy wound mechanics.

I wonder... I suppose I could make a copy of both attacker and defender off screen and next to each other, generate the attack, and then copy the wound from the simulated target to the real target. That would keep all the wound calculation on the same, in-game system, but allow for complex attacks. Of course it would also involve creating copies of attacker and defender for each such attack, and that might lead to it's own issues, not to mention erroneous reports/announcements. It's odd to me that firing/throwing an item has no associated action. I suppose once an item is turned into a projectile it is no longer a part of the action system and no behaves independently.

But I think, with the combined functionality of adding attacks to units, and simulating attacks using mathematical formulas, I should be able to come up with a decent, all around attacking system. Just have to test things out and see what the game thinks.
Logged

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2900 on: June 30, 2015, 12:35:52 am »

Oh yeah, forgot that requirement of an adjacent target... could you initialize the attack targeting yourself and then change it to the appropriate target?

God I can see some funny side effects of that.
Logged

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2901 on: June 30, 2015, 12:34:48 pm »

Oh yeah, forgot that requirement of an adjacent target... could you initialize the attack targeting yourself and then change it to the appropriate target?

God I can see some funny side effects of that.

Alas, that won't help. There is some sort of check in the actual mechanics of the attack that looks to see if the target has moved away (most likely to handle dodging properly). If we were able to hack into the attack code itself (not just the action but the full on number crunching code) we could apply long range attacks. But I'm not sure how feasible that is, and it is definitely beyond my capabilities. If one of the DFHack gods would like to look into it though it could be amazing.
Logged

mifki

  • Bay Watcher
  • works secretly...
    • View Profile
    • mifki
Re: DFHack 0.40.24-r3
« Reply #2902 on: June 30, 2015, 05:42:49 pm »

Spoiler (click to show/hide)

Edit: nevermind, just a field is missing in the class.

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2903 on: June 30, 2015, 07:14:32 pm »

Oh yeah, forgot that requirement of an adjacent target... could you initialize the attack targeting yourself and then change it to the appropriate target?

God I can see some funny side effects of that.

Alas, that won't help. There is some sort of check in the actual mechanics of the attack that looks to see if the target has moved away (most likely to handle dodging properly). If we were able to hack into the attack code itself (not just the action but the full on number crunching code) we could apply long range attacks. But I'm not sure how feasible that is, and it is definitely beyond my capabilities. If one of the DFHack gods would like to look into it though it could be amazing.
Wait wait wait, I'm going to poke at a couple of things later, but I was reminded of something while I was falling asleep.

So rumrusher made it so launch uses the hunt target to fling other units, the neat thing there is even if that target is nowhere near you, until you do an action that sets a hunt target you can keep tossing them around like a ragdoll, right?

Gonna have to mess around and see if you can set a hunt target and use that to bootstrap it back into an action target.
Logged

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2904 on: June 30, 2015, 09:38:48 pm »

Hmmm, no luck, was able to aim the targets just fine but still get the moved out of range problem.
Logged

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2905 on: June 30, 2015, 10:02:32 pm »

Hmmm, no luck, was able to aim the targets just fine but still get the moved out of range problem.

Yeah, I tried a couple different ways to try and work around the range issue, but I think it is just a fundamental part of the attack, to account for things like dodging or long build up attacks against extremely fast units. DFHack trickery will be required to circumvent this check.
Logged

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2906 on: June 30, 2015, 10:09:41 pm »

Yeah, though I realized I also misinterpreted what was said about the position of the weapon not mattering, I read it as hitting the elf with the sword, not the elf having the sword and using it from a distance to hit something beside you with it.

Is there a way to make a dummy target/attacker instead of having to copy them entirely?
« Last Edit: June 30, 2015, 10:13:02 pm by Max™ »
Logged

Rumrusher

  • Bay Watcher
  • current project : searching...
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2907 on: June 30, 2015, 10:48:13 pm »

uhh spawnunit a creature then delete said creature after testing works?
Logged
I thought I would I had never hear my daughter's escapades from some boy...
DAMN YOU RUMRUSHER!!!!!!!!
"body swapping and YOU!"
Adventure in baby making!Adv Homes

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2908 on: June 30, 2015, 11:55:20 pm »

I was trying to find where the actual "targetable for attacks" entry is but haven't had any luck yet, I figured maybe it would be possible to pull up a bare minimum which would allow an attack to be aimed without having to fully create a creature.
Logged

Iban

  • Bay Watcher
  • [CAFFEINE_DEPENDENT]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2909 on: July 01, 2015, 11:37:21 am »

How do I use Tiletypes to remove any floor and make it Open Space? I'm trying to clear tiles under bridges. I swear to god yo used to be able to channel under a closed bridge, but no more.
Logged
Pages: 1 ... 192 193 [194] 195 196 ... 360