void IUnitBehaviour.HandleUnitDetach()
            {
                spellModifiers.Clear();
                SpellHistory.Detached();
                Cast.Detached();

                unit = null;
            }
Exemplo n.º 2
0
            void IUnitBehaviour.HandleUnitDetach()
            {
                spellTriggers.Clear();
                schoolImmunities.Clear();
                spellModifiers.Clear();
                SpellHistory.Detached();
                Cast.Detached();

                unit = null;
            }
 static int Clear(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         System.Collections.Generic.Dictionary <string, SingleField> obj = (System.Collections.Generic.Dictionary <string, SingleField>)ToLua.CheckObject(L, 1, typeof(System.Collections.Generic.Dictionary <string, SingleField>));
         obj.Clear();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
 static int Clear(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         System.Collections.Generic.Dictionary <uint, Logic.Character.HeroEntity> obj = (System.Collections.Generic.Dictionary <uint, Logic.Character.HeroEntity>)ToLua.CheckObject(L, 1, typeof(System.Collections.Generic.Dictionary <uint, Logic.Character.HeroEntity>));
         obj.Clear();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
Exemplo n.º 5
0
    protected void OnControlToggleToggled(object sender, EventArgs e)
    {
        if (controlToggle.Active)
        {
            shiftedControls[Gdk.Key.Left]  = new JointControl(this.commandConnection, "HeadYaw", 1.57, 0.15);
            shiftedControls[Gdk.Key.Right] = new JointControl(this.commandConnection, "HeadYaw", -1.57, 0.15);
            shiftedControls[Gdk.Key.Up]    = new JointControl(this.commandConnection, "HeadPitch", -0.7, 0.1);
            shiftedControls[Gdk.Key.Down]  = new JointControl(this.commandConnection, "HeadPitch", 0.5, 0.1);

            shiftlessControls[Gdk.Key.Left]  = new WalkControl(this.commandConnection, 0.0, 0.75, 0.0);
            shiftlessControls[Gdk.Key.Right] = new WalkControl(this.commandConnection, 0.0, -0.75, 0.0);
            shiftlessControls[Gdk.Key.Up]    = new WalkControl(this.commandConnection, 1.0, 0.0, 0.0);
            shiftlessControls[Gdk.Key.Down]  = new WalkControl(this.commandConnection, -0.5, 0.0, 0.0);

            shiftlessControls[Gdk.Key.c] = new JointControl(this.commandConnection, "LShoulderPitch", 1.57, 0.1);
            shiftlessControls[Gdk.Key.v] = new JointControl(this.commandConnection, "LShoulderPitch", 0, 0.1);
            shiftlessControls[Gdk.Key.d] = new JointControl(this.commandConnection, "LElbowRoll", 0, 0.1);
            shiftlessControls[Gdk.Key.f] = new JointControl(this.commandConnection, "LElbowRoll", -1.57, 0.1);
            shiftlessControls[Gdk.Key.e] = new JointControl(this.commandConnection, "LHand", 0, 0.25);
            shiftlessControls[Gdk.Key.r] = new JointControl(this.commandConnection, "LHand", 1, 0.25);

            shiftlessControls[Gdk.Key.m] = new JointControl(this.commandConnection, "RShoulderPitch", 1.57, 0.1);
            shiftlessControls[Gdk.Key.n] = new JointControl(this.commandConnection, "RShoulderPitch", 0, 0.1);
            shiftlessControls[Gdk.Key.k] = new JointControl(this.commandConnection, "RElbowRoll", 0, 0.1);
            shiftlessControls[Gdk.Key.j] = new JointControl(this.commandConnection, "RElbowRoll", 1.57, 0.1);
            shiftlessControls[Gdk.Key.o] = new JointControl(this.commandConnection, "RHand", 0, 0.25);
            shiftlessControls[Gdk.Key.i] = new JointControl(this.commandConnection, "RHand", 1, 0.25);

            selectedControls = shiftlessControls;
        }
        else
        {
            foreach (var c in shiftedControls.Values)
            {
                c.Stop();
            }
            foreach (var c in shiftlessControls.Values)
            {
                c.Stop();
            }

            shiftedControls.Clear();
            shiftlessControls.Clear();

            selectedControls = null;
        }

        ttsEntry.Sensitive = !controlToggle.Active;
    }
Exemplo n.º 6
0
    static public void cleanup()
    {
        if (unitObjects != null)
        {
            foreach (var unit in unitObjects.Values)
            {
                GameObject.Destroy(unit);
            }


            unitObjects.Clear();            //Debug.Log( "cleanup PathUnitMeshTemplateCreator3" );


            unitObjects = null;
        }
    }
    static int Clear(IntPtr L)
    {
        ToLua.CheckArgsCount(L, 1);
        System.Collections.Generic.Dictionary <int, TestAccount> obj = (System.Collections.Generic.Dictionary <int, TestAccount>)ToLua.CheckObject(L, 1, typeof(System.Collections.Generic.Dictionary <int, TestAccount>));

        try
        {
            obj.Clear();
        }
        catch (Exception e)
        {
            LuaDLL.luaL_error(L, e.Message);
            return(0);
        }

        return(0);
    }
Exemplo n.º 8
0
    public static void CloseWorld()
    {
        if (RuntimeRoot.HasNode("SkyScene"))
        {
            RuntimeRoot.GetNode("SkyScene").QueueFree();
        }
        PlayerList.Clear();
        PossessedPlayer = ((PackedScene)GD.Load("res://Player/Player.tscn")).Instance() as Player;
        //Prevent crashes when player movement commands are run when world is not initalized
        StructureRoot          = null;
        Scripting.GamemodeName = null;
        Scripting.SetupServerEngine();
        Scripting.SetupClientEngine();
        Scripting.ClientGmScript = null;

        Building.Chunks.Clear();
        Building.RemoteLoadedChunks.Clear();
    }
Exemplo n.º 9
0
    private void ClearPlayers()
    {
        foreach (var player in players.Values)
        {
            Debug.Log(player);
            var mesh = player.playerController.gameObject.GetComponentInChildren <MeshRenderer>();
            if (mesh != null)
            {
                Destroy(mesh.gameObject);
            }
            Destroy(player.playerController.gameObject);
        }
        players.Clear();

        Node.ClearActives();
        Node.ClearBounces();
        GameBoard.KillSpotLights();
    }
Exemplo n.º 10
0
    public static DataTable getAccessionDetailsExtended(String AccountNumber, String ChartNumber, String PetName, String owner, String TestCode, String DateFrom, String DateTo, String DoctorName, Int32 startIndex, Int32 noOfRecords, out String query, Boolean useSoundex, String pageName, Int32 timeout, out Boolean isError)
    {
        CACHEDAL.ConnectionClass cache = new CACHEDAL.ConnectionClass();
        #region Preparing Query
        System.Text.StringBuilder sb = new System.Text.StringBuilder();
        sb.Append("SELECT ");
        sb.Append("ACC_Accession,");
        sb.Append("ACC_OwnerLastName||', '||ACC_PetFirstName AS PATIENT,");
        sb.Append("ACC_TestsOrderedDisplayString AS TESTSORDERED,");
        sb.Append("ACC_ClientDR->CLF_CLNUM AS ACCOUNTNUM,");
        sb.Append("ACC_MiniLogDate As ORDERDATE,");
        sb.Append("ACC_MiniLogTime As ORDERTIME,");
        sb.Append("ACC_ReportStatus As ReportStatus,");
        sb.Append("ACC_IsStat As StatDesignation,");
        sb.Append("$$GETINQNOTE^XT11(ACC_Accession) As InqNotes ");
        sb.Append("FROM ");
        sb.Append("ORD_Accession ");
        sb.Append("WHERE ");
        sb.Append("1=1");
        //There is an index with Doctor & Account.
        //If Doctor is present as search criteria, then client has to be present in the search criteria
        if (DoctorName.Length > 0)
        {
            sb.Append(" AND ACC_RequestingPhysician %STARTSWITH '" + DoctorName + "'");

            if (AccountNumber.Length > 0)
            {
                sb.Append(" AND ACC_ClientDR->CLF_CLNUM ='" + AccountNumber + "'");
            }
            else if (DateFrom.Length == 0 && DateTo.Length == 0)    //SSM 03/11/2011 #Issue115786 Migrating Accession search Changes
            {
                sb.Append(" AND ACC_ClientDR->CLF_CLNUM <>''");
            }
        }
        else if (AccountNumber.Length > 0)
        {
            sb.Append(" AND ACC_ClientDR->CLF_CLNUM ='" + AccountNumber + "'");
        }
        if (ChartNumber.Length > 0)
        {
            sb.Append(" AND ACC_MedicalRecordsNumber ='" + ChartNumber + "'");
        }
        if (!useSoundex)
        {
            if (owner.Length > 0)
            {
                sb.Append(" AND ACC_OwnerLastName %STARTSWITH '" + owner + "'");
            }
            if (PetName.Length > 0)
            {
                sb.Append(" AND ACC_PetFirstName %STARTSWITH '" + PetName + "'");
            }
        }
        else
        {
            if (owner.Length > 0)
            {
                System.Collections.Generic.Dictionary <string, string> tmpCol = new System.Collections.Generic.Dictionary <string, string>();
                tmpCol.Add("OwnerName", owner);
                tmpCol.Add("PetName", String.Empty);
                //String SoundexString = cache.StoredProcedure("?=call SP2_getSoundex(?,?)", tmpCol).Value.ToString();
                String SoundexString = cache.StoredProcedure("?=call SP2_getSoundex(?,?)", tmpCol, pageName, timeout, out isError).Value.ToString();
                if (isError) // for Reset Search
                {
                    query = "";
                    return(null);
                }
                if (SoundexString.Length > 0)
                {
                    SoundexString = owner + "^#" + SoundexString;
                }
                else
                {
                    SoundexString = owner + "^";
                }
                if (SoundexString.Length > 0)
                {
                    String[] OwnerPet = SoundexString.Split('#');
                    tmpCol.Clear();
                    sb.Append(" AND (");
                    for (Int32 i = 0; i < OwnerPet.Length; i++)
                    {
                        String[] tmp = OwnerPet[i].Split('^');
                        if (!tmpCol.ContainsKey(tmp[0]) && tmp[0].Length > 0)
                        {
                            tmpCol.Add(tmp[0], String.Empty);
                            sb.Append(" (ACC_PetFirstName %STARTSWITH '" + PetName + "' AND ACC_OwnerLastName %STARTSWITH '" + tmp[0] + "') OR");
                            //// Note:  'ACC_PetFirstName' is for petName with tmp[1]
                            ////        'ACC_OwnerLastName' is for owner with tmp[0]
                        }
                    }
                    sb.Remove(sb.Length - 2, 2);
                    sb.Append(" )");
                }
            }
            else if (PetName.Length > 0)
            {
                System.Collections.Generic.Dictionary <string, string> tmpCol = new System.Collections.Generic.Dictionary <string, string>();
                tmpCol.Add("OwnerName", owner);
                tmpCol.Add("PetName", PetName);
                // String SoundexString = cache.StoredProcedure("?=call SP2_getSoundex(?,?)", tmpCol).Value.ToString();
                String SoundexString = cache.StoredProcedure("?=call SP2_getSoundex(?,?)", tmpCol, pageName, timeout, out isError).Value.ToString();
                if (isError) // for Reset Search
                {
                    query = "";
                    return(null);
                }

                if (SoundexString.Length > 0)
                {
                    SoundexString = "^" + PetName + "#" + SoundexString;
                }
                else
                {
                    SoundexString = "^" + PetName;
                }
                if (SoundexString.Length > 0)
                {
                    String[] OwnerPet = SoundexString.Split('#');
                    tmpCol.Clear();
                    sb.Append(" AND (");
                    for (Int32 i = 0; i < OwnerPet.Length; i++)
                    {
                        String[] tmp = OwnerPet[i].Split('^');
                        if (!tmpCol.ContainsKey(tmp[1]) && tmp[1].Length > 0)
                        {
                            tmpCol.Add(tmp[1], String.Empty);
                            sb.Append(" (ACC_PetFirstName %STARTSWITH '" + tmp[1] + "' AND ACC_OwnerLastName %STARTSWITH '') OR");
                            //// Note:  'ACC_PetFirstName' is for petName with tmp[1]
                            ////        'ACC_OwnerLastName' is for owner with tmp[0]
                        }
                    }
                    sb.Remove(sb.Length - 2, 2);
                    sb.Append(" )");
                }
            }
        }
        if (!String.IsNullOrEmpty(TestCode))
        {
            TestCode = TestCode.Replace("'", "''");
            sb.Append(" AND (ACC_TestsOrderedDisplayString ='" + TestCode + "' OR ACC_TestsOrderedDisplayString %STARTSWITH '" + TestCode + ",' OR ACC_TestsOrderedDisplayString LIKE '%, " + TestCode + "' OR ACC_TestsOrderedDisplayString LIKE '%, " + TestCode + ", %')");
        }
        if (!String.IsNullOrEmpty(DateFrom) && !String.IsNullOrEmpty(DateTo))
        {
            sb.Append(" AND ACC_MiniLogDate>= {d '" + DateTime.Parse(DateFrom).ToString("yyyy-MM-dd") + "'} AND ACC_MiniLogDate<={d '" + DateTime.Parse(DateTo).ToString("yyyy-MM-dd") + "'}");
        }
        if ((!String.IsNullOrEmpty(DateFrom) && !String.IsNullOrEmpty(DateTo)) || (!String.IsNullOrEmpty(AccountNumber)))
        {
            //sb.Append(" ORDER BY ACC_MiniLogDate DESC, ACC_OwnerLastName");
            sb.Append(" ORDER BY ACC_MiniLogDate DESC, ACC_MiniLogTime DESC");
        }
        else
        {
            //sb.Append(" ORDER BY ACC_OwnerLastName");
        }

        string selectStatement = sb.ToString();
        #endregion Preparing Query
        query = selectStatement;
        return(cache.FillCacheDataTable(selectStatement, startIndex, noOfRecords, pageName, timeout, out isError));
    }
Exemplo n.º 11
0
 public void ClearAll()
 {
     _activedCharacters.Clear();
 }
Exemplo n.º 12
0
 public void ClearTextures()
 {
     Textures.Clear();
 }