Skip to content
Brass Orrery

Orrery Terrain · OrreryTerrain module · member function

UOrreryTerrainEditPolicy::

CanChangeFeature

Experimental

Whether Controller may replace or remove an existing feature: the owner check, asked before CanEdit.

Declaration

UFUNCTION(BlueprintNativeEvent, BlueprintCallable, Category="Orrery|Terrain|Net")
bool CanChangeFeature(APlayerController* Controller, EOrreryTerrainEditKind Kind, const FOrreryTerrainFeatureEditContext& Feature) const;
Header
#include "Net/OrreryTerrainEditPolicy.h"
Module
PublicDependencyModuleNames.Add("OrreryTerrain"); in your module’s Build.cs.
Stability
Experimental: supported, may change in a minor version, with a changelog line.
Thread
Game thread, on the server only; called once per brush step, so keep it cheap. (the rule of UOrreryTerrainEditPolicy)
Blueprint
Overridden in a Blueprint (My Blueprint, Functions, Override); no node of its own.

Description

The default is IsOwnFeature: a player changes only the features its own requests inserted. Override it to widen the rule (an admin, a team sharing an OwnerDomain) or to narrow it; with no policy set the server applies IsOwnFeature itself.

Parameters

NameTypeDefaultMeaning
ControllerAPlayerController*—

The requesting player's controller on the server; null when the link has none.

KindEOrreryTerrainEditKind—

CommitFeature for a Replace, RemoveFeature for a Remove.

Featureconst FOrreryTerrainFeatureEditContext&—

The feature named, its owner and author, its old and new bounds.

Returns

true to go on to CanEdit.