Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: utopien on March 07, 2018, 09:15:10 AM

Title: BoxCast Help I cant MAke it Work
Post by: utopien on March 07, 2018, 09:15:10 AM
hi everyone i am traing to use the box cast action but i can't makje it work th debug show noting and i get no value from any variable please if some one can tell me why  or send me tutorial  than would be great
Title: Re: BoxCast Help I cant MAke it Work
Post by: tcmeric on March 07, 2018, 09:43:32 AM
Hi,

If I remember correctly, it actually has no debug script. Its a fair amount of work to write a simple debug for a box it turns out.

I ended up writing my own custom action using a physics check box instead of box casting. Maybe it will also fit your needs.
https://docs.unity3d.com/ScriptReference/Physics.CheckBox.html

Make sure the game object has a box collider when using this action.
Title: Re: BoxCast Help I cant MAke it Work
Post by: utopien on March 07, 2018, 11:32:02 AM
thanks for custum Cs it work fine but unfortinaly i need an hit point position , Distance and the Normal of the surface but thnaks a lot for reply
Title: Re: BoxCast Help I cant MAke it Work
Post by: Doh on March 08, 2018, 05:51:58 AM
I had similar issues with SphereCast, it didn't present a visual debug like raycast does, I ended up attaching a couple of actual spheres at the origin and end points so I could get my head round it.

In terms of it not actually hitting anything, as a guess I'd take a close look at your direction, distance and layer mask values.
Title: Re: BoxCast Help I cant MAke it Work
Post by: utopien on March 09, 2018, 05:48:07 PM
thanks i ll try that