Search Unity

Official Plant critter

Discussion in 'Open Projects' started by cirocontinisio, Nov 14, 2020.

  1. cirocontinisio

    cirocontinisio

    Joined:
    Jun 20, 2016
    Posts:
    884
    This is the official thread for the creation of the Plant critter. Take a look at the Hero card on the roadmap.

    The plant critter is a creature that the player stumbles into early in the game, as the first hostile encounter. Since it can't move, it doesn't pose much of a threat, but if the player gets too close, it will bite.

    As an idle, it could be interesting to just make it look like a normal plant (so no mouth) so that it blends with the scenery. Good for a small scare the first time the player encounters it.

    When defeated, it withers to the ground (for a while?).

    Since it's a character, we need:
    All these phases don't need to be tackled by the same person!

    You can get some more info on the Critters on the corresponding card on the game design wiki, or in the cards for the individual tasks linked above.

    And for art guidelines, you can refer to the Rock Critter already present in the project.

    PlantCritter2.jpg PlantCritter1.jpg
     
    Last edited: Nov 14, 2020
  2. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Hi there!

    I am giving a try to model this creature. Here is a first test with a basic texture.
    upload_2020-11-15_1-39-3.png

    upload_2020-11-15_1-27-28.png
     
    Last edited: Nov 15, 2020
    laczkyl likes this.
  3. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    An update from today. I have started to rig it and try to build some drafts animations.
    It is more or less the first time I am doing that, so nothing is at the level of the existing asset... So, if anyone has texturing/rigging/animation skills, they are more than welcome :)

    Iddle state test:
    upload_2020-11-16_1-2-54.png

    Warn state test:
    plant_critter_2.gif


    Attack test:
    plant_critter_1.gif
     
  4. Smurjo

    Smurjo

    Joined:
    Dec 25, 2019
    Posts:
    296
    @treivize That's definitely not bad. My first chicken I tried to animate was far worse (the lesson I learned is that the start position - the equivalent to a T-pose - should be a good compromize between to the extremes you want to reach - I had modelled the chicken with it's head up high and wanted it pick on the ground - and I couldn't make so much deformation of the mesh look natural. If I ever make a chicken again I will have it's head stuck forward, pretty much like the phoenix chick's T-pose).

    About your plant critter:
    Not sure whether are any tiny movements in the idle state, I don't see any. Typically you simulate some breathing, maybe opening the mounth just a tiny bit, increasing the x and z scale a tiny bit, and the top leave moving just a tiny bit . You might have some random - looking slight leaning forward/backward/sideways as well. Maybe you do have all that but it's to small to be recognized.

    I would also say the attack is extremly symmetric. Why not a small leaning left or right during the forward movement on top of it (the end position still the same)? And the left leave doing something little different from the right leave?

    I could help with the animations if you want me to, but think you can handle to improving the animations yourself. If you like I will help with the texture. I just wait for your pull request to be processed.
     
  5. cirocontinisio

    cirocontinisio

    Joined:
    Jun 20, 2016
    Posts:
    884
    Super cool!

    My feedback too:
    • I agree with @Smurjo that the attack animation is very symmetric.
    • For the idle, it's true in the card I mentioned that the plant was supposed to be in disguise. So if you implement this breathing animation, it would have to be very subtle... actually, it could be a bit of movement to the sides so it looks a bit like the wind on normal plants.
    • The correspondence to the concept is 90% there. I'd make the shape more round, bigger leaf on top, and have the smaller leaf too. Also those half-baked eyes in the texture could go, in my opinion. I can also give a pass on the texture, if needed!
     
    davejrodriguez likes this.
  6. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Hi @cirocontinisio and @Smurjo,

    I am really glad that globally it seems to meet some of your expectations for the plant critter! Again thanks for your feedback, it was my goals posting this early WIP here to get some directions.

    • The idle state was just an image in my previous post. I did not start creating an animation yet. Just the initial pose, I might have mentioned it. Indeed I was thinking also on something not that static for the idle. I was thinking about a little leaves movement, like reacting to the wind. for the breathing it is a good idea, given we want to keep the predation of this plant secret, I will try to make the whole head inflate/deflate slightly without opening the mouth. And also have the side movement as explained by @cirocontinisio.
    • Agree the attack is currently very mechanical, not something matching a living creature. I will try to enhance based on your comments. I might reach my skill limits here.
    • I will update the mesh also based on your comments, based on your comment, I am just realizing that indeed the small leaf on the head is missing! It is my mistake, the model contains one, but it is currently a planar shape, I need to extrude it to make it two-side rendered in Unity.
    Fainting is not started yet, but I was thinking about introducing another animation state: "Be Hit" state when our Hero successfully hits the plant.
     
    erizzoalbuquerque likes this.
  7. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Hi everyone!

    Thanks a lot for your encouragements!

    I reworked UV and the texturing first today.
    To improve the UV, the first attempt was splitting the head in 4 quarters which was not good to have seamless texturing, so I have changed for a cylinder projection and caps for the top and the bottom of the head:
    upload_2020-11-16_22-34-20.png upload_2020-11-16_22-36-5.png

    I tried to improve the animations as much as I have been able to do.

    Idle > WakeUp > Alert > Attack > Alert > Attack > Alert > Idle:

    plant_critter_3.gif

    @cirocontinisio, the plant has been "spherified" for its idle state :D
    Everything has been pushed in my current PR.
     
    Last edited: Nov 16, 2020
  8. Smurjo

    Smurjo

    Joined:
    Dec 25, 2019
    Posts:
    296
    It would be nice if he opens his eyes when attacking. Why else would he have them?
     
  9. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Hi @Smurj,

    It seems indeed that baking eyes in the texture was not the best idea, I was a bit too lazy at the beginning :p
    I corrected it at lunch time :)

    Here is the same animations with glowing eyes!
    plant_critter_4.gif

    Is it better like this?
     
    Smurjo likes this.
  10. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Hi carnivorous plant lovers!

    I have added additional animations to it! Again everything is pushed in the on-going PR. I am waiting for your feedback!

    plant_critter_5.gif
     
  11. laczkyl

    laczkyl

    Joined:
    Aug 23, 2018
    Posts:
    32
    I like the lack of eyes, all the famous carnivorous vegetables didnt have eyes. Like piranha plant and Audrey II.
    Really cool job Treivize!
     
    davejrodriguez and treivize like this.
  12. cirocontinisio

    cirocontinisio

    Joined:
    Jun 20, 2016
    Posts:
    884
    Yes, I would also remove the eyes and stick to the concept art!
     
  13. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Sure, indeed plants have no eyes, it makes them even more frightening. removing the eyes was an easy update.

    Here is a small demo with a proper animator:


    Again it is available in the PR
     
    itsLevi0sa and erizzoalbuquerque like this.
  14. cirocontinisio

    cirocontinisio

    Joined:
    Jun 20, 2016
    Posts:
    884
    Super cool :) I swear I'll get on the PR soon :)

    (in the meantime, I did a little tweet about it as part of this ongoing chain)
     
    treivize likes this.
  15. erizzoalbuquerque

    erizzoalbuquerque

    Joined:
    Jan 23, 2015
    Posts:
    50
    Hey! Really nice work! I have almost zero experience in 3d modeling and seeing this post is giving me a better understand of the whole process.

    I like the animations. But, in the Alert animation, I find the leaves animation could improve. Maybe all leaves could go outwards and inwards instead of forward and backwards (I have no idea if doing this is possible hehe)

    Really good result! It got me really interested in trying some 3d art
     
    cirocontinisio and itsLevi0sa like this.
  16. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    @cirocontinisio, thanks a lot! I am really glad to discover some of my contributions in your tweets! It is really motivating!

    @erizzoalbuquerque, thanks for your warm feedback! I have pushed an updated version of the alert animation, indeed the animation of the leaves on the side were not great
     
    erizzoalbuquerque likes this.
  17. danten66

    danten66

    Joined:
    Nov 25, 2020
    Posts:
    32
    Hi all, I am new to the project and I love what I see. I can not wait to see how I can learn and help out.

    @treivize - this is looking so great and I can not wait to learn a bit more about the workflow of getting a rigged and animated model into Unity. Am I correct that that you built that model in Blender?
     
    erizzoalbuquerque likes this.
  18. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Hi @danten66, welcome on board! I am glad you like what is going on!
    Indeed, I am not a pro in computer graphics, just hobbyist so I am using Blender/Gimp to do everything about 3d assets (modeling/texturing/rigging/animation). If you need help how to export things from Blender to Unity do not hesitate to ask
     
    erizzoalbuquerque and danten66 like this.
  19. danten66

    danten66

    Joined:
    Nov 25, 2020
    Posts:
    32
    Thanks for the (future,) help. I'll poke around a bit over the next few days and see what questions I come up with in the meantime and then look for a place to hop in to this exciting project.
     
    cirocontinisio likes this.
  20. cirocontinisio

    cirocontinisio

    Joined:
    Jun 20, 2016
    Posts:
    884
    treivize and danten66 like this.
  21. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    I am super happy the plant is there! And thanks a lot for the pieces of advice in the PR :) I will take care about properly naming my future meshes, promise!
     
    cirocontinisio and danten66 like this.
  22. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Now that this vegetal flesh is there, it is maybe ok to start giving him a soul!
    As already discussed a bit in State Machine topic, I have started to play with State Machine, the transition table, action and condition to wire the plant.

    Here is a schema summarizing what is going on here:
    upload_2020-11-30_14-21-47.png

    Most of the work is to create SO based on existing code from SM and Event Channels, but I have introduced some few scripts to support the interaction between the protagonist and the critter. Basically, I tried to write as less code as possible to achieve this initial behavior trying to use as much as possible the existing stack.

    The critter has 3 particular stable states:
    - Idle: The plant critter is just sleeping peacefully. The stable state after spawning and when there is no interaction with the protagonist
    - Alert: The protagonist is coming close to the plant who wake up and menace the roamer. This stable state is reached when receiving an event raised by a EnemyZoneColliderController which fires an event if the protagonist enters in the collider zone. If he left the zone another event is triggered and the critter is moving back to idle state.
    - Fighting: The protagonist is coming closer and is close enough to be bitten. Like Alert state, this state is reached when receiving an event from another EnemyZoneColliderController attached to a smaller collider.
    upload_2020-11-30_14-16-32.png

    EnemyZoneColliderController :

    - Raised a provided event in case the protagonist enter or exit the collider.
    upload_2020-11-30_14-12-9.png

    The new generic /simple condition script to listen to an event based on voidEventChanelSO:
    upload_2020-11-30_14-12-58.png

    A new StateActionSO to make the critter facing the protagonist when state Alert/Fighting is on going:
    upload_2020-11-30_14-14-3.png

    What do you think about this approach?
    Link to the PR: https://github.com/UnityTechnologies/open-project-1/pull/241
     
  23. erizzoalbuquerque

    erizzoalbuquerque

    Joined:
    Jan 23, 2015
    Posts:
    50
    Nice work. There are some weeks since I read the state machine source so I know I'm very outdated right now. They seem to be making excellent work. A lot of things to keep up with, but right now I'm busy with other things. As I'm not updated with the tools they're are creating I feel I can't help with this right now. But all the logic and Unity's code seems okay. The "LookAt" logic could lead to some weird behavior, but I saw on the PR that you're already fixing this. I will keep an eye on the PR. Really good work. I'm very impressed with how fast you keep updating new things hehe
     
    treivize likes this.
  24. treivize

    treivize

    Joined:
    Jan 27, 2016
    Posts:
    136
    Hi @deivsky, @cirocontinisio and @erizzoalbuquerque,

    I have reworked the way of implementing the Plant Critter based on your different comments. Here are the ones I have digested:
    - Why using EventChannelSO instead of UnityEvent?
    - FaceProtagonist Action -> FaceTarget Action
    - Personal thought: Today there is an implicit link between the object entering in the collider and the one used in the action to Face the target, I suppose it is the unique protagonist.

    So here are the changes, I could propose:
    First ZoneTriggerController based on UnityEvent convoying the object name (to be able to find it back somewhere else)
    upload_2020-12-2_9-55-54.png

    The event received condition for SM, is becoming a simple boolean holder. This one, I am not sure this is the right way of implementing it...
    upload_2020-12-2_10-10-26.png

    FaceProtagonist is changing to be a FaceTarget where the target is based on the gameObject name defined in SO.
    The idea is that it will be set thanks to UnityEvent<string> raised when entering in the colliders

    upload_2020-12-2_10-13-18.png

    Finally in the inspector, I am binding the SO in the ZoneTriggerController:
    upload_2020-12-2_10-15-12.png

    What do you think about this new approach?
     
  25. Amel-Unity

    Amel-Unity

    Unity Technologies

    Joined:
    Jan 30, 2020
    Posts:
    62
    Hi everyone,
    Reviving the plant critter thread!!
    One improvement we have thought of is to add an anticipation animation to the plant critter attack animation, similar to the slime critter.
    Currently we see the slime critter moving a bit backward before attacking as if it is loading the attack. We would like to do the same for the plant critter and perhaps make the critter move a bit more forward when it attacks to make a bit more aggressive and ''dangerous'' :) (eventually we will tweak the colliders to go with the new animation). Let us know if you are interested to work on this task, here is the link the Codecks task card.
     
    Last edited: Apr 29, 2021
    redcurry79 likes this.
  26. redcurry79

    redcurry79

    Joined:
    Oct 26, 2020
    Posts:
    36
    @Amel-Unity For some reason the Codecks link asks me to login.
     
  27. Amel-Unity

    Amel-Unity

    Unity Technologies

    Joined:
    Jan 30, 2020
    Posts:
    62
    Just updated the link, it should work now. Thanks for mentioning it :)
     
    redcurry79 likes this.
  28. aby_gamemaker

    aby_gamemaker

    Joined:
    Nov 5, 2020
    Posts:
    69
    Can we do it so that the plant critters main attack is sending roots from beneath the ground to attack the players?
     
  29. ramshorngames

    ramshorngames

    Joined:
    Oct 15, 2019
    Posts:
    1
    I took a stab at creating some anticipation before the attack animation. If it looks okay I can push up a pull request.
     

    Attached Files:

  30. Amel-Unity

    Amel-Unity

    Unity Technologies

    Joined:
    Jan 30, 2020
    Posts:
    62
    Hi @ramshorngames, thanks for proposing the animation, we can already see the anticipation better. I'd suggest to make it even more exaggerated so it leans back longer and the projection forward goes also a bit further. That would give more impact attacking (we will make the collider bigger to go with that later).