Skip to content

Commit

Permalink
readme md
Browse files Browse the repository at this point in the history
  • Loading branch information
Xavrax committed Sep 22, 2023
1 parent 305bed8 commit e332adf
Showing 1 changed file with 52 additions and 0 deletions.
52 changes: 52 additions & 0 deletions unreal/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,58 @@

## Overview

Our SDK can be used together with [UnrealEngine](https://www.unrealengine.com/en-US).
It is **not** fully functional plugin but can be easly integrated into your project as a unreal module.

## How to setup

First of all you have to clone this repository inside the `<UnrealProject>/Source/` directory.
We recommend to place it inside the `ThirdParty` one (create it if no present).

After that you have to compile desired option of the SDK. You can simple do it as follow:
```sh
make -C <option> -f <architecture>.mk pubnub_<implementation>.a
```

for example:

```sh
make -C posix -f posix.mk pubnub_sync.a
```

After that you have to adjust `PubNubModule/PubNubModule.Build.cs` with selected options.
Just change `option`, `architecture` and `implementation` with the same values you used in compilation.

> Note that this step is temporary until we enchant our build system that is quite obsolete and need maintenance. We are aware of it.
In the end you have to import module in your your project as follow:

- `<UnrealProject>.Target.cs` and `<UnrealProject>Editor.Target.cs`
```cs
public class <UnrealProject>[Editor]Target : TargetRules
{
public <UnrealProject>[Editor]Target (TargetInfo Target) : base(Target)
{
//...
ExtraModuleNames.Add("PubNubModule");
}
}
```

- `<UnrealProject>.uproject`
```json5
{
//...
"Modules": [
//...
{
"Name": "PubNubModule",
"Type": "Runtime",
"LoadingPhase": "Default"
}
],
//...
}
```

Now generate the project files using your IDE and you're ready to go!

0 comments on commit e332adf

Please sign in to comment.