public static void buffPlayer(ref GameStateData gs, PlayerData player, ItemsData item, int i)
        {
            if (item.active == true)
            {
                switch (item.type)
                {
                case 0:
                    player.PlayerLifeStock += 1;
                    //Debug.Log("buff life");
                    break;

                case 1:
                    player.PlayerSpeed += 0.1f;
                    //Debug.Log("buff speed");
                    break;

                case 2:
                    //player.weapon = WeaponList.paint_weapon;
                    //Debug.Log("buff weapon");
                    break;
                }
                item.active   = false;
                gs.items[i]   = item;
                gs.players[0] = player;
            }
        }
 private static void InitItems(ref GameStateData gs)
 {
     for (int i = 0; i < MAX_ITEMS; i++)
     {
         var item = new ItemsData
         {
             position = new Vector3(NoObjectInObstacle(ref gs, true),
                                    NoObjectInObstacle(ref gs, false)),
             rotation = new Vector3(0, 0, 0),
             //rotationSpeed = 10,
             rotationSpeedVector = new Vector3(0, 5, 0),
             radius = 0.5f,
             active = true
         };
         gs.items.Add(item);
         //Debug.Log(item.position);
     }
 }