Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 173 174 [175] 176 177 ... 360

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

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2610 on: May 13, 2015, 08:21:10 am »

I never did have much luck getting those ones to work either.

So uh, I was trying to figure out for a while how the heck the reaction "imbue with material" I recall having at one point worked only to realize it was done through a script, apparently it was folded at least partially into another script but I can't figure out how to get one that makes something "Vaci Sunaclotho's skull helm" like the reaction one did, is that the only way to make it keep the name/body part stuff?

I recall playing with it some time back and accidentally making a roc feather dagger and such, was that broken by one of the more recent updates or am I just not looking in the right spot?

You may be looking for my script which I used to call imbue, but got changed to item/subtype-change. It will let you make things like roc feather daggers and such if used with modtools/reaction-trigger.

Boltgun and Meph, I'm pretty sure the problem was the self-targeting interaction rather than catching the syndrome.  I've never had much luck with self-targeting interactions for whatever reason.  What surprised me was that a probability 100 regional interaction didn't appear when it was the only option for that biome.  Interactions just hate me.  At least the Lua code works.

Can you post your interaction?
It's sort of a moot point now, though I'd like to know if I just plain did the interactions wrong.  These are the two interactions, though they wouldn't both be active at the same time.

Code: (interaction_tesb.txt) [Select]
interaction_tesb

[OBJECT:INTERACTION]

This interaction serves as a hook for a syndrome-trigger.

[INTERACTION:DOMESTICATE PET ROCK]
[I_SOURCE:REGION]
[IS_REGION:ANY]
[IS_FREQUENCY:100]
[I_TARGET:A:CREATURE]
[IT_LOCATION:CONTEXT_CREATURE]
[IT_AFFECTED_CREATURE:PET_ROCK:ALL]
[IT_CANNOT_TARGET_IF_ALREADY_AFFECTED]
[I_EFFECT:ADD_SYNDROME]
[IE_TARGET:A]
[IE_INTERMITTENT:WEEKLY]
[SYNDROME]
[SYN_NAME:Adorable pet rock]
[CE_MENT_ATTR_CHANGE:PATIENCE:200:1000:START:0]

[INTERACTION:GO_DOMESTIC]
[I_SOURCE:CREATURE_ACTION]
[I_TARGET:ME:CREATURE]
[IT_LOCATION:CONTEXT_CREATURE]
[IT_CANNOT_TARGET_IF_ALREADY_AFFECTED]
[I_EFFECT:ADD_SYNDROME]
[IE_TARGET:ME]
[SYNDROME]
[SYN_CLASS:TESB_DOMESTICATE]
[SYN_NAME:Adorable Pet Rock]
[CE_MENT_ATTR_CHANGE:PATIENCE:200:1000:START:0]

And in onload.init:

modtools/syndrome-trigger -syndrome "Adorable pet rock" -command [ tesb-domesticate \\UNIT_ID ]

which I know works when run from the console.  The regional one might have misfired because regional interactions just don't pop up as often as modders would like them to.  The self-interacting one probably misfired because the critter has an [IMMOBILE] tag, which seems to inhibit all interactions.

The whole reason I needed the script in the first place is that immobile wild animals can't get themselves caught in traps, and I really want these guys to be adoptable.  There is also a condition under which they'll be spawn-unit'ed, but those start out tame anyway.

Well, your syndrome for the creature action interaction has each word capitalized, that could be causing the trouble. And I assume you gave the creature the correct, [CAN_DO_INTERACTION:GO_DOMESTIC]?
« Last Edit: May 13, 2015, 08:26:11 am by Roses »
Logged

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2611 on: May 13, 2015, 10:47:31 am »

Yes, they had the interaction enabled.  But I suspect the IMMOBILE prevented it from working.
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 #2612 on: May 13, 2015, 11:15:30 am »

Ah, yes I do remember reading something about immobile animals not using interactions.
Logged

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2613 on: May 13, 2015, 03:17:32 pm »

Ohhhh, I figured subtype-change meant just weapon or armor subtype, thanks!
Logged

bennerman

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2614 on: May 17, 2015, 10:10:37 am »

