Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 170 171 [172] 173 174 ... 244

Author Topic: DFHack 50.14-r1.1  (Read 888965 times)

Vantezzle

  • Escaped Lunatic
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2565 on: August 31, 2020, 08:41:51 am »

It's not too surprising, since DFHack does do everything a virus does. In a sense it is a literal trojan horse: it impersonates another piece of code (SDL.dll) for its own nefarious purposes (modifying working memory... of a video game, to be fair)
Right, the surprising part is that (only?) dfhack-run was flagged, which doesn't do that.

Admittedly I'm not entirely sure how to check that, but out of curiousity I downloaded the github zip on my two old laptops, one with Bitdefender, another with Windows Defender and they both flagged it.
I first downloaded LNP last Sunday and everything was fine until yesterday.
You could check the hash of both files or use some file-comparison tool.
I suspect that your anti-virus definitions got updated recently and triggered this, which can happen pretty often depending on the software you're using. Redownloading like you did is probably the best way to ensure that something didn't actually change the file itself.

Yeah the hash matches.
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2566 on: August 31, 2020, 06:16:04 pm »

Hey there folks. Just curious if there is a way to utilize the buildingplan plug so that every time I close DF it saves the parameters. Every time I open the game I have to reset all the build-able items and their materials, etc.
That's currently not supported, at least as far as I know (most plugins don't support this). It may be worth putting up a feature request for it on the issue tracker if it would be a good feature to have. I'd be happy to help anyone interested in working on this, although I may not have a lot of time for it myself in the near future. There have been some (sort of) recent persistent storage changes that might make things like this easier, although part of it also depends on how complicated the buildingplan settings are to save/load.
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.

myk

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2567 on: September 01, 2020, 02:45:54 pm »

Another/additional option for persisting buildingplan filters could be to use json-based export/import like the orders plugin. Not quite as automatic as persistent data (unless we auto-export on save and auto-import on load), but more useful for copying across forts.

I do have some dev tasks for buildingplan on my short list for quickfort integration:
  • respect item filters that are passed in from the api
  • support all teh buildings (starting with constructions)
If filter persistence is still unimplemented when I'm done with that, I could look into implementing it.

Might be a while, though. There might be a raft of bug reports for quickfort when it goes out in the next release that I'll need to focus on.
Logged

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2568 on: September 03, 2020, 11:47:12 am »

Another/additional option for persisting buildingplan filters could be to use json-based export/import like the orders plugin. Not quite as automatic as persistent data (unless we auto-export on save and auto-import on load), but more useful for copying across forts.

I do have some dev tasks for buildingplan on my short list for quickfort integration:
  • respect item filters that are passed in from the api
  • support all teh buildings (starting with constructions)
If filter persistence is still unimplemented when I'm done with that, I could look into implementing it.

Might be a while, though. There might be a raft of bug reports for quickfort when it goes out in the next release that I'll need to focus on.

It's fairly easy to auto-save/auto-load json files using the import/export stuff. Depending on how the data for the plugin is stored it may only be a few lines of code.
Logged

Arson

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2569 on: September 03, 2020, 04:05:40 pm »

Another/additional option for persisting buildingplan filters could be to use json-based export/import like the orders plugin. Not quite as automatic as persistent data (unless we auto-export on save and auto-import on load), but more useful for copying across forts.

I do have some dev tasks for buildingplan on my short list for quickfort integration:
  • respect item filters that are passed in from the api
  • support all teh buildings (starting with constructions)
If filter persistence is still unimplemented when I'm done with that, I could look into implementing it.

Might be a while, though. There might be a raft of bug reports for quickfort when it goes out in the next release that I'll need to focus on.

It's fairly easy to auto-save/auto-load json files using the import/export stuff. Depending on how the data for the plugin is stored it may only be a few lines of code.

Thanks to everyone for answering. I'm afraid any coding portion it outside my realm of knowledge though.
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2570 on: September 03, 2020, 04:46:35 pm »

It's fairly easy to auto-save/auto-load json files using the import/export stuff. Depending on how the data for the plugin is stored it may only be a few lines of code.

Are you talking about Lua-side persistent tables? Unfortunately it's not nearly as trivial in C++, because C++ types can't be serialized by default - plugins have to serialize their own data manually, which is why a lot of them don't. For example, here is what autochop does to save/load its config. Granted, it still uses the old histfig-based system, which is now a wrapper around the new JSON-based system - the new system would result in code that's a bit more readable, but just as verbose.
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.

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2571 on: September 04, 2020, 09:16:58 am »

It's fairly easy to auto-save/auto-load json files using the import/export stuff. Depending on how the data for the plugin is stored it may only be a few lines of code.

Are you talking about Lua-side persistent tables? Unfortunately it's not nearly as trivial in C++, because C++ types can't be serialized by default - plugins have to serialize their own data manually, which is why a lot of them don't. For example, here is what autochop does to save/load its config. Granted, it still uses the old histfig-based system, which is now a wrapper around the new JSON-based system - the new system would result in code that's a bit more readable, but just as verbose.

I was thinking lua side json.decode_file stuff, but didn't realize we were talking about a plugin.
Logged

myk

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2572 on: September 06, 2020, 04:44:13 pm »

After reading through the buildingplan code, it looks like there is already support for serializing ItemFilters to persistent storage, which is cool. The problem is that the item filter state is directly accessible and mutable, which means that we won't know when it changes and needs copying into persistent storage.

