Procedural Dungeon ⏵ Dungeon Generator Base ⏵ Get Random Room Data Weighted
Get Random Room Data Weighted
Class: Dungeon Generator Base
Category: Dungeon Generator
Description
Return a random RoomData from the weighted map provided.
For example: you have RoomA with weight 1 and RoomB with weight 2,
then RoomA has proba of 1/3 and RoomB 2/3 to be returned.
Node

C++
URoomData* GetRandomRoomDataWeighted(const TMap<URoomData*,int32>& RoomDataWeightedMap)
Inputs
| Name | Type | Description |
|---|---|---|
| In | Exec | |
| Target | Dungeon Generator Base Object Reference | |
| Room Data Weighted Map | Map of Room Data Object References to Integers |
Outputs
| Name | Type | Description |
|---|---|---|
| Out | Exec | |
| Return Value | Room Data Object Reference | Return a random RoomData from the weighted map provided. For example: you have RoomA with weight 1 and RoomB with weight 2, then RoomA has proba of 1/3 and RoomB 2/3 to be returned. |