Does anyone know why adv-bodyswap isn't working, or, alternatively, if I'm doing it wrong? the console says it doesn't exist. Dfusion "change adventurer" made the swap happen but all my companions ran away, screaming about "the violence"

edit: I should specify: I swapped into one of my companions to equip him properly and give back the items I accidentally gave him. So when I did, my companions (one of whom was originally me before the swap) ran away. When I slept, hoping they'd be back when I woke up, I couldn't move at all. No injuries, just slightly hungry and thirsty, but I couldn't move.
« Last Edit: May 17, 2015, 10:12:51 am by bennerman »
Logged

Jordan~

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2615 on: May 17, 2015, 11:45:56 am »

Box: What's wrong with teleport.lua? It was working for me the last time I checked (which was at least after v0.40.20, if not v0.40.24).

Couldn't see that anyone answered this: whenever I try to use it, I just get tracebacks.
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2616 on: May 17, 2015, 03:17:53 pm »

It works for me in 0.40.24-r3. Are you using it as described in the readme?

For example, this should teleport the selected unit to (44, 55, 167):
Code: [Select]
teleport -x 44 -y 55 -z 167
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

Jordan~

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2617 on: May 17, 2015, 03:25:00 pm »

That might be what was wrong - I tried to get coords with "teleport showpos", but that also just returned tracebacks.

Edit: It was showing coords and then tracebacks, actually. :P

Edit again: Got the position and the unit ID, entered teleport -z 73 -y30 -z 155 16028 (and with the coordinates and the unit ID the other way around), and in both cases I'm getting tracebacks and no actual teleportation happening.
« Last Edit: May 17, 2015, 03:31:04 pm by Jordan~ »
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2618 on: May 17, 2015, 03:26:29 pm »

That might be what was wrong - I tried to get coords with "teleport showpos", but that also just returned tracebacks.
You have to include the hyphen: "teleport -showpos"

(In general, most plugins parse commands manually and don't require hyphens, but several scripts use a centralized method of argument processing that does require hyphens.)
« Last Edit: May 17, 2015, 03:28:04 pm by lethosor »
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

Jordan~

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2619 on: May 17, 2015, 03:31:49 pm »

Ironically, teleport -showpos just returns tracebacks; teleport showpos returns coordinates and tracebacks.

Also tried using the cursor to indicate the unit rather than an ID. Same deal.
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2620 on: May 17, 2015, 05:00:56 pm »

There's no way "teleport showpos" can work. Can you copy and paste the traceback here? (Read: copy and paste - if you're on Windows, the relevant menu is available by clicking somewhere in the title bar.)
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

Jordan~

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2621 on: May 17, 2015, 05:26:29 pm »

Code: [Select]
...sktop\Shortcuts\Dwarf Fortress\40.24\hack\lua\dfhack.lua:454: ...Shortcuts\Dw
arf Fortress\40.24/hack/scripts/teleport.lua:15: syntax error near '=='
stack traceback:
        [C]: in function 'error'
        ...sktop\Shortcuts\Dwarf Fortress\40.24\hack\lua\dfhack.lua:454: in func
tion <...sktop\Shortcuts\Dwarf Fortress\40.24\hack\lua\dfhack.lua:425>
        (...tail calls...)
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2622 on: May 17, 2015, 05:40:28 pm »

It looks like you've made modifications to teleport.lua - the script in the most recent release doesn't have "==" anywhere on that line. Try replacing the script with that version (clicking the "Raw" button will allow you to save it more easily).
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

DragonDePlatino

  • Bay Watcher
  • [HABIT:COLLECT_WEALTH]
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2623 on: May 17, 2015, 08:34:05 pm »

What is the command for identifying the tile under your cursor? Like, if I pointed at a grass tile, it would output "GrassLightFloor1"? I've been searching through the help files but I just can't find it...

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.40.24-r3
« Reply #2624 on: May 17, 2015, 08:35:07 pm »

There's "probe", although it'll give you a lot more information than that.
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.
Pages: 1 ... 173 174 [175] 176 177 ... 360