Adjust gravity via custom WorldSettings class

Hi, I’m trying to change the gravity with worldsettings. I have a custom worldsettings class with a few lines inside (below). I can’t manage to call globalGravityZ = 100; or worldGravityZ = 100;

I know it;s probably AWorldSettings:: or something different but I don’t know exactly.

.h

// Fill out your copyright notice in the Description page of Project Settings.

#pragma once

#include "CoreMinimal.h"
#include "GameFramework/WorldSettings.h"
#include "HBGWorldSettings.generated.h"

/**
 * 
 */
UCLASS()
class HGB_API AHBGWorldSettings : public AWorldSettings
{
	GENERATED_BODY()
		UFUNCTION(BlueprintCallable, Category = "HYBRIDGOLF|WorldSettings")
		static void ChangeGravity(int Grav);
		//AWorldSettings* MyWorldSetting = GetWorldSettings();

};

My .cpp is basically lines of tetsing (I’m new to unrealscript (if thats what it’s still called ahah) I came from Unity and pretty adapted to their way of things…

Anyways I found these IntelliSense fillers (in pic), can anyone help me utilize it? I basically want to be able to call a function from blueprint to tell the world settings gravity to be a certain value.

The int GRAVITY = is just a line i was testing to make sure it compiled.

Thanks for any help.

Nevermind, I will just explicitly set it through AddForce. It’s working great plus I have the ability to use overlap events etc to set the gravity to a certain number in certain areas on the map on certain actors, certain direction etc… Much easier and versatile!

EDIT: Added a pic for reference. The grounded bool is just begin and end overlap events setting grounded to true/false.