Dismiss Notice
Wynncraft, the Minecraft MMORPG. Play it now on your Minecraft client at (IP): play.wynncraft.com. No mods required! Click here for more info...

Horse Breeding Simulator

Discussion in 'Wynncraft' started by Skip, Nov 13, 2015.

Thread Status:
Not open for further replies.
  1. Skip

    Skip Wynncraft's only Elmo HERO

    Messages:
    95
    Likes Received:
    20
    Trophy Points:
    54
    Minecraft:
    Hello everyone,

    I wanted to know the average price of making a horse in wynncraft. To calculate this I made a Horse Breeding Simulator. Here are the results:

    Bought Horses:1.000010000100001
    Attempts:99999
    Emeralds:1536.0153601536015
    EB:24.000240002400023
    LE:0.37500375003750036
    24 Emerald Blocks

    Bought Horses:5.998719987199872
    Attempts:99999
    Emeralds:9214.033900339004
    EB:143.96927969279693
    LE:2.249519995199952
    2.2 Liquified Emeralds

    Bought Horses:43.48404548404548
    Attempts:999999
    Emeralds:66791.49386349386
    EB:1043.6170916170915
    LE:16.306517056517055
    16.3 Liquified Emeralds

    Bought Horses:317.1796361796362
    Attempts:999999
    Emeralds:487187.9211719212
    EB:7612.311268311269
    LE:118.94236356736357
    118.9 Liquified Emeralds

    This is open source code. You can do anything with it!
    PHP:
    package blaah;

    import java.util.ArrayList;
    import java.util.HashMap;

    public class 
    dsfaadsfdafs {

        private static 
    ArrayList<Horse> list = new ArrayList<>();

        public static 
    void main(String[] args) {
            
    int attempts 9999999;
            
    double averageaverage(attemptsHorse.CHESTNUT_HORSE); // Horse is an enum with all 4 horses available.
            
    double price average 24*64;
            
    System.out.println("Bought Horses:" average +"\n"
                    
    "Attempts:" attempts "\n"
                    
    "Emeralds:" price+"\n"
                    
    "EB:" price/64+"\n"
                    
    "LE:" price/64/64);
        }
      
      
        public static 
    double average(int amountHorse horse){
            
    int total 0;
            for(
    int i 0<= amounti++){
                
    total += breeder(horse);
            }
            
    double average = (double)total / (double)amount;
            return 
    average;
        }

        public static 
    int breeder(Horse horse) {
            list.
    clear();
            
    int brownHorseAmount 0;
            while (!list.
    contains(horse)) {
                if(
    getHorseAmount(Horse.BROWN_HORSE) < && getHorseAmount(Horse.BLACK_HORSE) < && getHorseAmount(Horse.WHITE_HORSE) < 2) {
                    list.
    add(Horse.BROWN_HORSE);
                    
    brownHorseAmount ++;
                }
                for(
    Horse breed Horse.values()){
                    if (
    getHorseAmount(breed) >= 2) {
                        list.
    remove(breed);
                        list.
    remove(breed);
                        list.
    add(breed(breedbreed));
                    }
                }
            }
            return 
    brownHorseAmount;
        }

        private static 
    Horse breed(Horse motherHorse father) {
            if (
    mother.equals(father)) {
                
    double random Math.random();
                if (
    mother.equals(Horse.CHESTNUT_HORSE)) {
                    if (
    random <= 0.2) {
                        return 
    Horse.WHITE_HORSE;
                    }
                    if (
    random <= 0.5) {
                        
    double rand Math.random();
                        if (
    rand <= 50)
                            return 
    Horse.BLACK_HORSE;
                        return 
    Horse.BROWN_HORSE;
                    }
                    if (
    random <= 1) {
                        return 
    Horse.CHESTNUT_HORSE;
                    }
                }
                if (
    mother.equals(Horse.BLACK_HORSE)) {
                    if (
    random <= 0.2) {
                        return 
    Horse.CHESTNUT_HORSE;
                    }
                    if (
    random <= 0.5) {
                        return 
    Horse.BROWN_HORSE;
                    }
                    if (
    random <= 1) {
                        return 
    Horse.BLACK_HORSE;
                    }
                }
                if (
    mother.equals(Horse.BROWN_HORSE)) {
                    if (
    random <= 0.2) {
                        return 
    Horse.BLACK_HORSE;
                    }
                    if (
    random <= 0.5) {
                        return 
    Horse.BROWN_HORSE;
                    }
                    if (
    random <= 1) {
                        return 
    Horse.BROWN_HORSE;
                    }
                }
                return 
    Horse.BROWN_HORSE;
            }
            return 
    Horse.BROWN_HORSE;
        }

        private static 
    int getHorseAmount(Horse horse) {
            
    int i 0;
            for (
    Horse paard : list) {
                if (
    paard.equals(horse))
                    
    i++;
            }
            return 
    i;
        }

    }

    xx,
    Elmo
     
    Archie_T likes this.
  2. YYGAYMER

    YYGAYMER reeeee FW FW Media HIC Master Featured Wynncraftian

    Messages:
    5,160
    Likes Received:
    16,286
    Trophy Points:
    215
    Guild:
    Minecraft:
    Known thing.
    (10 chars)
    ________________________________
    ...but nice source code
     
  3. Devourer

    Devourer Lava Warrior VIP+

    Messages:
    5,035
    Likes Received:
    1,762
    Trophy Points:
    81
    Minecraft:
    If people actually sold and bought horses for these prices, then the wynn economy might be less screwed up. IF anyone buys things anymore at Detlas, which I never see happen much.
     
  4. Skip

    Skip Wynncraft's only Elmo HERO

    Messages:
    95
    Likes Received:
    20
    Trophy Points:
    54
    Minecraft:
    Unfortunately there were dupers who messed up the Wynn economy. Wynncraft is able to fix this by using default prices and only make you able to buy and sell 20% around this.
     
    Devourer likes this.
  5. Devourer

    Devourer Lava Warrior VIP+

    Messages:
    5,035
    Likes Received:
    1,762
    Trophy Points:
    81
    Minecraft:
    Ik. If only Wynn had never had these dupers...
     
Thread Status:
Not open for further replies.