8,018
edits
Paradox-01 (talk | contribs) m (Cheat codes (notes)) |
Paradox-01 (talk | contribs) m (Cheat codes (notes)) |
||
Line 14: | Line 14: | ||
* create a png with transparent edges, import it | * create a png with transparent edges, import it | ||
* create a widget | * create a user widget, open it | ||
* drag and drop the mouse cursor asset into the widget designer | * drag and drop the mouse cursor asset into the widget designer | ||
* make it 32x32 in size 0, 0 in position | * make it 32x32 in size 0, 0 in position | ||
Line 69: | Line 69: | ||
===Cheat codes=== | ===Cheat codes=== | ||
Unreal has Cheat code class but that doesn't ship with cooked | Unreal has a Cheat code class but that doesn't ship with cooked games. | ||
: https://www.youtube.com/watch?v=hM_MPrEN7t8 | : https://www.youtube.com/watch?v=hM_MPrEN7t8 | ||
Also, to detect combinations of keys pressed ("shapeshifter", "lifeforever", etc.) we would have to write our own code anyway. | Also, to detect combinations of keys pressed ("shapeshifter", "lifeforever", etc.) we would have to write our own code anyway. | ||
Instead of detecting each key press individually we can use the Any key event and then get key names, mostly capitalized letters for standard alphabet characters. | |||
The letters will be stored in a string which we will keep at a maximum length of the longest cheat. The string is then compared against an array of cheat codes. | |||
The string is cleared as soon as the game gets ''unpaused'' again. |
edits