Search Unity

Unity John Lemon’s Haunted Jaunt: 3d Beginner Official Thread

Discussion in 'Community Learning & Teaching' started by Woolley_Kat, Apr 15, 2019.

  1. Fil04

    Fil04

    Joined:
    Aug 28, 2019
    Posts:
    1
    Hello,

    Im new to unity with a little bit of experience in C++ and python

    Im encountering an error where none of my endings are triggered, not the GameEnding gameObject or the gargoyles are recognising that I've been in there capsule collider. I haven't got to the ghosts yet but I got feeling that they wont work either, my code is a carbon copy of the tutorial so it is probably something in the inspector but I have no clue..

    I'm using Unity 2019.1.14f1 Personal if you need that and I've just finished Enemies, Part 1: Static Observers

    Thank you for any help...
     
    Last edited: Aug 28, 2019
    DRY1994 likes this.
  2. Burrito-Bob

    Burrito-Bob

    Joined:
    Aug 30, 2019
    Posts:
    1
    Thanks for this very nice tutorial.

    I am stuck at Enemies, Part 1, at the last step. Unity keeps saying:

    "Assets\Scripts\Observer.cs(33,13): error CS0246: The type or namespace name 'Raycasthit' could not be found (are you missing a using directive or an assembly reference?)"

    I doublechecked the scripts for typos, but found None so far.

    Can anybody help please?

    Thanks.

    Found the typo: 'RaycastHit', not 'Raycasthit'
     
    Last edited: Aug 30, 2019
  3. studio-3D

    studio-3D

    Joined:
    Sep 6, 2019
    Posts:
    1
    I've gotten up to Enemies Part 2, but I'm now getting an error ALL COMPILER ERRORS MUST BE FIXED BEFORE ENTERING PLAYMODE. Of course, I have no idea where to find the error. The last script said no errors, but there was no FINAL one to use/check. Any idea what I might do now (download completed?) thanks
     
  4. victorluccas

    victorluccas

    Joined:
    Sep 11, 2019
    Posts:
    1
    I feel like the second problem can't be fixed for some reason, but i would really like to understand why this is happening. Maybe weird interaction with physics?
     
  5. Ethanbuxton

    Ethanbuxton

    Joined:
    Sep 14, 2019
    Posts:
    2
    Did you find out how to solve??
     
  6. Harbinger-Czar

    Harbinger-Czar

    Joined:
    Jun 25, 2018
    Posts:
    7
    I'm having an issue where my PointOfView objects aren't moving with the ghost objects. How do I fix this?
     
  7. Valjuin

    Valjuin

    Joined:
    May 22, 2019
    Posts:
    180
    Did you drag the PointOfView Prefab onto the Ghost GameObject?
    upload_2019-9-16_18-9-57.png
     
  8. meadowc

    meadowc

    Joined:
    Sep 25, 2019
    Posts:
    1
    Have you resolved this problem.. I am having the identical problem.
     
  9. tialim

    tialim

    Joined:
    Sep 24, 2018
    Posts:
    1
    thaank you!
     
  10. unity_KxJVdVWa2dGFRQ

    unity_KxJVdVWa2dGFRQ

    Joined:
    Oct 15, 2019
    Posts:
    1
    i have a question. i am coming from ue4 so this is somewhat new for me. i am trying to learn the basics from unity but one question i have is how to add real gravity?. i mean as soon as you set "apply root motion" true john do not fall down in any way. i do not really mind but i am a person who do not like to work precise so i could run the gravity and when then player sees the character it is on the ground even if i put it above it in the editor. i am hoping for help.
     
  11. APSchmidt

    APSchmidt

    Joined:
    Aug 8, 2016
    Posts:
    3,458
    Hi,

    I'm beginning this project with Unity 2020.1. alpha.

    It's the best way I've found to test the new versions of Unity; I've done that already with the Ruby's Adventure: 2D beginner project and everything went fine. :)
     
  12. RedRecidivist

    RedRecidivist

    Joined:
    Nov 22, 2018
    Posts:
    7
    As others have said, this is a really great tutorial, thank you.

    In "Create a Trigger to Simulate the Gargoyle's Line of Sight", I'm finding that after following the instructions carefully, the transform position of my PointOfView GameObject is in the centre of the capsule collider, not at the end of it. I went through the steps twice. I'm guessing this could cause a bug later since the raycast will probably come from the wrong place.

    Maybe I missed something?

    Thanks again for this fantastic resource.

    Annotation 2019-11-13 214734.jpg
     
  13. APSchmidt

    APSchmidt

    Joined:
    Aug 8, 2016
    Posts:
    3,458
    Just above your scene view, change the "Center" button into "Pivot" and see what happens.
     
    RedRecidivist likes this.
  14. RedRecidivist

    RedRecidivist

    Joined:
    Nov 22, 2018
    Posts:
    7
    Oh! That's really interesting, and I understand. Thank you!
     
  15. RedRecidivist

    RedRecidivist

    Joined:
    Nov 22, 2018
    Posts:
    7
    Well, I finished the project, it build successfully on PC, and played fine. I wanted to see if it would build for Android, so I changed player to Android, changed the Android API version and renderer and it built fine. I thought "hmm, that's cool!" and then switched back to the PC player. I never changed any settings at all for the PC player from the point that it worked fine, but now it just gives me a grey screen with audio but no image when I build for PC. It still works fine in the editor.

    Bit of a shame after all that work, but at least I got to see it run properly once!
     
  16. Therhyno25

    Therhyno25

    Joined:
    Dec 2, 2015
    Posts:
    1
    There is something I don't understand from the tutorial, in the "Player Character: Part 2, in section
    13.Apply Movement and Rotation to your Character, it says :
    "The character has a fun Walk animation and it would be good to use the root motion for that. However, the animation doesn’t have any turning in it and if you tried to turn the Rigidbody in the Update method it might get overridden by the animation (which could lead to the character not turning when it should). "
    I thought the animation only affects the display of the character, but they say that the lack of turning there may over-ride my rotation(so I need to do it in a function called OnAnimatorMove. does the animation actually change values of the rigidbody? Thanks!
     
  17. ProjectRabbid

    ProjectRabbid

    Joined:
    Dec 1, 2019
    Posts:
    1
    I can't get the character to move.

    The warning says

    "Animator is not playing an AnimatorController "
     
  18. APSchmidt

    APSchmidt

    Joined:
    Aug 8, 2016
    Posts:
    3,458
    You skipped a step and forgot to add the controller to the animator.
     
  19. HernandoNJ

    HernandoNJ

    Joined:
    May 13, 2018
    Posts:
    8
    It is a great beginner course! It let me understand so many things about game development. Thank you very much! Great job!
     
  20. Glactus

    Glactus

    Joined:
    Dec 25, 2019
    Posts:
    1
    A bit late, but did you check so that the actual Observer script is assigned to the Ghost's PointOfView object in the Hierarchy? If not just drag and drop it from the Assets > Scripts > Observer to the Ghost Prefabs PointOfView!
     
  21. xiaolan706

    xiaolan706

    Joined:
    Jan 5, 2020
    Posts:
    1
    Hi Dan,

    I have the same issue as yours. Did you get any solution?

    Thanks,
    Jin
     
  22. scotty417

    scotty417

    Joined:
    Jan 25, 2020
    Posts:
    3
    I'm running into problems here. I started out using the tutorial and everything went well until I got stuck.
    I decided to start all over again, and I've been having problems ever since.

    In the tutorial, I'm being shown that there's Rendering Mask, etc. My version isn't showing it.

    I am using Unity 2019.2.

    I enclosed a screenshot of a problem that I ultimately fixed and didn't know how to eliminate it from this post.

    Thanks,
    Scott
     

    Attached Files:

  23. scotty417

    scotty417

    Joined:
    Jan 25, 2020
    Posts:
    3
    I'm not worried about the above problem anymore. My new problem is in Animation. I have done everything to get John Lemon animated. My problem is that I'm supposed to hit the play button and I can move him around. I try to click the play button, but it doesn't stay depressed. I've looked at the script and it's exactly like they show it.
     
  24. scotty417

    scotty417

    Joined:
    Jan 25, 2020
    Posts:
    3
    Never mind. I'm being an idiot. It's amazing what happens if you check your code more than once.
     
  25. xiao_pi

    xiao_pi

    Joined:
    Jan 31, 2020
    Posts:
    1
    I tried this tutorial, but the GameEnding didn't work. I played the game, when I ran into the ghost, the game didn't end. Dose anyone have answer for that? Thanks in advance.
     
  26. loop67

    loop67

    Joined:
    Feb 4, 2020
    Posts:
    1
    Hello, i encountered a problem at part 1, 11.Make your Character React to Physics, when i add rigidbody, instead of falling a short distance and stopping, the character falls a short distance and starts floating upwards. And after changingthe update mode from normal to animate physics, it doesn't even fall, just the idle animation plays. I couldn't figure out what causes this. My current version is 2018.4.16f1.
     
    Last edited: Feb 5, 2020
  27. Tigersong

    Tigersong

    Joined:
    Aug 11, 2014
    Posts:
    52
    I know this project is supposed to be for Unity 2019.1; fair enough. But what changed? I have 2019.3 and each time I get errors from the package com.unity.package-manager-ui, which is absent. Also, why does a single-player project include the Multiplayer package?
     
  28. rbaxter_unity

    rbaxter_unity

    Joined:
    Feb 12, 2020
    Posts:
    2
    I've completed everything up to the Build, Run, Distribute step, but I have an issue with my ghosts. The first one moves back and forth just fine between the waypoints, but the others keep getting stuck, and I get this error:

    IndexOutOfRangeException: Index was outside the bounds of the array.
    WaypointPatrol.Update () (at Assets/Scripts/WaypointPatrol.cs:25)

    I'm not sure what I can do about this. Please help if you can. Thanks!
     
  29. rbaxter_unity

    rbaxter_unity

    Joined:
    Feb 12, 2020
    Posts:
    2
    Nevermind, it was literally as simple of fixing a misplaced end parenthesis. Remember to always double-check your code, kids!
     
  30. Tigersong

    Tigersong

    Joined:
    Aug 11, 2014
    Posts:
    52
    I've got in error in Observer: "An object reference is required for the non-static field, method, or property 'GameEnding.CaughtPlayer()'".

    Code (CSharp):
    1. if (Physics.Raycast(ray, out raycastHit))
    2.             {
    3.                 if (raycastHit.collider.transform == player)
    4.                 {
    5.                     GameEnding.CaughtPlayer();
    6.                 }
    7.             }
    I also notice a blank field in the Inspector called "Game Ending"; that probably has something to do with it.
     
  31. QingQingYe

    QingQingYe

    Joined:
    May 29, 2019
    Posts:
    1

    I encountered the same problem, and I discovered that I add the script to the 'JohnLemon' inside the real 'JohnLemon' GameObject (remember that inside the 'JohnLemon' GameObject, there are another 'JohnLemon' and the 'Root'). That's the reason why it can't find the Animator object (because the Animator belongs to the 'outside' JohnLemon).

    If you drag the script to the scene, this situation is likely to happen.

    Hope this helps~
     
  32. 860000023

    860000023

    Joined:
    Jun 2, 2015
    Posts:
    1
    Hello everyone. I encountered a problem in Tutorial 6. When I create a UI. The image is not in the position indicated by the Rectangle tool. But I cannot find the Effects button. I'm unity in 2019.3. Can someone help me
     
  33. PKgamedesign

    PKgamedesign

    Joined:
    Tuesday
    Posts:
    1
    Hi,
    I've got stuck in tutorial 7 (Enemies, Part 1: Static Observers).
    I have checked my code several times and can't see the fault but when I go to Unity it tells me there's a compiler error.
    I'm unable to drag the PointOfView GameObject onto the Inspector.
    Any help much appreciated, thanks so much, Kayla

    Assets\Scripts\Observer.cs(22,14): error CS0111: Type 'Observer' already defines a member called 'OnTriggerEnter' with the same parameter types
    I am assuming it is the game object issue on John Lemon, but I cannot figure out how to fix it. Anyone know how to fix this
     

    Attached Files:

    Last edited: Apr 7, 2020 at 9:58 PM
  34. Valjuin

    Valjuin

    Joined:
    May 22, 2019
    Posts:
    180
    Observer script - Line 22
    You copied and pasted the OnTriggerEnter method and changed true to false but you didn’t change Enter to Exit.
     
unityunity