コード例 #1
0
        public void SetParams(int ID, EventExtraParams e)
        {
            MechanismInfo mi = FindMechanismInfo(ID);

            if (mi.mechanism != null && e.l_block > 0)
            {
                if (mi.Number == 8)
                {
                    Mechanism_8 old   = mi.mechanism as Mechanism_8;
                    Mechanism_8 new_m = new Mechanism_8(old.r1, old.R1, old.r2, e.l_rope, old.v_block, old.Center, old.ID);
                    mi.mechanism = new_m;
                }
                RestartMechanism(ID);
                StopMechanism(ID);
                DrawMechanism(ID);
            }
        }