Hi. I am trying to create a behavior wherein the NPC will Lead the Player to a location (a Transform point in game). The NPC will only lead if the Player is within its range. If the Player goes out or range, then the NPC will Rotate and look towards a specific Direction (defined by a Transform...
Hi, I am trying to highlight the clicked grid with some image and then show the option to equip or unequip. while equip and unequip option are available the grid should be shown as highlighted and when its equipped the highlight of the grid should be disabled. I have tried many methods outside...
Hi. So we had purchased the Climbing Pack, and integrated it in our project. Everything was working fine. We setup the Player to climb a straight vertical ladder, which the Player climbed successfully. But there is a scenario where we require a Ladder a bit tilted (say 45 degrees inclined). Now...
Yes. It's working now. Thank you!
I just needed to tick the Stop on Task End option. Don't know how I missed that part.
Additionally I switched the Start Type of Rotate Towards & NavMesh Agent Movement abilities to Automatic again for smoother transition.
So we were creating an NPC Behavior where if Player goes near an NPC and interacts with it, then the NPC would rotate towards Player, and bark some random dialogues (using the Dialogue System). This is working perfectly, when the NPC is static (in Idle state).
But we require some of our NPCs to...
Yes, it worked! Thank you @Justin .
For those who come by this post this is the solution:
// Start is called before the first frame update
void Start()
{
//linkedGameObject - Player, CameraController or any object that activates/triggers the state.
//gameObject - The gameObject this...
Hi. We want our custom script to respond to a change in state. Like for example we have created a custom script and inherited it from StateBehavior, and created our custom preset which simply sets a boolean value to true, when the Aim state is active.
Now the problem is that when the Player...
We figured out the issue @Justin . Basically the rotation values were changing when we aim/un-aim, as you said. We found out that when you are using a Cinemachine Third Person View Type, when you aim, the Main Camera's Rotation value for X changes.
For Example:- Before aiming lets say the values...
Make sure you have Projectile Shooter at top in the Shooter Module Group, and Spawn Projectile also at the top in Projectile Module Group. Then assign the necessary values to the components, like the FirePoint for the First & Third Person in Projectile Shooter and Particle Projectile to the...
Hi @Justin . We took your point into consideration and edited the CinemachineViewType.cs script. We added some lines of code in the LookDirection function. And its working perfectly. The projectile now moves to the crosshair's direction & position.
We took the ThirdPerson.cs script as reference...
Hi @Cheo . Thanks for the suggestion. We already had the Fire In Look Source Direction bool set to True, yet still it is not working as intended. We tried setting the bool true/false and still get the same glitch. We even looked around other camera view types to see what's happening, and found...
Thank you @Cheo . That helped a lot. Now the projectiles are spawning. But now we ran into another problem.
When we shoot, the projectiles don't move forward relative to the crosshair, they move along an offset direction.
Basically projectiles should follow the crosshair's direction.
Here's a...
I am trying to shoot a projectile whenever I shoot using the assault rifle.
I had attached the "Spawn Projectile" module to the Projectile Modules Group. Assigned it projectile prefab, and all the necessary fields. Yet still the Projectile isn't spawning!
(Screenshot taken during gameplay)