[SOLVED] Shape painter/Raycasts stoped working suddenly

Guys something is wrong with shape painter.

I can’t create new shape painter anymore…sry i mean the raycast but dunno if shape painter too.
i mean i’ve one of my old shape painter working properly but i can’t create no new shape painters anymore…i know thaz hilarious, i mean they’re not casted, invisible or whatever…spent a day trying to debug my game…
Imo it should be something related to the scene variables used to store the position…or the draw line action

Edit: i’ve seen another similar post here…

but i’m on pc

i created this from scratch anew

settings

it doesn’t work

i’ve even disabled the clear render to see if it was the problem but no…
lol i’m forced to stop develop my game since hard focused on shape painters usage…

The shape painter won’t be working because the raycast isn’t hitting anything. My first question would be if 100 pixels is enough distance for the raycast.

If the raycast is successful, then make sure this is unchecked:
image

If that fails, I suggest you debug by shape painting in an unconditional event, and drawing it from the OrangeBlock origin to 100 pixels below it to confirm it’s hitting p1.

that is not the raycast condition im using, just a test i made with a new raycast.
I don ’ t need it to hit p1 it is just a test, shouldnt the raycast be drawn at given range and angle indipendently from the target?..just as question…
I mean i’ m not testing the hit, but the fact that it isn’ t drawn,.,ive also checked that box ad u suggested without success.

The funniest thing is that yesterday everything was working fine…today for some reason 2 of my 3 raycasts stopped working…

i made a vid

would like to know if im doin something wrong.
the shapepainter is created anew ive cleaned the box but i’ve tested with other objects and i got the same result…and before someone ask there are no other instanmces of the same objects on the scene.
I’m not saying the raycast doesn’t work…i’m saying that something corrupted it since i’ve another raycasy that works perfectly…with the same inputs…

What’s mousebox, and where is it?

there is 1 far from the box …but in truth i just filled an object …if you need i can create a sprite from scratch…i’ve also tested dragging the shpapainter on the scene and move its position without success…

edit:if it can help…everything happened after i got a ctd (that was saying to backup) after deleting an unneeded extension…but i doubt it matter

Sorry, I don’t understand. Is it far from the OrangeBlock? The raycast has to hit mouseblock before the shape painter line draw is actioned.

Do you have both these set for the shape painter (I couldn’t see it on the video because it was off screen)?




Here are my events:



which result in:
raycast

tested again everythin g from scratch, 2 new boxes (sprite) and 1 new shape painter, got the same result…
i’m testing with dragging objects like u did above rite now…
…aaand no, same thing…

…something corrupt raycasts…i honestly thing that the dude that posted the same issue today has the same problem…

problem is that i’m now blocked…until this thing is fixed in some way…

ok removed everything from the game…and it drawn…

but i’ve no guess on what could be… i mean they’re all nbew objects with no events…great…now i’m all alone searching the issue since i can’t replicate…

thx a lot anyway

That’s because in your test project you raycast from NewSprite0.X(), NewSprite.Y() (it’s the wrong object for the Y position). Same for the line draw action. Once I fixed them to NewSprite0, the test project worked fine.

A bit drastic - you could just have disable other events and then introduced them one by one until it fails.

yep iu’ve noticed that error after posting again…
but it’s not in the game rite now

Ok …now something works…

I’m gonna tell you what happened…if i have the time i’m gonna test it.

my player move inside a room…when i started the project there was only the room and other objects…the first raycast i added is in fact working…

after that i’ve decided to merge the room and room’s object to a c.object…now the fun part…

all raycasts added after this room merging doesn’t works…but the one created before still works…inside the same c.object room…this is something better to tests asap…

in fact removing the room as custom object makes all raycasts working again…

i’ve also been vcareful to remove all unwanted b.box from the custom object and while the first raycast works in the same conditions, the others dont…

i dunno what happened…

the layer is the same
points are the same
vars are the same
same conditions…

I think to have found the issue , but now i thin k im gonna end to abandon my c.objects rooms plan…

the first raycast works bcs it’s pointing to the player, the otherrs 2 pointying the ground arent working probably bcs there is no platform detection…

imn thinking that the tiled collision map i added to custom object is not compatible…

or better the tiled map collision works inside the custom object but raycasts doesn’t works with it…it cant detect the collisions.

1 Like

FIXED…removing the border collision box from the c.,object’s collision masks when created…

it was a stack of collisions masks issue…working with c.objects is hard as hell…

i can go to sleep relaxed… :100:

thx mrmen for support!

1 Like