Пример #1
0
        public Weapon(int numberOfDice,
                      int diceSides,
                      int damageMod,
                      int penetration,
                      int encumbrance,
                      int enchantmentLevel,
                      int price,
                      WeaponType type,
                      WeaponReach reach,
                      WeaponHandedness handedness,
                      WeaponSize size) :
            base("", "", encumbrance, price)
        {
            NumberOfDice     = numberOfDice;
            DiceSides        = diceSides;
            DamageMod        = damageMod;
            Penetration      = penetration;
            EnchantmentLevel = enchantmentLevel;
            Type             = type;
            Reach            = reach;
            Handedness       = handedness;
            Size             = size;
            IsDire           = false;
            Quality          = WeaponQuality.MAX;
            Material         = WeaponMaterial.MAX;

            _isEquippable = true;

            WeaponId = NextAvailableId;
            NextAvailableId++;
        }
Пример #2
0
    void Start()
    {
        wepControl   = GameObject.Find("Player").GetComponent <PlayerWepControl> ();
        spellControl = GameObject.Find("Player").GetComponent <PlayerSpellControl> ();
        mover        = GameObject.Find("Player").GetComponent <PlayerMove> ();
        wepSize      = GameObject.Find("Player").GetComponent <WeaponSize> ();
        mouseLook    = GameObject.Find("Player").GetComponentInChildren <SimpleSmoothMouseLook> ();

        bladeRenderer  = GameObject.Find("Player").transform.Find("CharacterHead").Find("RightWep").Find("RightWepBlade").GetComponent <Renderer>();
        handleRenderer = GameObject.Find("Player").transform.Find("CharacterHead").Find("RightWep").Find("RightWepHandle").GetComponent <Renderer>();

        headSlider   = transform.Find("HeadSizeSlider").GetComponent <Slider> ();
        handleSlider = transform.Find("HandleSizeSlider").GetComponent <Slider> ();
        typeDrop     = transform.Find("TypeDropdown").GetComponent <Dropdown> ();
        statText     = transform.Find("StatIndicator").GetComponent <Text> ();

        Transform colorStuff = transform.Find("ColorCustomizers");

        bladeRedSlider   = colorStuff.Find("BladeRedSlider").GetComponent <Slider>();
        bladeGreenSlider = colorStuff.Find("BladeGreenSlider").GetComponent <Slider>();
        bladeBlueSlider  = colorStuff.Find("BladeBlueSlider").GetComponent <Slider>();
        bladeColorImage  = colorStuff.Find("BladeColorImage").GetComponent <Image>();

        handleRedSlider   = colorStuff.Find("HandleRedSlider").GetComponent <Slider>();
        handleGreenSlider = colorStuff.Find("HandleGreenSlider").GetComponent <Slider>();
        handleBlueSlider  = colorStuff.Find("HandleBlueSlider").GetComponent <Slider>();
        handleColorImage  = colorStuff.Find("HandleColorImage").GetComponent <Image>();
    }
Пример #3
0
    void Start()
    {
        wepControl = GameObject.Find ("Player").GetComponent<PlayerWepControl> ();
        spellControl = GameObject.Find ("Player").GetComponent<PlayerSpellControl> ();
        mover = GameObject.Find ("Player").GetComponent<PlayerMove> ();
        wepSize = GameObject.Find ("Player").GetComponent<WeaponSize> ();
        mouseLook = GameObject.Find ("Player").GetComponentInChildren<SimpleSmoothMouseLook> ();

        bladeRenderer = GameObject.Find ("Player").transform.Find ("CharacterHead").Find ("RightWep").Find ("RightWepBlade").GetComponent<Renderer>();
        handleRenderer = GameObject.Find ("Player").transform.Find ("CharacterHead").Find ("RightWep").Find ("RightWepHandle").GetComponent<Renderer>();

        headSlider = transform.Find ("HeadSizeSlider").GetComponent<Slider> ();
        handleSlider = transform.Find ("HandleSizeSlider").GetComponent<Slider> ();
        typeDrop = transform.Find ("TypeDropdown").GetComponent<Dropdown> ();
        statText = transform.Find ("StatIndicator").GetComponent<Text> ();

        Transform colorStuff = transform.Find ("ColorCustomizers");

        bladeRedSlider = colorStuff.Find ("BladeRedSlider").GetComponent<Slider>();
        bladeGreenSlider = colorStuff.Find ("BladeGreenSlider").GetComponent<Slider>();
        bladeBlueSlider = colorStuff.Find ("BladeBlueSlider").GetComponent<Slider>();
        bladeColorImage = colorStuff.Find ("BladeColorImage").GetComponent<Image>();

        handleRedSlider = colorStuff.Find ("HandleRedSlider").GetComponent<Slider>();
        handleGreenSlider = colorStuff.Find ("HandleGreenSlider").GetComponent<Slider>();
        handleBlueSlider = colorStuff.Find ("HandleBlueSlider").GetComponent<Slider>();
        handleColorImage = colorStuff.Find ("HandleColorImage").GetComponent<Image>();
    }
