user()->character; if ($character->isInHospital() || $character->isDead()) { $releaseTime = $character->in_hospital_until ? $character->in_hospital_until->diffForHumans() : 'unknown'; $reviveCost = config('game.health.hospital_cost', 1000); return redirect()->route('game.hospital') ->with('error', "You are in hospital and cannot perform actions. You will be released {$releaseTime} or can revive for \${$reviveCost}."); } return $next($request); } }