Hey

Couple of things if thats okay? sorry to be a pain!

I have gone through the shooter tutorial but still not fully understanding the Raycasting.

I have the following created a schematic

Settings 2nd problem GUI

I have menus etc set up in ORK, however since adding Makinom the menus seem to be using those and not the ones set in ORK. I have set up the plugin etc - is there a way to select which menus it uses?

I am getting the following error;

TypeLoadException: Could not load type 'ORKFramework.ControlBlockChanged' from assembly 'ORKMakinomConnectionPlugin'.
ORKFramework.PluginsSettings.OnInitializeORK ()
ORKFramework.ORK.Init (.ORKProjectAsset project)
ORKFramework.ORK..ctor (.ORKProjectAsset project)
ORKFramework.ORK.Initialize (.ORKProjectAsset project)
ORKFramework.Behaviours.GameStarter.Awake ()


Thanks :)
  • I guess you've forgotten to add some details or a screenshot of your schematic?
    Raycasting (in general) will send a ray/line from point A to point B and return the objects (with colliders) that where hit by it. In Makinom, you can set this up in different ways, e.g. by defining the points, by using a source object (point A) and send it into a direction (e.g. forward) and other options.

    Your error probably comes from using an outdated version of ORK. As the plugin page mentions, you need at least Makinom 1.0.2 and ORK 2.5.0.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Ah

    sorry! :)

    here are some screens

    image

    image

    image

    image

    I have added a tree with a box collider on it.

    It seems to never find the player even when nothing is obstructing view.

    I imagine I am missing something really simple :)

    Thanks
  • Yes, you're missing something :)
    You currently use the player's position as direction for the raycast, i.e. the ray is going somewhere completely different.

    Set Raycast Origin to Value Position, that way you can define the start and end position of the raycast.
    Since you can just use the position of a game object as a Vector3 value (position), you can select the camera (start position) and the player (end position).

    Also, you'll probably need to find multiple objects that are blocking the view, so you should enable Raycast All. In the Hit Game Object settings, select change type Set, otherwise you'll add more and more objects to the list instead of only using the currently hit objects.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • hehe figured I would be :)

    I have changed the above and it still seems to fail to find the player for some reason, not sure why..

    I have managed to get it working with triggers but think recasting would give better results.
  • Still struggling with this for some reason, I have tried changing settings and having a play but nothing seems to work.

    Really struggling to see what needs to be fixed.

    I have updated the settings you gave but it still cannot find the player, if I set Recast origin as screen then it finds the player but always finds it even when behind a building or tree.

    At this rate I'm gonna cut all the trees down haha
  • When you're using the tree layer for raycasting, your player would need to be on the tree layer to be found.
    But you don't actually want to find the player, you only want to find the trees in between - is that working?
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Ah - thanks,

    At work at the moment so will check tonight and no doubt will bug you again if still missing something :P

    Thanks for all the help so far and the patience, I really appreciate it!
  • Nope still not working.

    I have set the player prefab and child objects to have the same layer as the trees, I have also added the Camera into that layer as well.

    But not working

    Not sure if it's the settings I have on camera, got it set to execute on "start"


  • edited July 2015
    Well, at start, there probably is no player set yet ... either use a start delay time, or (what you'll most likely need for this kind of mechanic) use a tick machine to do this each frame.
    Post edited by gamingislove on
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Thanks,

    will try changing the Auto machine with a Tick machine and see if this works tonight. :)
  • I have got this sorted :P

    I would just like to thank GIL for all of the hardwork put in to get this resolved for me :P

    I just have a few improvements to make to give it a more polished look.

    if anyone would benefit from this, ill do some form of tutorial and stick it in the forum if it would help others?

    Thanks!
Sign In or Register to comment.