Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

AVK | Assault Vehicle Kit

Discussion in 'Assets and Asset Store' started by whebert, Feb 11, 2015.

  1. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Make sure all of the prefabs listed in the VehiclePrefabs behavior (which the waypoint AI spawner pulls from to spawn new vehicles when needed) are prefab references that reside within your project (Project tab) - not temporary prefabs in your scene (Hierarchy tab). If you use a prefab in the scene and it dies, when the spawner tries to use it as a reference to spawn a new vehicle with, you'll get that error message.

    That should fix that error and you should start seeing properly spawned vehicles.
     
    sahin09 likes this.
  2. sahin09

    sahin09

    Joined:
    Oct 29, 2015
    Posts:
    14
    Hey! No more errors when respawning fixed those thanks! Set up some test waypoints. Now, every time I kill them, it would respawn another one instantly in a random waypoint, or it would just keep randomly spawning the enemy AI, I have looked upon the example scene on AVK and its setup the same, am I missing something? It is supposed to spawn on the last nearest waypoint it was destroyed on, but instead it would randomly spawn clones, when the clone respawns, my controls which I control my Vehicle with would control the clones, and if I accelerate and turn they would instantly at the same time


    Thanks!

    EDIT:And when I die, it would respawn a clone of it self again even though its a seperate prefab?
    Also, they don't stick to the waypoints and follow them when they respawn, they seem to follow the player (me) and they respawn backwards most of the time as well.

    EDIT 2: Yep, although it can follow the waypoints at the start of the scene, it also lets me control it as well due to the RCC Car Controller which I cannot disable as if I do it will not follow the waypoints.
     
    Last edited: Feb 17, 2016
  3. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Yep, the WaypointAISpawner is coded to do that - chooses a random spawn point along the path as a spawn point. If you need it to spawn the last spawn point, you could save the position of the Entities as they die, say in a Queue<>, and use those to spawn new Entities with.

    Is the RCCVehicle script (the AVK to RCC bridge script) on the AI vehicles and enabled? If not, they would just respond to user input via the RCCCarControllerV2 script. Make sure to grab the latest RCCVehicle script as I made changes that should set the RCCCarControllerV2 to be externally controlled (via AIController flag) - just don't have the vehicle selected in the Editor or the RCCEditor script will reset it. And your AI vehicle prefabs need to be distinctly different than your player vehicle prefabs - they should contain the AggressivePathFollowerAI and an Enity (not PlayerEntity).
     
    sahin09 likes this.
  4. sahin09

    sahin09

    Joined:
    Oct 29, 2015
    Posts:
    14
    Thanks, I am changing the WaypointAISpawner to work with my game more right now and I made sure the RCCVehicle scripts were enabled on the vehicles as well. With the waypoints you set out, is there some kind of break zone which you also provide as well? something which the RCC already offers? Need to put breakzones otherwise they go flying or crashing everywhere lol.

    The AI seem to not be able to reverse either or they are not intelligent enough when they crash as they just accelerate forward and not reverse to carry onto the waypoints, could this be a major bug?

    EDIT: I have fixed it! I have bridged the RCCVehicle with the other RCC scripts, and used "namespace hebertsystems.AVK" on every single RCC script. Added over stuff from the aggressive AI Script to the RCCAIcontroller and it all works perfectly!
     
    Last edited: Feb 19, 2016
    whebert likes this.
  5. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    The provided driving AI in AVK was mostly intended as a demonstration to showcase an external driving system other than the player controlling the AVK vehicles. Their settings were tweaked for the AVK vehicles specifically, so they may need to be tweaked some for other vehicle packages. Overall, though, they were designed to be pretty simple and not very "smart" - just enough to show how easy it is to get them driving and shooting in the AVK demo scene where they work pretty well. Hopefully being simple they are easy to understand and augment where needed, which was the intent.

    I actually did find a bug in the AggressivePathFollowerAI script, line 142. That line should read:
    Code (CSharp):
    1. float throttle = maxThrottle;
    It sounds like you may have gotten things working by further integrating AVK and the RCC AI scripts, but another thing to try would be to make the above change and to modify the max and min throttle the AI can use on the vehicles, which should provide more stability and control.

    Awesome! Glad to hear you got things working as you need. Sounds like you're having fun at it too!
     
  6. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    Hello team herbert systems llc, i just bought your asset from unity asset store, but am having alot of issues. I tried to play the demo scene but it does work. I noticed its hanging, doesn't play smoothly. After sometime it will close and say unity not responding and my computer will freeze. i really like how you organised your codes but i just can play the demo scene on unity. Again i really need more vehicle and there corresponding destroyed version(just like assaultBuggy and assaultBuggy_destroyed) for my project. Can you provide it at the store. Finally as for my problem, am using unity 5.2.2f1
     
  7. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
  8. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Hey henkesky,

    AVK isn't yet fully compatible with Unity 5 - I'm working on fixing this when time permits. Mostly the wheeled vehicles (like the Assault Buggy) don't behave properly under Unity 5's new physics system (WheelCollider). Under Unity 4.x, AVK will operate as expected. Other aspects of AVK, like the modular controller systems for camera, steering, and aiming, are fine under Unity 5.

    As for your Unity session being unstable while playing AVK's demo scene, I read several forums concerning the stability of Unity 5.2 and people mentioning issues with certain bugs and the like (all unrelated to AVK). Please try 5.3.0 or later and see if those stability issues go away. Although that still won't fix the vehicles wonky behavior under Unity 5, you at least won't be crashing.

    You mentioned needing more vehicles for your game. I'm not sure if you've read much of this forum, but lately I've posted about several integrations between AVK and other vehicle physics packages. So if you happen to like certain aspects of AVK (the modular controller systems, the turret system, etc.) but need more vehicles than AVK currently offers (or vehicles that just work under Unity 5 at all while I'm fixin things for AVK :)), you can integrate other vehicle systems with AVK, put turrets on them and shoot up enemies, and control the external vehicles as if they were a part of AVK. I've posted several script "bridges" that provide the link between AVK and other systems. AVK & EVP demo here for an example.
     
  9. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    @whebert, thanks for your reply will try unity 4x and 5.3 versions. I understand that i can add turret system and controls to other vehicles, but what i want is a destroyed version of any specific vehicle i working with. I want for each vehicle am working with, a destroyed version that can replace the main one when health bar is finished. The destroyed version will just be a wreckage without tires, front screen (just the empty body)e.t.c and fire particles on it. But as i was typing this i figured out how to this, by creating another version of my vehicles with all it parts disabled, except the empty body and adding a fire particles to it. Finally do you have idea how i can add deformation/damages to my vehicles. and a steering like control for the mobile version. Thanks in advance
     
  10. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Yep, that is basically what I did with the destroyed version of the AVK vehicles.

    I didn't add this to AVK, but there are probably several ways to go about it. I would just modify the vehicles underlying mesh vertices using some weighted vector based on the force and proximity to the point of impact. There are probably a couple of forum discussions on the details of how to go about that. And likely some Unity assets with plug and play solutions as well.

    As for the mobile controls, you should be able to plop in touch sensitive scripts for the camera, steering and aiming systems into AVK's modular system. It would depend on how exactly you want the mobile controls to work, of course, but the system was designed to be fairly simple and easy to modify/augment.
     
  11. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    @whebert thanks i have gotten unity 4.70 and tested it. Its working(the directions) but i cant seem to fire rockets or shoot. I even searched for it in the codes but cant find the button. Please can you help me with this.
     
  12. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Hey henkesky,

    I need a little more information. Are you playing the DesertDemo scene? That should just work out of the box and you should be able to drive & shoot just by playing the scene.

    If you are building a scene from scratch, or possibly integrating another vehicle package, than you may need to make sure some things are setup in your scene. To take player input (like keyboard and mouse and shooting primary/secondary button clicks) and send it to the vehicle and turrets, you need to use the provided PlayerDriverCameraRig prefab. This prefab takes the player input and sends it to the player's vehicle and any turrets on the vehicle.

    If you are using one of the player AVK vehicle prefabs (like AssaultBuggyPlayer or RollerBotPlayer), you should be good-to-go as either should work out of the box too.

    If you are building a vehicle and adding a turret to it, like the GunRocketTurret prefab, then ensure it is setup correctly too to troubleshoot the problem. Go down the hierarchy of the turret to the Weapon objects (PrimaryWeapon & SecondaryWeapn). Make sure they have a projectile prefab selected for the "Projectile" property - should be Bullet and Rocket for the projectiles. Also, you can tell each weapon what Type of weapon they are, either primary or secondary weapon. Note: The GunRocketTurret prefab file in the Project had an issue on the secondary weapon where it was assigned as Primary Type, should be Secondary. The GunRocketTurret prefab attached to the AssaultBuggyPlayer is setup correctly - you can copy it from there too if you prefer.
     
  13. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    @whebert Yes am playing the desertDemo scene. Which button am i suppose to use to fire rocket. I can only drive around. I also created a new scene, added PlayerDriverCameraRig prefab to the scene, drag and dropped assaultBuggyPlayer not assaultBuggyAi to the scene but the control wouldn't work(the directions and shooting) i can only hear the assaultBuggyPlayer audio. Which script contains the directional control and rocket firing?
     
  14. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    Again the controls should have been independent of the scene. It should be attached directly to the vehicles(assaulbuggy and rollerBot). Without asking no one would have know is linked to PlayerDriverCameraRig prefab. Kind of makes things difficult to figure out. Again does the project contain a kind of game manager, cant find any like that being described in the pdf documentation
     
  15. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Primary weapon fire is the left mouse button, secondary fire is the right mouse button. Hit the 'H' key when playing the DesertDemo scene for a help menu listing the keyboard/mouse controls as well as the Xbox gamepad controls. I list the H key and help menu on the web demo - looks like I forgot to put it in the PDF document as well, will add that.

    The controls are independent of the scene, but do need something like the PlayerDriverCameraRig to utilize the camera/steering/aiming controls and to send player input to the vehicles and turrets. The reason the vehicles don't have input control scripts attached directly is that this is how AVK is designed. The vehicles and turrets are themselves just modular systems that receive external input to tell them what to do - whether that input comes from a player or AI.

    With this type of setup you could potentially have multiple player vehicles in the scene but only one is considered the player's active vehicle and thus receives input. If each vehicle had input scripts attached directly, then all the vehicles would respond to driving input at the same time - as I've seen in other vehicle packages.

    I like this type of abstraction between a vehicle (and turret), which should just respond to external input, and the control system that is operating it (whether a player or AI).
     
    Last edited: Mar 8, 2016
  16. sahin09

    sahin09

    Joined:
    Oct 29, 2015
    Posts:
    14
    Hey, I have not been active that lately but thats due to being extremely busy. I am trying to bridge and work your scripts with the Race Game Template. I abandoned the RCC so I am using the Car Controller which comes with the Race Game Template. Any help on how to get it work? thanks
     
  17. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Hey sahin09,

    I'm not familiar with the Race Game Template, but I would think you could use the RCC bridge script as a guide and try to do similar things with the vehicle controller in RGT. Try to figure out how to apply throttle, steering angle input, braking, etc. to the new controller and make the appropriate changes in the script. Hopefully RGT's vehicle controllers were designed so they can be externally controlled fairly easily. If not, and you have source code, the necessary changes can always be made.
     
  18. sahin09

    sahin09

    Joined:
    Oct 29, 2015
    Posts:
    14
    Thanks for the quick prompt reply as usual whebert. I managed to get it working kinda, but for some reason the turret keeps auto aiming at stuff it self, I do not understand what is causing this issue!

    EDIT: It is definitely something to do with the camera. I am using the camera in his template as its needed for loading the vehicles to the scene ect. The camera itself is customized to switch through another view. Seems like the camera is interfering with the aim of the turret thus im getting only less than 25% control of the turret.. Any possible solutions?
     
    Last edited: Mar 12, 2016
  19. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Hmm, that's odd. So you have the PlayerDriverCameraRig prefab in the scene, and there are Aiming controllers active? Which aiming controller are you trying to use, Camera Aiming?

    If RGT's camera is also in the scene, yes, that sounds like it would interfere with AVK's system. If RGT's camera has some script on it to load/initialize aspects of the scene, you could potentially move that script off a camera and put it on some other object so that it is still in the scene and does its thing, just may not need to be on a camera.
     
  20. sahin09

    sahin09

    Joined:
    Oct 29, 2015
    Posts:
    14
    I use Manual Aiming (Screen Cursor) for the eye tracking. But as I said, it keeps aiming somewhere else and it is really annoying, but it would stop aiming elsewhere when I cycle through to the other view like 4x, it would start aiming 100% accurately again. I am definitely sure it is his camera
     
  21. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Is this the built in Manual Aiming (Screen Cursor) that comes with AVK, controlled by the mouse and/or gamepad controller? Or are you using your cool, modified aiming controller with the Tobii Eye tracking you spoke of previously?

    Is the aiming reticle being displayed on the screen for the aiming controller? Does the reticle move smoothly as you control it, or does it move around erratically as if controlled by something else? Does the turret seem to follow the aim point indicated by the reticle or does the turret seem to have a life of its own and not follow the reticle? Or is there no reticle? Maybe if you captured some video I could see what you mean - feel free to send a link to the support email address.
     
  22. sahin09

    sahin09

    Joined:
    Oct 29, 2015
    Posts:
    14
    I have sent you an email with the video.

    It is using the modified Manual Aiming (Screen Cursor) for Tobii Eye Tracking, which works normally with your AVK, but when used in conjunction with the RGT due to there being a different camera setup it is causing issues.

    The aiming reticle is being displayed and it moves smoothly as I control it. As you will see, the problem to me seems that the turret is not pointing at the direction which the car is pointing at if that makes sense, so the turret seems to follow the reticle but on the wrong side of what the car is driving towards?

    The video will give you a better idea.

    Thanks
     
  23. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Answered in email.
     
  24. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    Note i also noticed this in unity 4.7 s is not a unity 5x series bug
     
  25. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    The turret not following the reticle? From the DesertDemo scene directly, or from a modified scene with customizations? The AVK turrets in an unmodified DesertDemo scene should definitely follow the aim point indicated by the reticle. In a modified scene, especially with other camera systems in the scene other than AVK's, it is possible the AVK rig is performing the aiming raycast out a different camera than the one rendering the scene. But this would be just a setup/configuration issue.
     
  26. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    @whebert please i want to try something else. I just need the turretMount model and bullet shell. I tried to drag only the turretMount from the prefab to a new scene but is not working. Just send the model the model and the shell model to me to my email hiltonsoftwares@yahoo.com. If you want i can send you my purchase details. You can send your email if that is the case.
     
  27. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    Please also include the particle effect for explosion and audio sounds used
     
  28. henkesky

    henkesky

    Joined:
    May 23, 2015
    Posts:
    36
    @whebert please i want to try something else. I just need the turretMount model and bullet shell. I tried to drag only the turretMount from the prefab to a new scene but is not working. Just send the model the model and the shell model to me to my email. If you want i can send you my purchase details. You can send your email if that is the case.
     
  29. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    henkesky,

    I'm not entirely sure what you are needing. There is a GunRocketTurret prefab in the project under the Weapons folder. Are you needing just the model or the turret controller script as well (which is already attached to the prefab)? The bullet prefab is also in the project.

    The turret prefab can be dragged to the scene, like you mention, but won't receive input unless it is on a vehicle - AVK is expecting turrets to be on vehicles. The PlayerDriverCameraRig contains the main system that obtains input from the various controllers (camera, steering, aiming/firing) and sends that input to the vehicle and any attached turrets on that vehicle.

    Of course you could just bypass all of that and send turret input directly to any turret with some custom script and the turret should react accordingly. Just send it a TurretInput structure and the turret should do the rest, if that is what you need.
     
  30. ron-bohn

    ron-bohn

    Joined:
    Oct 5, 2015
    Posts:
    228
    Hello, I am using your asset as part of a mini-game in a larger project. I've put in around 20 hours with your asset and I am having serious difficulty with your asset compared to other controllers I have integrated into my game. I have a pause menu that has save/load etc (completely separate system works perfectly with the rest of my game aside from with your asset). Basically, when I press escape to bring up this pause menu. When I move the mouse, it breaks my camera from the vehicle. I'm using unity 5 and a custom mod of the rollerball player. There is some update that is happening within your scripts that is causing this and I am very frustrated with it. What is causing this? I've spent a lot of time trying to pick apart your asset and take all the stuff that I don't need...which is basically everything except for the core functionality. I've already done this, but you should make a "simple scene" with no menus etc like Edy's Vehicle Physics has (I saw that you are familiar with that so that's why I used that example). Your menus, etc are not useful to me really just get in the way. I know you are going for a "complete project" but it's really just a vehicle controller with a basic weapons/ai system. I have most everything disabled, I just wanted to point out that it was a huge headache doing so. Anyways, I've integrated my game with 5 other controllers and I don't have this issue with any of them. Your asset has a ton of potential, but I have found it it overly complex (trying to be a complete project) and difficult to integrate. But yeah, I'm hoping to use it in just a small part of my game. Please let me know if you have any idea what's breaking my pause menu. If I can get that figured out, then I can use your asset which = me being very happy with your product.
     
    Last edited: Mar 24, 2016
  31. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Hello ron bohn,

    Sorry to hear that you're having issues integrating AVK into your game.

    The AVK menus that you've disabled, are you referring to the Help menu you get when hitting 'H'? Are you also referring to any of the UI that shows health, shield, xp, and the current active camera, steering, or aiming controllers?

    Are you still using the PlayerInput.cs and the PlayerDriverCameraRig prefab? Are you using any of the camera, steering, or aiming controllers themselves, or are you using different camera controllers, etc. other than AVK's?

    If I knew exactly which parts of AVK are still active, I might have a better idea of what is going on.

    I'll take a guess, though. In an unmodified AVK DesertDemo scene, when you pause the game using the 'H' key and the built-in AVK help menu comes up, several things happen (MenuController.cs is what is doing this). First, to pause the game, the Time.timeScale is set to 0 so time freezes. Also, MenuController.cs sets the pauseGame flag within PlayerInput.cs to true so that PlayerInput doesn't report any camera movement, etc. while in a paused state.

    If you are still using PlayerInput.cs to read player input that AVK is looking at, it is possible one of the AVK controllers is still seeing player movement so is moving a camera. Again, not sure if you are using another camera controller or AVK's camera controller, but that is what I'm guessing is happening. And I'm not sure what you mean by "breaks my camera from the vehicle" except that the camera following/looking at the vehicle is moving when it shouldn't in the pause state? But if you are using any of the AVK camera controllers along with PlayerInput, but not MenuController which would set the pauseGame flag, than perhaps that might explain what you are seeing. Feel free to email me a video of what is going on if I didn't understand what you're seeing.

    Hope this helps.
     
  32. ron-bohn

    ron-bohn

    Joined:
    Oct 5, 2015
    Posts:
    228
    Thanks for your prompt response whebert! The information you provided was actually very helpful. I'm going to go try out a couple things now and let you know how it goes. If I still don't get it, then I will provide you with the more details on what I specifically have enabled. I'm pretty sure the menucontroller.cs is not being called and it sounds like that is most likely causing it.
     
  33. ron-bohn

    ron-bohn

    Joined:
    Oct 5, 2015
    Posts:
    228
    Hi whebert, your help/pause menu sets your controllers time scale to 0 just fine, but my pause menu (which also sets the time scale to 0) is not recognized somehow. You see, my pause menu also sets the timescale to 0 when it opens the menu that I need to pause your asset. My pause menu (and save/load/close menu/exit to title menu) pauses 4/4 of the other controllers I integrated into my game. I'm very worried, hopefully one of the game objects I have disabled is causing this. You can see everything I have disabled on your asset in the image below. I also disabled the sound script on the RollerBot Player (1) because I handle sound in a completely different way. That's it though, unless something is missing. Hopefully you can tell me :)

     
    Last edited: Mar 24, 2016
  34. ron-bohn

    ron-bohn

    Joined:
    Oct 5, 2015
    Posts:
    228
    Also, I want to clarify....when I say menus, I'm not referring to the XP/Health/Shield/crosshairs. Those are the core functionality UI and not menus. I don't need or want the AVK help menu, camera selections, etc.
     
  35. Astrobyte_

    Astrobyte_

    Joined:
    Jun 30, 2015
    Posts:
    6
    Any updates on when a version for Unity 5 is coming out? I REALLY want this to play around with and integrate into my game, but my game uses Unity 5. Do we have a estimated release date?
     
  36. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Just saw this - apparently I didn't get a notification email since ron bohn's post #132.

    I don't have a lot of time at the moment, was just checking the forum real quick - glad I did. I'll look into this in more depth later today.

    So it looks like AVK's Main Menu is still active, along with the MenuController inside PlayerInput object? But AVK's help menu only shows when/if you hit 'H', and your pause menu shows when you hit 'Esc', yes? If so, MenuController won't do any of the things it does when you hit 'Esc' for your game's pause screen - like setting timeScale and setting pauseGame to false in PlayerInput. Sounds like your pause script already sets timeScale, which is good, but doesn't set pauseGame on PlayerInput. I'd suggest deactivating AVK's MainMenu object, and deactivating the MenuController script on PlayerInput as well. Then just add the pause/unpause code from MenuController into your external pause system so that PlayerInput is put to rest during pause, which should stop any AVK cemeras from moving.

    @RTMdeveloping, no specific update yet. I am still working on things when I have time and the vehicle is working better and better - but still not quite where I want it unfortunately.
     
  37. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Also, when you bring up AVK's menu with 'H', does the pause work as you would expect - game freezes and no camera movement, correct? But when you bring up your pause menu with 'Esc', game freezes but camera still moves, yes? If so, like I mentioned, I think your pause menu script just needs to set the pauseGame flag on PlayerInput as well.
     
  38. ron-bohn

    ron-bohn

    Joined:
    Oct 5, 2015
    Posts:
    228
    "your pause menu script just needs to set the pauseGame flag on PlayerInput as well"

    could you please be more specific about this? What do you mean by a flag? Are you referring to a player input level?
     
  39. ron-bohn

    ron-bohn

    Joined:
    Oct 5, 2015
    Posts:
    228
    "But AVK's help menu only shows when/if you hit 'H', and your pause menu shows when you hit 'Esc', yes?" Yeah it's easy to set that to any key, but yes that is correct. There is nothing overly complicated or different about the set-up other than EXACTLY what I showed you in the picture.
     
  40. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    By flag, I just mean setting the boolean value of something. Booleans (bool in C#) are often referred to as flags.

    In this case, the pauseGame bool of the PlayerInput.cs script. So, here is an example of what your pause game script needs to do along with whatever else it does:

    Code (CSharp):
    1. using UnityEngine;
    2. using hebertsystems.AVK;
    3.  
    4. public class TestPause : MonoBehaviour
    5. {
    6.     public PlayerInput playerInput;
    7.     private bool pauseState = false;
    8.  
    9.     void Awake ()
    10.     {
    11.         // Obtain a reference to AVK's PlayerInput script if it isn't already set in the Inspector.
    12.         if (!playerInput) playerInput = FindObjectOfType<PlayerInput>();
    13.     }
    14.  
    15.     void Update ()
    16.     {
    17.         // Toggle the pause state when ESC is pressed.
    18.         if (Input.GetKeyDown(KeyCode.Escape))
    19.         {
    20.             // Toggle pause state flag
    21.             pauseState = !pauseState;
    22.  
    23.             // Pause game
    24.             if (pauseState)
    25.             {
    26.                 Time.timeScale = 0;
    27.                 if (playerInput) playerInput.pauseGame = true;
    28.             }
    29.             // Unpause game.
    30.             else
    31.             {
    32.                 Time.timeScale = 1;
    33.                 if (playerInput) playerInput.pauseGame = false;
    34.             }
    35.         }
    36.     }
    37. }
     
  41. workingman247

    workingman247

    Joined:
    Jul 25, 2015
    Posts:
    11
    Just inquiring as to a possible release date for a Unity5 compatible AVK. Thank you.
     
  42. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Hello workingman247. No specific date I'm afraid, but I hope to release the Unity5 compatible AVK this Summer.
     
    closetgeekshow likes this.
  43. unity5aspyr

    unity5aspyr

    Joined:
    Mar 11, 2016
    Posts:
    1
    Hi Whebert - where can we follow you to get news on the Unity5 update?

    Thanks!!
     
  44. workingman247

    workingman247

    Joined:
    Jul 25, 2015
    Posts:
    11
    For those of you interested, I made minor changes in the AI that stops enemies from attacking each other and fire only at objects tagged as Player...Simply use this version of the AggressivePathFollowerAI that uses an IF statement to determine if the target has a tag of Player
     

    Attached Files:

  45. Tecknowolf01

    Tecknowolf01

    Joined:
    Oct 31, 2012
    Posts:
    49
    So is this working with current versions of Unity or not? I like the asset but if its not fully working then i would wait till it is.
     
  46. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Not yet, Tecknowolf01. Planning to get the Unity 5 update out this Summer.
     
  47. jaelove

    jaelove

    Joined:
    Jul 5, 2012
    Posts:
    302
    I hope you can make it compatible with Unity 5 soon as I would really like to purchase it for my next project.
     
  48. Tecknowolf01

    Tecknowolf01

    Joined:
    Oct 31, 2012
    Posts:
    49
    Sounds good Whebert, I just purchased it and expect from what I have read that we can take care of it. I will post more as our product prototype takes shape! Now if only Randomation Vehicle Physics hadn't closed up :(
     
  49. workingman247

    workingman247

    Joined:
    Jul 25, 2015
    Posts:
    11
    Been working diligently on a game base around the AVK, and am wondering when a Unity 5 version will be released. I love the asset, and with enough work, have been able to integrate other assets into the project. Unfortunately, the sample is 104 MB zipped, so cannot be included here.
     
  50. whebert

    whebert

    Joined:
    Mar 9, 2013
    Posts:
    72
    Hey workingman247. Sorry for the delay in responding, I've been slightly off-grid for the holidays. :)

    Very cool to hear you are loving AVK and have had success in integrating other assets. Would love to see some screen shots.

    I'm still working on upgrading AVK to Unity 5 as time permits. I know I probably sound like a broken record, but hopefully soon. :)
     
    SecretStudio likes this.