Minable Cliffs not showing expected resources

Place to get help with not working mods / modding interface.
Post Reply
EnigmaticAussie
Fast Inserter
Fast Inserter
Posts: 129
Joined: Mon Dec 18, 2017 7:53 am
Contact:

Minable Cliffs not showing expected resources

Post by EnigmaticAussie »

Edit:
What:

If an entity has minable results, or lootable results, these should show in the tooltip underneath the Map.

Why:

Consistency.



Original:

Made a simple mod to allow the player to mine cliffs and gain a bunch of resources, much like rocks.

Yet, in game, the expected resources don't appear in the tooltip under the mini-map.

Is this expected behaviour, or am I missing something obvious?

Code: Select all

-- get all cliff types, make selectable and minable, yielding resources

for k, v in pairs(data.raw.cliff) do
  v.minable = {
    mining_particle = 'stone-particle',
    mining_time = 30,
    results = {
      {name = 'stone', amount_min = 50, amount_max = 150},
      {name = 'coal', amount_min = 50, amount_max = 75}
    }
  }
  v.loot = {
    {name = 'stone', amount_min = 50, amount_max = 150},
    {name = 'coal', amount_min = 50, amount_max = 75}
  }
  v.selectable_in_game = true
end
Image
Last edited by EnigmaticAussie on Wed Nov 18, 2020 12:52 pm, edited 1 time in total.

User avatar
Deadlock989
Smart Inserter
Smart Inserter
Posts: 2528
Joined: Fri Nov 06, 2015 7:41 pm

Re: Minable Cliffs not showing expected resources

Post by Deadlock989 »

I have encountered other weirdnesses around "expected results" in the past, one got tweaked after I made a request. I suspect these things are handled per entity type so it could just be that the cliff entity doesn't have it set up and you'll have to ask for it. You would have a good argument for saying that if the entity supports minable results and/or lootable results then the tooltip should show them.
Image

EnigmaticAussie
Fast Inserter
Fast Inserter
Posts: 129
Joined: Mon Dec 18, 2017 7:53 am
Contact:

Re: Minable Cliffs not showing expected resources

Post by EnigmaticAussie »

@moderators - Can someone please move this into the MIR sub-thread please?

I've updated the original post to clarify the request.

Post Reply

Return to “Modding help”