Files
City10/database/factories/CityFactory.php
T
marcocosta10000 79ce2a1825 feat(world): add persistent citizen simulation with needs, jobs, and social features
- Adds Character model with survival needs (hunger, thirst, energy) and state machine
- Implements city:tick world ticker for offline progression every minute
- Adds city territory expansion and building construction system
- Introduces job economy, inventory, and transaction audit trail
- Adds social graph (friends, marriage, children) and character chat
- Implements admin approval workflow for new registrations
- Adds hospital admission system for traffic accidents
- Includes comprehensive feature tests and world seeders
2026-10-17 21:46:23 -03:00

35 lines
752 B
PHP
Executable File

<?php
namespace Database\Factories;
use App\Models\City;
use Illuminate\Database\Eloquent\Factories\Factory;
use Illuminate\Support\Str;
/**
* @extends Factory<City>
*/
class CityFactory extends Factory
{
/**
* Define the model's default state.
*
* @return array<string, mixed>
*/
public function definition(): array
{
$name = fake()->unique()->city();
return [
'name' => $name,
'slug' => Str::slug($name).'-'.fake()->unique()->numberBetween(1, 9999),
'bounds_min_x' => -80,
'bounds_max_x' => 80,
'bounds_min_z' => -80,
'bounds_max_z' => 80,
'is_active' => false,
'expansions' => 0,
];
}
}