[INACTIVE][MECH] Cow Paths v2 - Pave the paths where players walk [670]

Discussion in 'Inactive/Unsupported Plugins' started by deltahat, Apr 6, 2011.

  1. Offline

    deltahat

    Cow Paths - Pave the paths where players walk
    Version: v2

    Cow Paths is a bukkit plugin for simulating the natural erosion caused by player walking. The name of the plugin comes from the phrase "to pave the cow paths." As players walk around the server, Cow Paths keeps track of the number of times each block has been stepped on and erodes the world accordingly. By default, the world erosion patterns are (with step thresholds in parentheses):

    Grass -(10)-> Dirt -(50)-> Gravel -(200)-> Cobblestone -(800)-> Smooth Stone
    Sand -(100)-> Sandstone

    Download
    Jar - https://github.com/rmichela/CowPaths/downloads
    Source - https://github.com/rmichela/CowPaths

    Configuration
    The erosion patters and step thresholds used by Cow Paths are completely configurable. All wear patterns are stored in the config.yml file under the wearPatterns key. A wear pattern is made up of a three part string containing the fromMaterial, toMaterial, and stepThreshold. A line looks like this:

    Code:
    - Grass Dirt 10
    When defining the fromMaterial and toMaterial, you can use either a material's canonical name or ID number. Malformed wear patterns will be ignored. If two wear patterns share the same fromMaterial, only the first one will be used.

    API
    To access Cow Paths data in your plugins, use the following code
    Code:
    CowPaths cpPlugin = (CowPaths)this.getServer().getPluginManager().getPlugin("CowPaths");
    CowPathsApi cpApi = cpPlugin.api;
    
    Don't forget to add appropriate null protection.

    Changelog:
    Version 2
    • Fixed console spamming bug
    • Added API
    • Added total steps metric
    Version 1
    • Initial Release
     
    Flipp, credence, Digi and 1 other person like this.
  2. Offline

    Flenix

    No idea how to fix it, but I can explain it.
    The "snow" block is technically a block like air that you walk through not on top of, therefore you aren't standing on the snow but just walking through it so it wont register a change. When you fall on the snow you stand on it for a moment, so it registers a change there.
    Never thought of that really :p
     
  3. Offline

    TheGurw

    i would like to add this, but i would require multiworld support before i do.....
     
  4. Offline

    Tibs

    multiworld works fine, just its one configuration across all worlds. Cowpaths creates separate folder to store paths for each world.

    Something has to be done about the way cowpaths stores it's data, it's now taking up more space than my world folder =(.

    world folder:
    649 files, 1.7GB

    cowpaths:
    380014 files, 1.8GB

    If I compress the cowpaths folder it takes up 91MB, this tells me there is a LOT of wasted space here. Of those 380k files 296k of them are 203 bytes.

    I am thinking that this doesn't have to be so precise to get the same effect, consider a chance, each time a player steps on a block there is a chance it will turn into another block. You wouldn't even need persistent storage with this method.
     
  5. Offline

    valdark

    I agree with this... a percent chance would be highly preferable for me.
     
  6. Offline

    deltahat

    Yeah... reducing the space requirement is on my todo list. One of the reasons it takes so much space is that files can't be smaller than about 4kb on a disk, even if they take up less than 4kb of data. This is caused by minimum block sizes in the filesystem. When you compress, you are able to get rid of all the empty data.
     
  7. Offline

    verboseone

    I to like the chance method!
     
  8. Offline

    Alesana

    Hey guys, i'm getting this error:

    Code:
    2011-05-05 13:46:07 [SEVERE] [Cow Paths] Error paging in chunk step data.
    java.io.EOFException
        at java.io.ObjectInputStream$BlockDataInputStream.readFully(Unknown Source)
        at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
        at java.io.ObjectInputStream.readSerialData(Unknown Source)
        at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
        at java.io.ObjectInputStream.readObject0(Unknown Source)
        at java.io.ObjectInputStream.readObject(Unknown Source)
        at java.util.HashMap.readObject(Unknown Source)
        at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at java.io.ObjectStreamClass.invokeReadObject(Unknown Source)
        at java.io.ObjectInputStream.readSerialData(Unknown Source)
        at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
        at java.io.ObjectInputStream.readObject0(Unknown Source)
        at java.io.ObjectInputStream.defaultReadFields(Unknown Source)
        at java.io.ObjectInputStream.readSerialData(Unknown Source)
        at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
        at java.io.ObjectInputStream.readObject0(Unknown Source)
        at java.io.ObjectInputStream.readObject(Unknown Source)
        at com.ryanmichela.cowpaths.model.WorldStepData.pageInChunk(WorldStepData.java:76)
        at com.ryanmichela.cowpaths.controller.StepController.loadChunk(StepController.java:90)
        at com.ryanmichela.cowpaths.controller.StepController.prime(StepController.java:115)
        at com.ryanmichela.cowpaths.plugin.CowPaths.onEnable(CowPaths.java:88)
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:127)
        at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:632)
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:218)
        at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:116)
        at org.bukkit.craftbukkit.CraftServer.loadPlugins(CraftServer.java:94)
        at net.minecraft.server.MinecraftServer.e(MinecraftServer.java:217)
        at net.minecraft.server.MinecraftServer.a(MinecraftServer.java:204)
        at net.minecraft.server.MinecraftServer.init(MinecraftServer.java:144)
        at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:259)
        at net.minecraft.server.ThreadServerApplication.run(SourceFile:394)
    I'm using Craftbukkit version git-Bukkit-0.0.0-706-gf53e007-b740jnks (MC: 1.5_02).

    Any idea please?
     
  9. Offline

    deltahat

    I'll look into it tonight.
     
  10. Offline

    TheGurw

    What I mean is on for some, off for others, or with different configurations for different worlds. I have small city worlds (limited size) with portals spaced apart in the infinite world that is my main map. I'd like to not have the city worlds degrade this way.
     
  11. Offline

    Plague

    670 - inactive
     
  12. Offline

    Krispy

    I would love to see this maintained.
     
  13. Offline

    iPhysX

    it isnt technically 'NOT' maintained :/
     
  14. Offline

    Krispy

    I'm sorry, I must have my terminology mixed up. I'd love to see it updated to the latest craftbukkit build.
     
  15. Offline

    iPhysX

  16. Offline

    Specops343

    Any chance of this being after 1.6 drops?
     
  17. Offline

    deltahat

    Maybe....after bukkit's dust settles.
     
  18. Offline

    compgurusteve

    860 seems to be a fan favorite. Any chance of updating now?
     
  19. Offline

    deltahat

  20. Offline

    compgurusteve

  21. Offline

    jellybellys

    don't expect anything till mid-july, I'm going to be quite busy
     
  22. Offline

    compgurusteve

    :-/ meh, that's a shame, but I'll still wait patiently.
     

Share This Page