Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

[WIP] Platformer Pro

Discussion in 'Works In Progress - Archive' started by JohnnyA, Jan 19, 2014.

  1. awejk

    awejk

    Joined:
    Oct 13, 2012
    Posts:
    32
    The rope is already implemented in platformer pro? Or it's planned in future release?
     
    Last edited: May 1, 2015
  2. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    I have a ropein my version but it wasn't ready for beta. Might get a chance to clean it up today. It will be in v1.0.
     
  3. The_Daleatron

    The_Daleatron

    Joined:
    Nov 26, 2013
    Posts:
    43
    Hello johnny havent been in around in a while busy with life, just checking out the beta today and wanted to say its come so much from the previous released version its really fantastic work. :)
     
  4. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
  5. awejk

    awejk

    Joined:
    Oct 13, 2012
    Posts:
    32
    excellent! Thank you. Glad to hear it. Sorry to bring this up, but last it's critical for me to push and pull. Maybe it too will be ready for the next beta?
     
  6. inthemilkywat

    inthemilkywat

    Joined:
    Dec 29, 2013
    Posts:
    56
    Looks really good from watching all the youtube videos. Was wondering if you could add a option for wall jumping that would make you jump away from the wall like in super meat boy.
     
  7. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Are you a mind reader? I just did a simple but quite nice 'push' this morning (it is already better than the one in 2DPC but has a few wrinkles to iron out). Pull is next on the list.

    @inthemilkywat thats already done. There's a wall jump movement based on SMB which:
    - sticks to the wall if you push against it
    - slides up the wall if you jump while against a wall
    - allows you to jump away from the wall (at different speeds if you hold run button)
    - also allows you to climb a wall by jumping up it
     
    superwendel likes this.
  8. awejk

    awejk

    Joined:
    Oct 13, 2012
    Posts:
    32
    it's good. I continue to wait for the rope, pull and push to integrate our project Platformer Pro instead of 2D platform controller. Your opinion: better to wait for a more stable release, or may be already starting to integrate? To begin with, we use the basic things, walking, jump, ropes, and push / pull boxes.
     
  9. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    @awejk its very unlikely core systems will be changing so you should be pretty safe to start the basics.
     
  10. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Hi guys, released beta 2.1.

    Beta Notes v0.2.1
    ---------------------------------------
    iTween removed
    - Several users described issues in previous projects with iTween performance, it was also causing issues in Unity 5.
    - Replaced with a simple custom tweening framework.

    Full Unity 5 Support
    - Same code base now works in Unity 5 and Unity 4.6.
    - How-to: Copy project folder, open, select upgrade. You should NOT be prompted to do the second API upgrade step.
    - May still be some issues as testing hasn't been extensive.

    New Features
    - Push movement. Push boxes.
    - Added some enemies to Alien sample including ability to kill by jumping on them or by head butting a brick which they are standing on.

    2.5D/3D
    - Still haven't cleaned up Hero2.5D Sample so its messy "around the edges".
    - New models and animations underway (again) but may not make first release.

    Bug Fixes
    - Not many as the U5/iTween upgrade took most of my time.
    - There are a couple marked as high priority in JIRA which should get addressed this week.
     
    aL0nerWolf likes this.
  11. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Good to hear the new implementations/improvements. I suppose this means the separate joystick aiming will be in a latter release though?
     
  12. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Yeah its in my JIRA (bug system) as a medium so there's still a couple of items ahead of it (couple of movement bugs), but nothing that should take too long.
     
  13. awejk

    awejk

    Joined:
    Oct 13, 2012
    Posts:
    32
    Thank you very much, JohnnyA. I tried it and I liked. I very hope, pull and rope will be in the next releases.
     
  14. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Just out of curiosity, am I right in believing that the override(attack) and it's animator controller allow you to interrupt other animation states under certain circumstances. If so that would be nifty. :) If not maybe you could put that on the list for a future tutorial. Thanks and keep up the great work btw.
     
  15. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Hey Johnny, I imported some assets from another project with plaformer pro. The only thing that doesn't seem to work is a script I have for mouse look rotation. I suspect it is the bit where I use:

    // subtracting the position of the player from the mouse position
    Vector3 difference = Camera.main.ScreenToWorldPoint (Input.mousePosition) - transform.position;
    difference.Normalize (); // normalizing the vector. Meaning that all the sum of the vector will be equal to 1

    float rotZ = Mathf.Atan2 (difference.y, difference.x) * Mathf.Rad2Deg; // find the angle in degrees
    transform.rotation = Quaternion.Euler (0f, 0f, rotZ + rotationOffset);

    It's suppose to cause an object to rotate pointing towards the mouse cursor (which it does in my original project file). When I try and use it in the project I have platformer pro on however it just rotates to the offset and sticks. Is there something specific in pro that would cause this?
     
  16. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    @Daniel311311 What are you rotating? I would be very hesitant to control the character with something other than a custom movement.

    More generally that script doesn't supply a z value to ScreenToWorldPoint, which means its assuming the world point is at a distance of 0 from the camera. Which basically means you would always be looking at the camera. Seems like a bug, you probably want to supply a z distance that is the distance between your "looking object" and the camera.
     
  17. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    I had the arm witch is a separate sprite parented to the character, enabling it to shoot directly at the cursor location. So it would rotate around its pivot which is centered on the shoulder of the character sprite.
     
  18. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Override in the animators refers to some way of overriding the whole animator. What it does depends on the animator. In the 2D animator it uses a mecanim override (for example in command bro he can shoot from any state as each state has a shoot override in a new animation controller). In 3D this could be a layer, which would allow (for example) a gun/sword holding state to be applied to the top of the body while the bottom still runs jump etc (this will be in one of the samples).

    In the attack system the "override movement" settings determine if attacks control movement in general. If this is true the character will hand over complete control to attack system. By default it just plays the animation state, but you could also extend to do special movements during attacks (like reducing gravity during air attacks).

    If it is false attacks set an animation override but DO NOT get control. The user can still run, jump, etc. Useful for fast shooting movements for example.

    To just set an animation state directly use: ForceAnimation(state, time)
     
  19. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    So change:

    Vector3 difference = Camera.main.ScreenToWorldPoint (Input.mousePosition) - transform.position;


    to

    Vector3 difference = Camera.main.ScreenToWorldPoint (new Vector3(Input.mousePosition.x, Input.mousePosition.y, dist)) - transform.position;

    Where dist is the distance between character and camera: Vector3.distance(Camera.main, character);


    (Note: not guaranteeing this will work in your setup but not setting a z is a common error in using ScreenToWorldPoint).
     
  20. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    (also feel free to send me a sample to poke at)
     
  21. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Beta users can now get the next version:

    -------------------------------------------------------------
    Release Notes - Platformer PRO - Beta - v0.2.2
    -------------------------------------------------------------
    Air Movement Variable
    - Fixed some movement bugs.
    - Added warnings and tips to the inspector which help you get better movement.

    Ground Movement Physics
    - Added a stick to slope option similar to digital (so you can turn off rotate to slope and still move smoothly up and down slopes).

    Loopy Hamster
    - Heaps of clean up of the slide behaviour that kicks in if you don't have enough speed to loop.

    Beat-em Up Sample
    - Fixed colliders.
    - Clean-up so various bits and pieces although there are still known bugs around enemy colliders.

    StandardInput
    - Interface now makes it much clearer that settings here are overridden by PlayerPreferences.
    - Editor allows you to load/save default settings to/from XML file.
    - Editor allows you to set the defaults to match current player preferences (so you can configure using UI system in game and then save as defaults).
    - Editor allows you to clear player prefs.

    PS @Daniel311311 I haven't forgot your update, this weekend hopefully.
     
  22. dragonikus

    dragonikus

    Joined:
    Sep 29, 2010
    Posts:
    4
    JohnnyA, hi! How to be a beta user?
    I already have license for 1.0 version...
     
    Last edited: May 16, 2015
  23. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Awesome! Thanks : ) Oh btw I got that camera look thing sorted out, thanks again.
     
  24. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Send a support request including asset store order number.
     
  25. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    @Daniel311311 - Second stick added to StandardInput (works the same as existing HorizontalAxis/Vertical Axis but called AltHorizontalAxis/AltVerticalAxis).

    Also added an aimer which supports this and a direction facer which shows how you can rotate to aiming direction.

    That said the Pixtroid character doesn't have enough animations to really support this, hopefully its clear enough until I get art to do a fully worked sample.
     
  26. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Awesome! No worries about the anims, I'm pretty familiar with the Pixtroid setup now so I think I can work mine in. Do I send a support request to get the latest build?
     
  27. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Haven't done a build yet, probably next weekend, but I guess if you send me an email I can send you the current state.
     
  28. awejk

    awejk

    Joined:
    Oct 13, 2012
    Posts:
    32
    I tried to built(0.2.2) iOS 7.1.1 (iphone 4s) and got exceptions during launching the game(SampleScene-CommandBro). I hope it will be fixed in future versions. BTH, game started anyway.

    ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) System.Reflection.EventInfo/AddEvent`2<PlatformerPro.Enemy, System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>>:invoke_void__this___Enemy_EventHandler`1<DamageInfoEventArgs> (PlatformerPro.Enemy,System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>)' while running with --aot-only.

    at System.Reflection.EventInfo.AddEventFrame[Enemy,EventHandler`1] (System.Reflection.AddEvent`2 addEvent, System.Object obj, System.Object dele) [0x00000] in <filename unknown>:0
    at System.Reflection.EventInfo.AddEventHandler (System.Object target, System.Delegate handler) [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.AddHandler () [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.OnEnable () [0x00000] in <filename unknown>:0

    (Filename: Line: -1)

    ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) System.Reflection.EventInfo/AddEvent`2<PlatformerPro.Enemy, System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>>:invoke_void__this___Enemy_EventHandler`1<DamageInfoEventArgs> (PlatformerPro.Enemy,System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>)' while running with --aot-only.

    at System.Reflection.EventInfo.AddEventFrame[Enemy,EventHandler`1] (System.Reflection.AddEvent`2 addEvent, System.Object obj, System.Object dele) [0x00000] in <filename unknown>:0
    at System.Reflection.EventInfo.AddEventHandler (System.Object target, System.Delegate handler) [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.AddHandler () [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.OnEnable () [0x00000] in <filename unknown>:0

    (Filename: Line: -1)

    ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) System.Reflection.EventInfo/AddEvent`2<PlatformerPro.CharacterHealth, System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>>:invoke_void__this___CharacterHealth_EventHandler`1<DamageInfoEventArgs> (PlatformerPro.CharacterHealth,System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>)' while running with --aot-only.

    at System.Reflection.EventInfo.AddEventFrame[CharacterHealth,EventHandler`1] (System.Reflection.AddEvent`2 addEvent, System.Object obj, System.Object dele) [0x00000] in <filename unknown>:0
    at System.Reflection.EventInfo.AddEventHandler (System.Object target, System.Delegate handler) [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.AddHandler () [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.OnEnable () [0x00000] in <filename unknown>:0

    (Filename: Line: -1)

    ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) System.Reflection.EventInfo/AddEvent`2<PlatformerPro.Enemy, System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>>:invoke_void__this___Enemy_EventHandler`1<DamageInfoEventArgs> (PlatformerPro.Enemy,System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>)' while running with --aot-only.

    at System.Reflection.EventInfo.AddEventFrame[Enemy,EventHandler`1] (System.Reflection.AddEvent`2 addEvent, System.Object obj, System.Object dele) [0x00000] in <filename unknown>:0
    at System.Reflection.EventInfo.AddEventHandler (System.Object target, System.Delegate handler) [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.AddHandler () [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.OnEnable () [0x00000] in <filename unknown>:0

    (Filename: Line: -1)

    ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) System.Reflection.EventInfo/AddEvent`2<PlatformerPro.DestructiblePlatform, System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>>:invoke_void__this___DestructiblePlatform_EventHandler`1<DamageInfoEventArgs> (PlatformerPro.DestructiblePlatform,System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>)' while running with --aot-only.

    at System.Reflection.EventInfo.AddEventFrame[DestructiblePlatform,EventHandler`1] (System.Reflection.AddEvent`2 addEvent, System.Object obj, System.Object dele) [0x00000] in <filename unknown>:0
    at System.Reflection.EventInfo.AddEventHandler (System.Object target, System.Delegate handler) [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.AddHandler () [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.OnEnable () [0x00000] in <filename unknown>:0

    (Filename: Line: -1)

    ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) System.Reflection.EventInfo/AddEvent`2<PlatformerPro.DestructiblePlatform, System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>>:invoke_void__this___DestructiblePlatform_EventHandler`1<DamageInfoEventArgs> (PlatformerPro.DestructiblePlatform,System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>)' while running with --aot-only.

    at System.Reflection.EventInfo.AddEventFrame[DestructiblePlatform,EventHandler`1] (System.Reflection.AddEvent`2 addEvent, System.Object obj, System.Object dele) [0x00000] in <filename unknown>:0
    at System.Reflection.EventInfo.AddEventHandler (System.Object target, System.Delegate handler) [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.AddHandler () [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.OnEnable () [0x00000] in <filename unknown>:0

    (Filename: Line: -1)

    ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) System.Reflection.EventInfo/AddEvent`2<PlatformerPro.Enemy, System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>>:invoke_void__this___Enemy_EventHandler`1<DamageInfoEventArgs> (PlatformerPro.Enemy,System.EventHandler`1<PlatformerPro.DamageInfoEventArgs>)' while running with --aot-only.

    at System.Reflection.EventInfo.AddEventFrame[Enemy,EventHandler`1] (System.Reflection.AddEvent`2 addEvent, System.Object obj, System.Object dele) [0x00000] in <filename unknown>:0
    at System.Reflection.EventInfo.AddEventHandler (System.Object target, System.Delegate handler) [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.AddHandler () [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.OnEnable () [0x00000] in <filename unknown>:0

    (Filename: Line: -1)

    ExecutionEngineException: Attempting to JIT compile method '(wrapper delegate-invoke) System.Reflection.EventInfo/AddEvent`2<PlatformerPro.Door, System.EventHandler`1<PlatformerPro.DoorEventArgs>>:invoke_void__this___Door_EventHandler`1<DoorEventArgs> (PlatformerPro.Door,System.EventHandler`1<PlatformerPro.DoorEventArgs>)' while running with --aot-only.

    at System.Reflection.EventInfo.AddEventFrame[Door,EventHandler`1] (System.Reflection.AddEvent`2 addEvent, System.Object obj, System.Object dele) [0x00000] in <filename unknown>:0
    at System.Reflection.EventInfo.AddEventHandler (System.Object target, System.Delegate handler) [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.AddHandler () [0x00000] in <filename unknown>:0
    at PlatformerPro.EventResponder.OnEnable () [0x00000] in <filename unknown>:0
     
  29. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    @awejk I haven't done a mobile build for some time, touch controls and mobile samples are in the MUST DO list.
     
  30. awejk

    awejk

    Joined:
    Oct 13, 2012
    Posts:
    32
    could not you add ParticleSystem, Transform and MonoBehaviour to MovementsVariables? It's very useful for private implementation movements. I added myself, but it is inconvenient when update to a new version. Each time check this file and replace. Thanks.
     
    Last edited: May 17, 2015
  31. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Movements are about moving the 'physics representation' of the character I'm not sure movement would be the right choice for actions which affect those things.

    Why would a particle system reference be needed in a movement? Maybe you are riding a particle system or something... can you describe your use cases?

    For those cases where you really do need external reference you can either:

    1. Use movements that don't use (only) movement variables, you can add your own extensions directly to your character.

    2. Add a class which lets you get these variables from the character:
    Code (csharp):
    1.  
    2. particleSystem = character.GetComponent<ParticleSystemReference>().ParticleSystem;
    3.  
    4. class particleSystemReference: Component { ... }
    5. // Obviously needs a bit more code but hopefully the intent is clear
    6.  

    Although this pattern might seem a bit contrived I think having these kinds of external entities easily accessible as movement variables will encourage bad movements which have animations, movement, effects, etc all lumped in one place (which will hurt flexibility, debugging, etc).

    - - - -
    EDIT: Not saying in your case these things don't make sense, its more from a framework view I need to be careful that I encourage people to write code (and separate their concerns) in the same way I have.
     
  32. awejk

    awejk

    Joined:
    Oct 13, 2012
    Posts:
    32
    Let's suppose, i'd like to implement the own DeathMovement for character.

    Code (CSharp):
    1. public class DeathMovement_Burst : DamageMovement {
    2.  
    3.        public ParticleSystem prefabBurst;
    4.  
    5.        private const int PrefabBurstIndex = 0;
    6.        private const int MovementVariableCount = 1;
    7.  
    8.        override public Movement Init(Character character, MovementVariable[] movementData) {
    9.                this.character = character;
    10.  
    11.                // Set variables
    12.                if (movementData != null && movementData.Length == MovementVariableCount) {
    13.                    prefabBurst = movementData[PrefabBurstIndex].ParticleSystemValue;
    14.                } else {
    15.                    Debug.LogError("Invalid movement data.");
    16.                }
    17.  
    18.                return this;
    19.            }
    20.  
    21.        public static MovementVariable[] DrawInspector(MovementVariable[] movementData, ref bool showDetails, Character target) {
    22.                if (movementData == null || movementData.Length != MovementVariableCount) {
    23.                    movementData = new MovementVariable[MovementVariableCount];
    24.                }
    25.  
    26.                // Prefab Burst
    27.                if (movementData[PrefabBurstIndex] == null) movementData[PrefabBurstIndex] = new MovementVariable();
    28.                movementData[PrefabBurstIndex].ParticleSystemValue = (ParticleSystem)EditorGUILayout.ObjectField(
    29.                    new GUIContent("Prefab Burst", "Particle System of burst, the character will burst like a small ball"),
    30.                    movementData[PrefabBurstIndex].ParticleSystemValue,
    31.                    typeof(ParticleSystem)
    32.                );
    33.                if (movementData[PrefabBurstIndex].FloatValue < 0) movementData[PrefabBurstIndex].FloatValue = 0.0f;
    34.  
    35.                return movementData;
    36.            }
    37. }
    Description from your code to MovementVariable
    "Data for a movement variable"
    Exactly, data for a movement, not only physics variables, all the variables necessary for the implementation of this movement, float value, int value, particlesystem value, transform and etc. In my case i'd like to explode character when in die, it means DeathMovement_Burst need ParticleSystem to explode the character.

    if i'm wrong, what is the best way in my case to implement burst with particlesystem? Some cases need a bit more variables like two or three particlesystem, sometimes link to MonoBehaviour(only for cache, I do not like to invoke GetComponent in runtime, especially if has a chance to cache).

    Create reference like ParticleSystemReference which contain all needed variables separate from MovementVariable?
     
    Last edited: May 18, 2015
  33. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    @awejk Actually thats exactly what I was trying to help people avoid.

    To play a particle system on death simply add an event responder to the character (or a child of the character). Listen to the CharacterHealth event Died and play a particle system as the response (you can add sound effects and things too).

    Screen Shot 2015-05-18 at 8.36.33 pm.png

    (The DamageType filter is so you can play different events based on damage type, for example if it was COLD damage you may want to play a blue ice particle system or animation override).

    To reiterate movements are for controlling the position and animation state of the character.

    PS I understand it might be hard to know about this without the documentation.

    PPS You can see these at 1:30 of the very old video:
     
    Last edited: May 18, 2015
  34. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    More generally the whole system is very much based around a strong separation of concerns. Each component does just one thing, ideally it does this one thing very well. What this means as a user is you will need to put a little work in to understanding the structure, but once you do you can very easily change one part of the system without affecting the other parts.

    The documentation will address this in several ways:

    1. Detailed doco of each class.
    2. High level discussions of structure and approaches.
    3. How-to's for specific behaviours and problems.
    4. Video tutorials of complete games.

    You can get a sense of what the documentation approach will be by reading the How Movement Works page, but obviously there is a lot to left to write.
     
  35. awejk

    awejk

    Joined:
    Oct 13, 2012
    Posts:
    32
    it seems need to create separate tutorial about EventResponder. I get it. Thanks.
     
  36. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Absolutely.
     
  37. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Hey Johnny, looking forward to the next beta release. I had a few questions. I was experimenting with different Air/Ground movement combos, and was wondering if there will be ( or already is) a way to mix or add together some that aren't available in the inspector. For instance adding the jetpack to a controller setup that already has jump. Also I like the physics movement (can make for some right challenging platforming) but it would be even sweeter if there was an option without air control. :)
     
  38. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    @Daniel311311 You can have multiple movements of any given type. If it is Air or Ground the last one in the list is considered the default, the others above them override them if they meet their WantsXControl conditions.

    For example see the rolling behaviour in CommandBro sample or Crouching behaviour in Pixtroid sample.

    In the case of the jetpack movement you could add that with a standard jump as the default. If your jetpack used fuel it would allow you to jump when you don't have fuel, and jetpack when you do. If you wanted to jump and then jetpack then there would need a little bit of code to ensure that you only start jet-packing when you are close to the peak of your jump. Something like this added to WantsAirControl():

    Code (csharp):
    1. if (character.Grounded || character.Velocity.y < SomeConstantValue) return false;

    PS Details of how the active movement is decided is in the existing online doco (one of the few things there).

    PPS I'll add that with a checkbox or something to control the behaviour in an upcoming release.

    PPPS Another alternative would be to use a different button for jetpack. I'll add that too.
     
    aL0nerWolf likes this.
  39. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Cool thanks Johnny! I think it would be cool to be able to set a different button, or even have it set where it only activates when a button is held. Like hold down button (activating jetpack) then control it with A button the same as in the jet pack example. Either way I would prefer to have both jetpack and regular jump available. I figured out the fuel system from the example and it works perfectly having the jump available after fuel runs out, I just want the player to be able to use the fuel sparingly. Thanks again.

    PS Hope that wasn't too picky. :)
     
  40. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Not picky at all, my aim is to be able to easily address all but the most esoteric of use cases. Once all the core features are finalised and v1.0 is released I'll focus on expanding the movement library.

    I'm actually thinking of having a bounty system so users can contribute movements and win cash as a nice way to grow the movement library.
     
  41. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Sounds like an awesome plan. I imagine it will result in quite a feature rich plugin. It will probably be sometime before I am proficient enough at C# (or coding in general) to contribute, but I look forward to seeing how it progresses. I have no shortages of ideas regarding stuff I like/would like though. ;) So I guess that is kind of a contribution.
     
  42. BigBite

    BigBite

    Joined:
    Feb 20, 2013
    Posts:
    108
    THIS. This is definitely the biggest reason I was exited when I saw the work you were doing on the rewrite. No offense, but trying to modify the original version was disconcerting, and it made me ultimately give. Mostly because I have just enough programming knowledge that if there are separation of concerns, I can usually modify them to my needs. I'm really happy I bought this product BTW, it's looking really good.
     
  43. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Hah no offence, 2DPC wasn't originally intended to be an asset I was just trying to get something quickly. By the time it got popular it felt too late to fix: better to rewrite and hence Platfomer PRO was born.
     
  44. zenGarden

    zenGarden

    Joined:
    Mar 30, 2013
    Posts:
    4,538
    Any news on the release date ?
     
  45. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    The two main things missing are mobile controls and builds (this weekend) and the pretty 2.5D sample (still blocked by art). I can drop the 2.5D sample and clean up Hero Sample but there are a few things that I really want to demonstrate in the 2.5D sample so this is worse case scenario.

    Add some time to do bug fixes and promo material and June is still doable, maybe even early June. May wont happen.

    If you have the beta you can pretty confidently start working from there, no major system changes will be coming.
     
  46. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    When you say builds, are you just referring to building for mobile, or just building for any platform?
     
  47. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    Well I'll be doing all builds, but its mobile builds that might require a bit of work. Just did my first Android build without issues (well I had to add a couple if #if statements). Touch controls will happen next.
     
  48. JohnnyA

    JohnnyA

    Joined:
    Apr 9, 2010
    Posts:
    5,041
    PS It was my fist Android build ever*, how easy is this S*** now! I remember doing my first iOS build 5-6 years ago and it was quite a pain!

    * Sadly for everyone I may waste some of my dev time porting all my iOS apps to Android now.
     
    aL0nerWolf likes this.
  49. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    46
    Haha Thanks for the warning. I would be building to pc and possibly mac ( but not any time soon ). From the sound of it there wasn't much to fix on that front. I've been going a little crazy with lighting, camera effects, and particles plus I know very little about optimization sooooo... mobile probably isn't good for me at this stage anyway. lol
     
  50. abatcat

    abatcat

    Joined:
    Feb 8, 2015
    Posts:
    70
    I really recommend you check out "Ori and the Blind Forest" it has some of the most smoothest movement behaviour
    out of any platformer I have played :D