示例#1
0
        public bool AddProperty(ArchSolarComponentProperty arch)
        {
            Type archType = arch.GetType();

            if (archType == typeof(ArchSolarComponentPropertyRigidHull))
            {
                SolarComponentPropertyRigidHull hull = new SolarComponentPropertyRigidHull(this, arch as ArchSolarComponentPropertyRigidHull);
                properties[typeof(SolarComponentPropertyRigidHull)] = hull;
                return(true);
            }

            return(false);
        }
示例#2
0
        private void CreateHardpoints(ArchSolarComponent arch)
        {
            SolarComponentPropertyRigidHull hull = GetProperty <SolarComponentPropertyRigidHull>();

            if (hull == null)
            {
                return;
            }

            foreach (ArchComponentHardpoint hp in arch.hardpoints)
            {
                SolarComponentHardpoint hardpoint = new SolarComponentHardpoint(hp, hull);

                hardpoints.Add(hardpoint.id, hardpoint);
            }
        }
 public SolarComponentHardpoint(ArchComponentHardpoint arch, SolarComponentPropertyRigidHull hull)
 {
     this.id = arch.id;
     this.hull = hull;
 }
 public SolarComponentHardpoint(ArchComponentHardpoint arch, SolarComponentPropertyRigidHull hull)
 {
     this.id   = arch.id;
     this.hull = hull;
 }