Mighty RPG (Build jam submission)

Mighty RPG

Mighty RPG is the package that provides a solid but very flexible foundation for your own RPG game.
It is completely attribute-agnostic and allows you to define your own set of attributes, requirements, bonuses and levelling conditions. It is also capable to integrate with most of the official Unit 2 packages and some of the community-made ones.



  1. Add MRPG_User template to your User template
  2. Add MRPG_Player template to your Player template

Initial configuration:

You can find available attributes within MRPG_User > Setup > Available Character Attributes.
Example template introduces Dexterity, Strength, and Constitution, but it is entirely up to you what character attributes you want to use.
To add new character attribute to your game simply add mrpg_CharacterAttributeProperiesScript to the Available Character Attributes and define the id for your attribute and it’s label.

Id: is the identifier of your attribute which you will use later on to define item requirements/scaling bonuses.
Label: is the label used by the character sheet widget.

After you have defined your desired character attributes you can modify the script properties in the
MRPG_User > Setup

Persist Progress: When on the character progress will be saved in-between game sessions.

Use Manual Initial Point Distribution :
When on:
The character starts with each attribute being set to the value of Min Stat Distribution Value
Character receives spare points (Spare Points) that they can invest in any of the defined character attributes.
When off:
Initial attributes are assigned randomly based on the classical DND rule (best 3d6 out of four rolls)

Spare Points Per Level: Number of spare attribute points character receives on lvl up.

Baseline Value and Bonus Per Attribute Point will be described in the Property Modifiers and Bonuses section.

Leveling: Defines XP requirements for each character level


To make your RPG to work with the weapon you need to add MRPG_Item template to your weapon.
Currently only supports gun and axe packages that allow you to create and customise range and melee weapons.

This template allows you to define requirements the character has to meet in order to perform the attack action with this weapon.

Requirements are defined as a string of format {id}:{value} where id is the attribute identifier and value is the minimum attribute value requirement character has to meet (Example: str:12 - Character can not use this weapon unless they have at least 12 Strength)


In order to see the damage value the character does to the entity you have to add MRPG_DamageReceiver template to the entity and enable the Damage Enabled checkbox on this entity.

Property Modifiers and Bonuses:

Each attribute point invested could modify the numerical properties of the Player or Entity that they holding or any numerical properties of their scripts.

Attribute Bonuses:
Inside MRPG_User > Setup you can find two properties that are affecting bonus calculations:

Baseline Value: Every attribute below this value will penalize the character or their weapon if this attribute is used by the property modifier. Values above the baseline will act as bonuses.

Bonus Per Attribute Point: The bonus value per each attribute point. Note: The value will be rounded down.

with Baseline Value = 10 and Bonus Per Attribute Point = 0.5 we get the following bonuses chart

| Attribute | Bonus |
| 4-5       | -3    |
| 6-7       | -2    |
| 8-9       | -1    |
| 10-11     | 0     |
| 12-13     | 1     |
| 14-15     | 2     |
| 16-17     | 3     |  

Property Modifiers:
in order to start modifying properties of the MRPG_Item or MRPG_Player you need to add mrpg_PropertyModifierScript to the player or item. Both of those templates contain a convenient place for storing those modifiers (The Modifiers directory)

Modify Script Property: When off will modify the property of the entity otherwise modifies the property of specified script attached to this entity

Script: The scriptasset whose property has to be modified when Modify Script Property is on

Property Name: The name of the property to be modified

Has Dependant Property: Only visible when modifying script property. Sometimes to achieve the desired results we can not modify just a single property and we need to adjust some dependent property as well. A good example would be the maxHp of the Health package. If we only modify the maxHP the actual current health of the Player will remain unmodified which doesn’t feel like proper behaviour. If we specify the hp as the dependant property it will be adjusted proportionally to the maxHP value so users won’t need to heal after increasing their max health.

Base Value: Unmodified property value

Modifiers: List of the modifiers to be applied. Each modifier should be presented as the sting of the format “{id}:{bonus_multiplier}” (Where id is the id of the attribute and the multiplier is the multiplier of the attribute bonus)
The final formula for the property calculation will look like this:
base_value + modifier1 + modifier2...
In cases when you need to reduce the value instead of increasing it you could use a negative bonus multiplier. Example: When you want to reduce the spread of the gun depending on the attribute

Receiving XP:

In order to give the character the experience points, you need to call userEntity:SendToScripts("ReceiveExperience", xpValue)


  1. Improve the UI and allow for easier UI customisation
  2. Critical hit chance with d20 check
  3. Blueprint game and Video tutorials
  4. Requirement and d20 checks on triggers
  5. Integration with the Text Adventure Package by @ekelrock to allow different dialog options depending on the character attributes
  6. Entity visibility based on the character attributes (Trap detection)
  7. Skills and Spells
  8. Resistance and Defence
  9. More package integrations