Пример #4
0
 public Weapon(SerializationInfo info, StreamingContext ctxt)
     : base(info, ctxt)
 {
     this.damage     = (int)info.GetValue("damage", typeof(int));
     this.damageType = (DamageType)info.GetValue("damagetype", typeof(DamageType));
     this.protection = (Dictionary <DamageType, int>)info.GetValue("protection", typeof(Dictionary <DamageType, int>));
     this.size       = (WeaponSize)info.GetValue("size", typeof(WeaponSize));
 }
Пример #5
0
 public Weapon(SerializationInfo info, StreamingContext ctxt)
     : base(info, ctxt)
 {
     this.damage = (int)info.GetValue("damage", typeof(int));
     this.damageType = (DamageType)info.GetValue("damagetype", typeof(DamageType));
     this.protection = (Dictionary<DamageType, int>)info.GetValue("protection", typeof(Dictionary<DamageType, int>));
     this.size = (WeaponSize)info.GetValue("size", typeof(WeaponSize));
 }
Пример #6
0
 public Weapon(int itemid)
     : base(itemid)
 {
     this.damage     = int.Parse(ItemStats.GetStat(itemid, "damage"));
     this.damageType = StatParser.ParseDamageType(ItemStats.GetStat(itemid, "damagetype"));
     this.proc       = null;
     size            = StatParser.ParseWeaponSize(ItemStats.GetStat(itemid, "size"));
     this.Equippable = true;
 }
Пример #7
0
 public Weapon(int itemid)
     : base(itemid)
 {
     this.damage = int.Parse(ItemStats.GetStat(itemid, "damage"));
     this.damageType = StatParser.ParseDamageType(ItemStats.GetStat(itemid, "damagetype"));
     this.proc = null;
     size = StatParser.ParseWeaponSize(ItemStats.GetStat(itemid, "size"));
     this.Equippable = true;
 }
Пример #8
0
        static void Main(string[] args)
        {
            Console.WriteLine("Welcome to TolchokInfo database. Here we have some information on Minsk city LARP movement");

            var clubsList = new ShowClubs();

            clubsList.ShowListOfClubs();

            var clubMembers = new ShowClubs();

            clubMembers.ShowClub();

            BrigadaMembers brigMemberName = (BrigadaMembers)1;
            WeaponSize     brgMmbrWpnSz   = 0;
            WeaponMaterial brgMmbrWpnMtr  = 0;
            WeaponType     brgMmbrWpnTp   = 0;
            VisitedGames   brgVisGames    = 0;

            var brigMember1 = new Tolchok();

            brigMember1.Name         = brigMemberName.ToString();
            brigMember1.FavWeapon    = $"{brgMmbrWpnSz} {brgMmbrWpnMtr} {brgMmbrWpnTp}";
            brigMember1.GamesVisited = brgVisGames.ToString();
            Console.WriteLine(brigMember1.PrepareReport());



            //var kris = new Tolchok();
            //kris.Name = "Kris";
            //kris.DateOfBirth = new DateTime(1994, 6, 7);
            //Console.WriteLine("select your club");
            //foreach (ClubNames club in (ClubNames[])Enum.GetValues(typeof(ClubNames)))
            //{
            //    Console.WriteLine($"{(int)club} - {club}");
            //}
            //kris.Club = (ClubNames) int.Parse(Console.ReadLine());
            //Console.WriteLine(kris.PrepareReport());
            //if (kris.Club == ClubNames.Brigada)
            //{
            //    Console.WriteLine("100% Dexter enrolled!");
            //}
            //else if (kris.Club == ClubNames.DSE)
            //{
            //    Console.WriteLine("Ex Vice Minister is your head");
            //}
            //else
            //{
            //    Console.WriteLine("noname club");
            //}

            Console.ReadLine();
        }
Пример #9
0
 public static List<Item> WeaponsAsItems(this List<Item> inventory, WeaponSize size)
 {
     return inventory.Weapons(size).Cast<Item>().ToList();
 }
Пример #10
0
 public static List<Weapon> Weapons(this List<Item> inventory, WeaponSize size)
 {
     return inventory.Weapons().FindAll(delegate(Weapon x) { return x.Size == size; });
 }
Пример #11
0
 public static List <Item> WeaponsAsItems(this List <Item> inventory, WeaponSize size)
 {
     return(inventory.Weapons(size).Cast <Item>().ToList());
 }
Пример #12
0
 public static List <Weapon> Weapons(this List <Item> inventory, WeaponSize size)
 {
     return(inventory.Weapons().FindAll(delegate(Weapon x) { return x.Size == size; }));
 }
Пример #13
0
 public Equipment(WeaponSize s, string p)
 {
     size   = s;
     prefab = p;
 }