Skip to content

Conversation

JasonAtClockwork
Copy link
Contributor

@JasonAtClockwork JasonAtClockwork commented Sep 29, 2025

Description of Changes

Closes: https://github.com/clockworklabs/SpacetimeDBPrivate/issues/2073

  • Expanded on the Unreal tutorial to create the Blueprint version, this uses :::server-cpp and :::server-blueprint which might not work yet when deploying.
  • Updated the server side code to use signed integers as discussed for both Rust + C# server modules.

API and ABI breaking changes

None

Expected complexity level and risk

1 - Documentation update, does update the server side

Testing

  • Manually tested both Rust + C# modules
  • Ran through all images and steps

@JasonAtClockwork
Copy link
Contributor Author

The Unreal documentation has been updated but I need to fix up the Unity documentation to use signed integers as well as fix up the Blackholio demos all to use signed integers.

@JasonAtClockwork JasonAtClockwork self-assigned this Sep 29, 2025
@JasonAtClockwork JasonAtClockwork added documentation Improvements or additions to documentation backward-compatible labels Sep 29, 2025
…m/clockworklabs/SpacetimeDb into jlarabie/blackholio-blueprint

# Conflicts:
#	demo/Blackholio/client-unreal/Source/client_unreal/Private/ModuleBindings/SpacetimeDBClient.g.cpp
#	demo/Blackholio/client-unreal/Source/client_unreal/Public/ModuleBindings/SpacetimeDBClient.g.h
#	demo/Blackholio/client-unreal/Source/client_unreal/Public/ModuleBindings/Types/CircleRecombineTimerType.g.h
#	demo/Blackholio/client-unreal/Source/client_unreal/Public/ModuleBindings/Types/CircleType.g.h
#	demo/Blackholio/client-unreal/Source/client_unreal/Public/ModuleBindings/Types/ConfigType.g.h
#	demo/Blackholio/client-unreal/Source/client_unreal/Public/ModuleBindings/Types/ConsumeEntityTimerType.g.h
#	demo/Blackholio/client-unreal/Source/client_unreal/Public/ModuleBindings/Types/EntityType.g.h
#	demo/Blackholio/client-unreal/Source/client_unreal/Public/ModuleBindings/Types/FoodType.g.h
#	demo/Blackholio/client-unreal/Source/client_unreal/Public/ModuleBindings/Types/PlayerType.g.h
@JasonAtClockwork
Copy link
Contributor Author

Ready for review but not pushed to staging yet as we'll need to discuss the images and the new ::: setup I've used

@JasonAtClockwork JasonAtClockwork marked this pull request as ready for review October 2, 2025 00:13

### Create the GameManager Actor

:::server-cpp
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The C++ and Blueprint documentation toggle all appear to use server-cpp and server-blueprint. This seems to imply the server either uses C++ or Blueprints to run, but contain instructions pertaining to the client. We likely want to change these to client-cpp and client-blueprint or possibly client-ucpp to indicate this is Unreal C++ and not general C++.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

100% I'm actually working on this right now as I've got it running locally and :::server-rust is competing with :::server-cpp as an example. Even changing to :::client-cpp isn't working so I'm diagnosing now!

@rekhoff
Copy link
Contributor

rekhoff commented Oct 2, 2025

If we are creating a Blueprint project, should we still generate the project as a C++ as shown here

![Create Blank Project](https://tmp-unreal-engine-tutorial-images.nyc3.digitaloceanspaces.com/part-1-01-create-project.png)
or should Blueprint be selected?
If we should still select C++ in the Project Defaults, we may want to have a note or something, so folks going down the Blueprint path, don't generate the project as a Blueprint project out of habit.

@JasonAtClockwork
Copy link
Contributor Author

JasonAtClockwork commented Oct 2, 2025

If we are creating a Blueprint project, should we still generate the project as a C++ as shown here

![Create Blank Project](https://tmp-unreal-engine-tutorial-images.nyc3.digitaloceanspaces.com/part-1-01-create-project.png)

or should Blueprint be selected?
If we should still select C++ in the Project Defaults, we may want to have a note or something, so folks going down the Blueprint path, don't generate the project as a Blueprint project out of habit.

Yes we will want all projects to start as C++, the reason is we're generating C++ code from the module into the project so might as well start them off on the right foot.

I'll make sure to get an extra note in there!

@bfops bfops added release-any To be landed in any release window no runtime change This change does not affect the final binaries labels Oct 6, 2025
@rekhoff
Copy link
Contributor

rekhoff commented Oct 7, 2025

Here are some items I found while reviewing:

In docs/docs/unreal/part-2.md

Add **Function** named `BuildConnection`:
Restart of Unreal was required for the SpacetimeDB Build node to become available.

In docs/docs/unreal/part-3.md

Open `BP_GameMode` and update to the following:
Wrong object, BP_GameMode -> BP_GameManager Should be:
Open BP_GameManager and update to the following:

- Add **Output** as `Diameer` with **Float** as the type.
Typo, Diameer -> Diameter. Should read:
- Add Output as Diameter with Float as the type.

Add **Function** named `GetGameManager` as follows:
Missing Blueprint Output setup task. Below screenshot should read:
- Add Output as GameManager with BP Game Manager as the type.

- Add **Input** as `Center` with **Vector** as the type.
Typo, Input -> Output. Should read:
- Add Output as Center with Vector as the type.

Add **Function** named `SpawnCircle` as follows:
Different node behavior from screenshot, Get Username function required Exec.
image
I put it's execution between Cast to WBP_Nameplate and Update Text in my example.
Note: Editor Version: 5.6.1-44394996+++UE5+Release-5.6

- Change **Variable Type** to **BP Game Manager -> Class Reference**
Typo, Class Reference -> Object Reference. Should read:
\ - Change Variable Type to BP Game Manager -> Object Reference

- Change **Variable Type** to **BP Player Pawn -> Class Reference**
Typo, Class Reference -> Object Reference. Should read:
\ - Change Variable Type to BP Player Pawn -> Object Reference

Add **Function** named `GetGameManager` as follows:
Missing Blueprint Output setup task. Below screenshot should read:
- Add Output as GameManager with BP Game Manager as the type.

Next, wire up `SetUsername` to update the Nameplate:
Unable to generate Bind Event to On Username Changed node.
When following the server-blueprint instructions, I don't see a SetUsername being created.

:::server-blueprint
Unclear the purpose of this blueprint section.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backward-compatible documentation Improvements or additions to documentation no runtime change This change does not affect the final binaries release-any To be landed in any release window

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants