Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chips #103

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Chips #103

wants to merge 3 commits into from

Conversation

pruby
Copy link

@pruby pruby commented May 1, 2013

This includes my last pull request as well as it has a dependency on it.

This provides the ability to make naturally reinforced blocks drop "chips" while we mine them. These are an item that drops with some probability on each blocked break. It also includes an ability to block the final drop.

Here's an example natural reinforcements section of config:

naturalReinforcements:
  STONE:
    durability: 5
  IRON_ORE:
    durability: 50
    chipDrops:
      IRON_INGOT: 0.1
    disableNormalDrops: true

This would make stone take on average 5 breaks to break and iron ore 50. The iron ore, however, would not drop ore as normal. It would instead have a 10% (0.1) chance of dropping an iron ingot on each break, making each ore give us on average 5 ingots. When it finally breaks we get nothing due to disableNormalDrops being set for IRON_ORE.

Note that all this logic is disabled if a silk touch tool is used. Mining with ST never drops chips, but the final drop is allowed (so ores can be collected). We could collect the iron ore by breaking it with ST (still average 50 hits) but would not get chips while doing so. This prevents us from placing the iron ore and starting to mine it again.

@pruby
Copy link
Author

pruby commented May 1, 2013

Packaged version of this at https://github.com/pruby/Citadel/blob/chip_pkg/Citadel.jar

Does require a config. This might do for testing:

naturalReinforcements:
  DIAMOND_ORE:
    durability: 100
    chipDrops:
      DIAMOND: 0.02
  GOLD_ORE:
    durability: 50
    chipDrops:
      GOLD_NUGGET: 0.2
    disableNormalDrops: true

Should create on average 3d/block for diamond (2 chips + final break) and 10 nuggets/block for gold (10 chips, no final break). At the moment fortune only affects the natural drop, not the chips.

@pruby
Copy link
Author

pruby commented May 1, 2013

This contained a minor bug which was that chips did no damage and cancelling the natural drops was also stopping the normal damage to the tool. As a result tools weren't damaged when mining chip-only materials at all.

I've added that each time we get a chip the tool accumulates one damage. This keeps it behaving similarly to the way it does already (not damaging tool on every break) but it does accumulate damage slowly.

@BoredCoder
Copy link

Can we get it so that there is an option for chance to receive a chip to reduce as the natural reinforcements lower? That way, we can better simulate exploitation of resources as when one uses up the "easy" resources, they have to turn to tapping a "harder" resource.

@LunNova
Copy link

LunNova commented May 1, 2013

The reinforcement is a chance in the PR this depends on so that can't
happen.
On 1 May 2013 14:18, "BoredCoder" [email protected] wrote:

Can we get it so that there is an option for chance to receive a chip to
reduce as the natural reinforcements lower? That way, we can better
simulate exploitation of resources as when one uses up the "easy"
resources, they have to turn to tapping a "harder" resource.


Reply to this email directly or view it on GitHubhttps://github.com//pull/103#issuecomment-17280841
.

@pruby
Copy link
Author

pruby commented May 1, 2013

The issue is that natural reinforcements aren't saved, and I can understand why the author avoided that (db load). Problem is, people could mine forever as long as they only damaged each block less than its durability each day - the server restart would set back to full strength.

The choices here were to get saving working, or make it irrelevant by having a chance to lose the block from the first break. I can adjust the mechanics here, but would rather avoid people gaming it.

Sent from my phone

----- Reply message -----
From: "BoredCoder" [email protected]
To: "Exultant/Citadel" [email protected]
Cc: "Tim Goddard" [email protected]
Subject: [Citadel] Chips (#103)
Date: Thu, May 2, 2013 01:18
Can we get it so that there is an option for chance to receive a chip to reduce as the natural reinforcements lower? That way, we can better simulate exploitation of resources as when one uses up the "easy" resources, they have to turn to tapping a "harder" resource.


Reply to this email directly or view it on GitHub.

@pruby pruby closed this May 1, 2013
@pruby pruby reopened this May 1, 2013
@pruby
Copy link
Author

pruby commented May 1, 2013

(accidentally hit button with that closing)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants