コード例 #1
0
 public override void _PhysicsProcess(float delta)
 {
     if (PlayerColliding)
     {
         if (Seed != null)
         {
             if (Input.IsActionJustPressed("Player_Action"))
             {
                 var CurSeed = Seeds.GetSeed(Seed);
                 if (PlayerBody.Money >= CurSeed.Price)
                 {
                     PlayerBody.Inventory.Gain(CurSeed);
                     PlayerBody.Money -= CurSeed.Price;
                 }
             }
         }
     }
     OutLine.Visible = false;
     PlayerColliding = false;
 }