I'm planning on reworking the buildingplan API to remove "abstraction leaks" like this. Once the API is solidified, I think persisting the ItemFilter settings will be very doable.
Logged

myk

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2573 on: September 17, 2020, 08:57:10 pm »

As I refactor buildingplan and get it in shape to handle the remaining building types for quickfort, I noticed that it is inconsistent with how it handles artifacts. It allows the filters to accept artifacts, and you can even set them to accept *only* artifacts, but when it scans for available items it filters artifacts out so they can never be matched.

Unless there are any objections, I'm thinking of changing this so that artifacts can be properly matched, but the default quality settings allow only ordinary though masterwork. If you want to match artifacts, you would have to manually increase the quality filter to include them.
Logged

nezclaw

  • Bay Watcher
  • i should really migrate my saves...
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2574 on: September 20, 2020, 09:34:03 pm »

hey uh sorry to sound like a n00b but i was trying to install dfhack to go with the most recent version of the game instead of downloading the LNP since the most recent DF version is updated when i do a system update and i didn't see a point in downloading another copy via the pack. i think i installed it properly, but when i run it it only gives me the builtin commands and no scripts or plugins.
Spoiler (click to show/hide)
the stderr.log
i'm running arch linux (which i didn't set up my brother did, he's more computer savvy than i am)
Logged
Dawnthunder: It menaces with spikes of tetanus
After the fire had burned down all of the wooden next boxes on the surface, Mottled Petrel was reluctant to replace them with more wooden nest boxes. Instead, he placed the remaining store of wooden nest boxes in the dormitory for any aspiring koopa mothers.

The nest boxes were immediately overrun by helmet snakes.

Ziusudra

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2575 on: September 20, 2020, 11:13:20 pm »

hey uh sorry to sound like a n00b but i was trying to install dfhack to go with the most recent version of the game instead of downloading the LNP since the most recent DF version is updated when i do a system update and i didn't see a point in downloading another copy via the pack. i think i installed it properly, but when i run it it only gives me the builtin commands and no scripts or plugins.
Spoiler (click to show/hide)
the stderr.log
i'm running arch linux (which i didn't set up my brother did, he's more computer savvy than i am)
Did you install dfhack manually? Or did you use an AUR package?
Logged
Ironblood didn't use an axe because he needed it. He used it to be kind. And right now he wasn't being kind.

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2576 on: September 20, 2020, 11:37:59 pm »

I'm guessing you used a package - the output in stderr.log appears to indicate that you don't have any plugins (since it would log a message for every plugin that's loaded). This is probably due to some parts of DFHack being installed in the wrong place relative to other parts. It will be tricky to troubleshoot, though, since the interactive "lua" interpreter is itself a Lua script, and I suspect those are installed in the wrong place as well. I should also be clear that this isn't necessarily your fault - we made a change in 0.47.04-r2 that changes the way DFHack computes the DF root path on Linux, sometimes. In a fresh install with vanilla DF, the behavior should be the same as in previous versions, but maybe it breaks a package.

Can you locate the path to libdfhack.so? By default, it should be in a "hack" folder, which should have subfolders named "plugins" and "scripts".
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.

nezclaw

  • Bay Watcher
  • i should really migrate my saves...
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2577 on: September 21, 2020, 02:21:27 pm »

i installed it manually, i didn't feel like running a -Syu yet. i can find libdfhack.so, and the scripts and plugins folders have things in them.
Logged
Dawnthunder: It menaces with spikes of tetanus
After the fire had burned down all of the wooden next boxes on the surface, Mottled Petrel was reluctant to replace them with more wooden nest boxes. Instead, he placed the remaining store of wooden nest boxes in the dormitory for any aspiring koopa mothers.

The nest boxes were immediately overrun by helmet snakes.

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2578 on: September 21, 2020, 05:41:33 pm »

i installed it manually, i didn't feel like running a -Syu yet. i can find libdfhack.so, and the scripts and plugins folders have things in them.
Ok, thanks, disregard my speculation in my earlier post. I probably should have asked "is libdfhack.so in the hack folder", although I think that's what you meant.

Can you verify that you're the owner of everything in the hack/plugins folder and that the read and execute permissions are enabled? e.g. with "ls -l hack/plugins"

If that doesn't help, just to get an idea of what your installation looks like, can you run this command in your DF folder and upload its output somewhere? Make sure it has some lines starting with "./hack" first. It may be large, so a site like Pastebin would probably be a better choice than pasting it directly in a reply.
Code: [Select]
find . -path ./data/save -prune -or -print


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.

Ziusudra

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.04-r2
« Reply #2579 on: September 21, 2020, 06:38:28 pm »

i installed it manually, i didn't feel like running a -Syu yet. i can find libdfhack.so, and the scripts and plugins folders have things in them.
Installing things manually on Arch is usually a bad idea especially with DF being installed as a package. The DF package installs things to /opt/dwarffortess and includes a script to make sure everthing is linked in ~/.dwarffortress and that the game is run with the correct working directory. The dfhack package works the same way and makes sure dfhack can find all its and DF's files.
Logged
Ironblood didn't use an axe because he needed it. He used it to be kind. And right now he wasn't being kind.
Pages: 1 ... 170 171 [172] 173 174 ... 244