So here is the code Im working with to place burn marks on the wall if my bullet collides with the wall, the burn mark is to be placed where the bullet,postion hits the wall,BUTTT,they never are placed on the wall, they just shoot trait into to wall.the plain does stay at the location of my bullet if I dont hit a wall so I know its working but for some reason im getting no collition with my level walls.
edit: object 3 is my bullet,and bullethole is my burn mark plain
SC_updateObject bullethole
SC_updateObject 3
if shootfire=1
unglue object 3
playobject=0
point Object 3, camera position x(0), camera position y(0)-2, camera position z(0)
show object 3
move object 3,-10
rem get the player position
x3#=object position x(3)
y3#=object position y(3)
z3#=object position z(3)
rem position bullethole to camera orientation
position object bullethole,x3#,y3#,z3#
rotate object bullethole,camera angle x(),camera angle y(),camera angle z()
rem get ending position of bullet
move object bullethole,-10
newx#=object position x(3)
newy#=object position y(3)
newz#=object position z(3)
rem check if the bullet hit the object
if SC_intersectObject(1,x3#,y3#,z3#,newx#,newy#,newz#)=1
rem get the collision position and the normals of the poly
cx#=sc_getstaticcollisionx() : nx#=sc_getcollisionnormalx()
cy#=sc_getstaticcollisiony() : ny#=sc_getcollisionnormaly()
cz#=sc_getstaticcollisionz() : nz#=sc_getcollisionnormalz()
rem rotate and position the bullethole
position object bullethole,cx#,cy#,cz#
point object bullethole,cx#+(nx#*100),cy#+(ny#*100),cz#+(nz#*100)
move object bullethole,0.1
position object 3,cx#,cy#,cz#
point object 3,cx#+(nx#*100),cy#+(ny#*100),cz#+(nz#*100)
move object 3,0.1
endif
shoottimefire=shoottimefire+1
endif
my signature keeps being erased by a mod So this is my new signature.