Search Unity

Sidescrolling 2.5D Shooter - Support

Discussion in 'Assets and Asset Store' started by Mikael-H, Feb 6, 2016.

  1. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    Last edited: Mar 3, 2016
  2. TechSins

    TechSins

    Joined:
    Feb 16, 2015
    Posts:
    142
    Hey is there any tutorial on how to get cubiquity integrated into the scene?
     
  3. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    In the latest version I chose to include a package that you open in order to import all the Cubiquity stuff. All you need to do is double click it and the integration should be done. Use the Cubiquity demo scene as a starting point. If this doesn't work for you let me know and I'll send you a working copy.

    Let me know i this works for you!
     
    Last edited: Dec 11, 2016
  4. DreamEnder

    DreamEnder

    Joined:
    Apr 12, 2011
    Posts:
    191
    Hi. Would this work on mobile? Thanks.
     
  5. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    I have not tried it on mobile myself but there are no explicit techniques used that would not work on mobile in the basic scenes. The destructible terrain scenes would need dll's compiled for mobile platforms to work, I don't know if there are any yet. If you know your way around a c++ compiler you could probably compile the open source code yourself.

    Note that you'd need to create your own mobile controls. This should be fairly easy, the controls are very loosely coupled in code.
     
  6. Merih

    Merih

    Joined:
    May 12, 2015
    Posts:
    1
    Hello! Your framework looks great! Can I add moving objects like elevator or crates? Also I want to add dialogue box for character speech.
     
  7. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    Yes there is nothing preventing you to do so. If you want the AI to properly use your elevator that will need some thinking though, depending on your requirements. It currently uses extensions of a* pathfinding project to find a path and it can handle a changing environment as can be seen in the destructible voxels scene. You just need to tell it to update in a particular area. If you want more intelligent usage of elevators that is a bit harder...
     
    Merih likes this.
  8. Firlefanz73

    Firlefanz73

    Joined:
    Apr 2, 2015
    Posts:
    1,316
    Hello,

    I saw you are also experienced with UMA. Wouldn't it make sense to integrate UMA here?

    I will be finished with my Project in a few months. I am thinking about starting a new one soon and want to create a medieval Kind of "Rogue Legacy" 2.5D Action game.

    I would use UMA and melee weapons, but range weapons also like fireballs with a staff also. This here looks great!

    Maybe integrating UMA and melee weapons would be a good Suggestion? Knocking someone down for a Moment would be great also...
     
  9. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    UMA would absolutely make sense! I actually started on that path, I was going to make sort of an RPG part of this pack which got sidetracked into a much bigger project (not released) and which got sidetracked into an actual game. But it would be a lot of fun to get back to this and introduce UMA into it. Especially since I hear very good things about the latest version.

    You asking for it also builds a lot of motivation, so thanks! :)
     
  10. waseem2k

    waseem2k

    Joined:
    Jul 9, 2015
    Posts:
    1
    Hey Mikael,

    I'm having issues getting my ai to find a correct path using the "Grid Jump Graph". I'm using "Super Tilemap Editor" to create my levels which uses 2D Edge Colliders. I had to place a 3D collider in the scene at the bottom of the map that is the length of the entire map and set the Max Fly Height on the GridJumpGraph to match the depth. It scans the graph correctly and generally the path will stick to the ground but at certain points it will just find a direct path to the enemy.


    In the seeker if I ignore the flyable tag. It doesn't find a path at all. So this tells me the ai is simply using flight nodes to calculate paths. Is the Grid Jump Graph simply not suited for what I'm trying to achieve?

    UPDATE: Turns out GridJumpGraph was simply using 3D physics. Which is why I couldn't get it to work with my 2D colliders correctly. So I updated it a bit and got rid of Flyable and Digable nodes since I didn't need them. This is what my GridJumpGraph looks like now in case it helps anyone else.

    Code (CSharp):
    1. [JsonOptIn]
    2. public class GridJumpGraph : GridGraph {
    3.     [JsonMember]
    4.     public float maxJumpHeight;
    5.     [JsonMember]
    6.     public float maxDropHeight;
    7.  
    8.     [JsonMember]
    9.     public uint walkableTag = 1;
    10.     [JsonMember]
    11.     public uint jumpableTag = 2;
    12.  
    13.     public override void UpdateNodePositionCollision(GridNode node, int x, int z, bool resetPenalty = true)
    14.     {
    15.         base.UpdateNodePositionCollision(node, x, z, resetPenalty);
    16.  
    17.         if (!node.Walkable) return;
    18.  
    19.         float rayCastLength = maxJumpHeight;
    20.         float nearest = float.PositiveInfinity;
    21.         bool didHit = false;
    22.  
    23.         Vector2 dir = Vector2.down;
    24.         Vector2 ray = new Vector2(node.position.x / Int3.FloatPrecision, node.position.y / Int3.FloatPrecision);
    25.         RaycastHit2D hit = Physics2D.Raycast(ray, dir, rayCastLength, collision.mask);
    26.  
    27.         didHit |= hit;
    28.         nearest = Mathf.Min(nearest, hit.distance);
    29.  
    30.         dir = new Vector2(1f, -1f).normalized;
    31.         hit = Physics2D.Raycast(ray, dir, rayCastLength, collision.mask);
    32.         didHit |= hit && hit.normal.y > 0.1f;
    33.  
    34.         dir = new Vector2(-1f, -1f).normalized;
    35.         hit = Physics2D.Raycast(ray, dir, rayCastLength, collision.mask);
    36.         didHit |= hit && hit.normal.y > 0.1f;
    37.        
    38.         node.Walkable = didHit;
    39.  
    40.         node.WalkableErosion = node.Walkable;
    41.  
    42.         if (nearest <= maxJumpHeight && nearest > 1)
    43.             node.Tag = jumpableTag;
    44.         else
    45.             node.Tag = walkableTag;
    46.        
    47.  
    48.         if (resetPenalty)
    49.             node.Penalty = (uint)(nearest * 1000);
    50.     }
    51. }

    I had to use Sphere collider under Collision Testing because SuperTilemapEditor uses edge colliders but Ray should work fine for most situations.
     
    Last edited: Nov 3, 2017
    Mikael-H likes this.
  11. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    Hi,

    I've been travelling and didn't see your post until now. I am impressed you managed to reuse my pathfinder in a totally different scenario than I had ever thought of! Awesome work!

    If you have any more questions let me know, I'll try to be a bit faster to answer :)

    Good luck with your game, would like to see what you make :)
     
  12. TheNenet

    TheNenet

    Joined:
    Nov 4, 2017
    Posts:
    5
    Hi Mikael,

    I could not find the game with the destructible landscape that was advertized on asset store.
    Was it part of a previous release ?

    Regards

    Oliver
     
  13. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    No it should be in there. I'm currently travelling, will get back to you soon!

    EDIT:
    Look in Assets\VikingCrew\2.5D Sidescrolling Shooter\Integrations\Voxels
    Run Cubiquity voxel engine.unitypackage and all should be good. I'll make sure to update the manual to make this more clear
     
    Last edited: Dec 15, 2017
  14. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    I just noticed a critical bug introduced by a changed behaviour in Physics.IgnoreCollisions in later versions of Unity where now ignored collisions seem not to be reset when activating/deactivating an object any more. This made recycled pooled bullets harmless when fired at someone who had previously fired that bullet. Can't have harmless bullets! :)

    Anyway, bug is fixed (also fixed a pathfinding bug in 2D scene) and pushed to asset store. If someone needs the new package in a hurry and can't wait for asset store vetting process let me know and I'll email a download link.
     
  15. skarsnik1931

    skarsnik1931

    Joined:
    Jul 22, 2016
    Posts:
    1
    Hi Mikael,

    i just bought the asset and when i open the escene 3D, there are no cameras, no characters, no spawns when i push play button. Only the blue escenario. There are displayed two null references in that moment. im usingunity2017 version.
     
  16. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    You need to load two scenes, one logic scene (2D or 3D) and one level scene. You probably only loaded a level scene. Sorry for the confusion, I'll try to make this more clear for the next version! Thanks for pointing this out!
     
    felipemullen likes this.
  17. TechSins

    TechSins

    Joined:
    Feb 16, 2015
    Posts:
    142
    Hey @Mikael-H what is planned for the next update? and more new features??
     
  18. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    Well I am currently considering multiplayer or touch screen support. Not sure yet, though, so no promises... :)
     
  19. br20o0ly

    br20o0ly

    Joined:
    Aug 9, 2015
    Posts:
    18
    i'm so excited to the next update
     
  20. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    Happy to hear it, currently working on another asset of mine, Tycoon Terrain, to bring it up to speed and make sure it has a similar MVC architecture as the sidescroller. So it will take some time to get back to the sidescroller. What would you like to see the most in the next update?
     
  21. TechSins

    TechSins

    Joined:
    Feb 16, 2015
    Posts:
    142
    mobile controls and more weapons
     
    Mikael-H likes this.
  22. DageLV

    DageLV

    Joined:
    Feb 5, 2018
    Posts:
    17
    Hello.
    Im using FPSME asset to make 2.5d shooter, but i couldnt figure out how to make my guy spin 180°, when i aim behind it. Can i share parts from your asset with FPSME creator, so he could help me?
    Even more useful would be to know which part of the code makes the guy turn around.
     
  23. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    Sorry I didn't see this in time, I had a deadline at work so worked lots of overtime this week... I do not know anything in general about FPSME but if anyone needs to share any asset of mine with someone else for support reasons then of course that is ok.
     
  24. lzardo2012

    lzardo2012

    Joined:
    Apr 11, 2013
    Posts:
    80
    Hi

    I just acquired your asset and I´m having some trouble setting up my own character.

    I used the prefab Character 2D View Prefab to create my own and, in the demo scene it´s spawning it instead of the blue Ethan, the units even animate correctly and use the AI ato attack the read team, the problem is, I cannot control my own unit and the camera does not find it too (it remains in the initial position)

    I´m also having this error message:

    NullReferenceException: Object reference not set to an instance of an object
    VikingCrewTools.Sidescroller.Teams.TeamController.HandleTeammateGenerated (VikingCrewTools.Sidescroller.Characters.CharacterMainController teammate) (at Assets/VikingCrew/2.5D Sidescrolling Shooter/Scripts/Teams/TeamController.cs:175)
    VikingCrewTools.Sidescroller.Teams.TeamController.Spawn () (at Assets/VikingCrew/2.5D Sidescrolling Shooter/Scripts/Teams/TeamController.cs:141)
    VikingCrewTools.Sidescroller.Teams.TeamController+<ContinousSpawn>d__28.MoveNext () (at Assets/VikingCrew/2.5D Sidescrolling Shooter/Scripts/Teams/TeamController.cs:126)
    UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at C:/buildslave/unity/build/Runtime/Export/Coroutines.cs:17)
    UnityEngine.MonoBehaviour:StartCoroutine(IEnumerator)
    VikingCrewTools.Sidescroller.Teams.TeamController:Start() (at Assets/VikingCrew/2.5D Sidescrolling Shooter/Scripts/Teams/TeamController.cs:117)


    And, the manual seems to be from an older version of the asset so it´s not helping me either, for example, I cannot find the "Body Animator field anywhere nor even the Character Controller 2D script (I assume it was replaced by Movement Controller, but I could not find anything like this field.
     
  25. lzardo2012

    lzardo2012

    Joined:
    Apr 11, 2013
    Posts:
    80
    Oops, just found out, the manual in the asset is different form the one online

    Sorry, I´ll try this one instead.
     
  26. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    Oh, than I am sorry for misleading you! If you need any help then sugin the support email is the fastest way. Don't hesitate to let me know if you need more help!
     
  27. Aphelion78

    Aphelion78

    Joined:
    May 8, 2015
    Posts:
    8
    Hello,
    Just got this asset and I'm eager to sink my teeth into it but I'm getting a nasty error I can't figure out. *Ahem... In my best announcer voice* :

    There is no argument given that corresponds to the required formal parameter 'editCallback' of 'EditorGUILayoutx.TagField(string, int, Action)'
    error CS7036: Assets\VikingCrew\2.5D Sidescrolling Shooter\Scripts\Pathfinding\Editor\JumpGridGraphEditor.cs(36,52)

    Running Unity 2018.3
    Any ideas?

    Also... I'm embarrassed to admit this but I have no idea how to load two scenes at once. Never used additive mode before.
     
    Last edited: Apr 24, 2019
    Mikael-H likes this.
  28. Mikael-H

    Mikael-H

    Joined:
    Apr 26, 2013
    Posts:
    309
    In order to load two scenes you only need to drag the second one into the project hierarchy window. If this does not fix the issue for you contact me on the support mail and I'll help you out! :)