GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — `hauler_type.Bin` is inaccurate · Issue #438 · DFHack/df-structures

hauler_type.Bin is inaccurate #438

New issue
Copy link
New issue
Copy link
Open
Open
hauler_type.Bin is inaccurate#438
Copy link
Labels
enumsresearch

Description

@lethosor
lethosor
opened on Aug 24, 2021
Issue body actions

Originally posted by @ab9rf in #435 (comment)

My research suggests that we should rename Bin to something else. Specifically, StoreItemInHospital jobs increment world.stockpile.num_jobs[Bin], even though a "store in hospital" job never result in anything being actually stored in a bin.

        pjVar38 = job::create();
        piVar42 = local_440;
        pjVar38->job_type = StoreItemInHospital;
...
        world.stockpile.num_jobs.Any = world.stockpile.num_jobs.Any + 1;
        world.stockpile.num_jobs.Bin = world.stockpile.num_jobs.Bin + 1;

Activity

  1. lethosor
    added
    enums
    research
    on Aug 24, 2021
  2. ab9rf commented on Aug 24, 2021

    @ab9rf
    ab9rf
    on Aug 24, 2021
    Member
    More actions

    To my fairly substantial surprise, I note that MSVC tells me that there are zero live references to df::enums::hauler_type::Bin in dfhack C++ code. I also did a search of the published hack/scripts folder and found no references in published Lua or Ruby scripts.

  3. lethosor commented on Aug 25, 2021

    @lethosor
    lethosor
    on Aug 25, 2021
    MemberAuthor
    More actions

    Isn't labormanager using a hardcoded "4" somewhere in place of it?

  4. ab9rf commented on Aug 25, 2021

    @ab9rf
    ab9rf
    on Aug 25, 2021
    Member
    More actions

    Isn't labormanager using a hardcoded "4" somewhere in place of it?

    Yes. And that's the only code in DFHack I'm aware of that uses world.stockpiles.num_haulers or world.stockpiles.num_jobs at all.

  5. quietust commented on Jun 12, 2024

    @quietust
    quietust
    on Jun 12, 2024
    Member
    More actions

    Turns out DF doesn't even have a "hauler_type" enum, and the arrays in world.stockpile (bay12 storage_handlerst) are simply two flat sets of variables whose names end with "", "_mining", "_wood", "_burial", "_item", "_body", "_food", "_refuse", "_furniture", and "_animals".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enumsresearch

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402520 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.