uinit snippets
Hey guys ! Just wanted to let you know that I need to run some maintenance on the website because of the recent domain name changes from netlify. So, some pages will appear like this for a few days... but guess what's coming new to the pages ? A Dark theme switch !!!
Snippets under uinit namespace are used to initialize components and some select variable types. It might take some getting used to, but the generated code should always properly initialize the comps/variables for you.
For example, the following sight config component :
$1 = CreateDefaultSubobject<UAISenseConfig_Sight>("Sight Config");
$1->SightRadius = 400.0f;
$1->LoseSightRadius = 500.0f;
$1->PeripheralVisionAngleDegrees = 60.0f;
$1->SetMaxAge(5.0f);
$1->DetectionByAffiliation.bDetectEnemies = true;
$1->DetectionByAffiliation.bDetectFriendlies = true;
$1->DetectionByAffiliation.bDetectNeutrals = true;
GetPerceptionComponent()->SetDominantSense(*$1->GetSenseImplementation());
// Bind a function to be called when new pawns of above affilication are detected...
// GetPerceptionComponent()->OnPerceptionUpdated.AddDynamic(this, AAI_Bot_Controller::OnPawnDetected);
GetPerceptionComponent()->ConfigureSense(*SightConfig);
$0
Snippets in this namespace are used to reduce macro usage for UPROPERTY() declarations. There are three subclasses allowing the designer varying degrees of freedom at the editor.
I upload weekly and revamp bi-monthly. You can support my work at Patreon | Paypal | Marketplace | Gumroad