Devlog#4 - Controller Support and chargeshot rework
Hello Everyone, welcome back to another devlog for Sceptre of God
_____________________________________________________________________________________________________________________________________
Last time we talked about a lot of Ui changes and inventory reworks.
This week I want to touch up on 3 main additions :
- Partial Controller Support.
-Updated projectile code and chargeshot rework.
-Updated projectile impact VFX.
_____________________________________________________________________________________________________________________________________
Added XBOX game pad support for the character actions.
Now the Player will be able to move,jump ,shoot and pickup items using a controller. The UI controlling elements have not yet been added but that is the next thing that I am working on.
____________________________________________________________________________________________________________________________________
The projectile system has been updated.
Previously when the player would perform a charge shot they would have to use the right-click button and hold it down for a specific time. But instead of having 2 buttons for normal shot and charge shot, I combined them into one button.
The above enhanced action has 2 trigger conditions :
- when the button is released, this fires the normal projectile.
-when the button is held down for a specific time frame, this fires the chargeshot.
This is the initial part of the shoot code.
When the player presses the shoot button(left click for Keyboard/R2 for game pad), the elapsed seconds are calculated and if those exceed 0.8 seconds the charging will begin, however if the button is released before 2 seconds are up the charge will get negated and a regular projectile will be fired.
The charge functionality initializes the particle effects for the weapon charge to indicate that the weapon is charging and sets a timer or how long I want the charge to take. Once the timer is up it a ring will form around the weapon and a sound will trigger to the let the Player know that the charge is complete.
In this way I can use a singular button to handling the firing mechanic.
To simulate the AOE effect when the chargeshot explodes, I made a change in the base projectile class so when the projectile collides wuth something I fire a multi-trace objects node to ping the nearby objects and either apply damage or perform some other effect. The regular bullets was not given a large radius but the charge shot was given a decent radius.
*The projectile firing code was originally in the firstpersoncharacter blueprint but it has now been shifted to the weapon blueprint as it makes the most sense for the weapon to be handling the firing instead of the Player.
____________________________________________________________________________________________________________________________________
Updated impact effects for the projectiles
Before
After
____________________________________________________________________________________________________________________________________
If you found this interesting please donate by downloading the demo and choosing your price or you can donate at
Thank you very much for reading
Get Sceptre of God
Sceptre of God
A 3D fps exploration game
Status | In development |
Author | SwSG10 |
Genre | Shooter, Adventure |
Tags | 3D, Exploration, Fantasy, First-Person |
More posts
- Devlog #3 - UI additions and rework20 days ago
- Devlog #2 : UI rework and additions27 days ago
- Better UI system54 days ago
- Sceptre of God : Alpha Version released77 days ago
Leave a comment
Log in with itch.io to leave a comment.