Validation macros for checking null or invalid objects. Logs a warning with the function name and argument index when a check fails.
Macros
Name
Description
CDRYX_CHECK_INVALID
Check validity of arguments using a custom validation function. Uses this as log context.
CDRYX_CHECK_INVALID_STATIC
Same but with explicit log context object.
CDRYX_CHECK_INVALID_OBJECT
Check UObject validity (nullptr and IsValid). Uses this.
CDRYX_CHECK_INVALID_OBJECT_STATIC
Same with explicit log context.
// Check that myActor and myComponent are valid UObjects, return nullptr if not
CDRYX_CHECK_INVALID_OBJECT(2408140036, returnnullptr, {myActor, myComponent})
// Same but in a static context, providing explicit log context
CDRYX_CHECK_INVALID_OBJECT_STATIC(owner, 2308071929, returnnullptr, {clazz})
// Custom validation: check that a float array is not empty
CDRYX_CHECK_INVALID(float*, 2401010001, return, o !=nullptr, {myFloatPtr})
Functions
Name
Description
checkInvalid
Validate an array of objects using a custom predicate. Logs warning with function name and argument index on failure. Returns true if any invalid.