|
|
Re: c_trace/move - returning the 'texture' hit?
[Re: DiegoFloor]
#256169
03/15/09 02:19
03/15/09 02:19
|
Joined: Feb 2008
Posts: 3,232 Australia
EvilSOB
Expert
|
Expert
Joined: Feb 2008
Posts: 3,232
Australia
|
c_move doesnt, but if you performe a c_trace(me.x, target.x,IGNORE_ME|SCAN_TEXTURE)(untested) then the tex_name variable will be the texture name of what was hit. OR c_trace(me.x, you.x,IGNORE_ME|SCAN_TEXTURE)(untested) then the tex_name variable will be the model-filename of what was hit.
"There is no fate but what WE make." - CEO Cyberdyne Systems Corp. A8.30.5 Commercial
|
|
|
Re: c_trace/move - returning the 'texture' hit?
[Re: EvilSOB]
#256170
03/15/09 03:17
03/15/09 03:17
|
Joined: Jan 2009
Posts: 86 Brasil - RS
DiegoFloor
OP
Junior Member
|
OP
Junior Member
Joined: Jan 2009
Posts: 86
Brasil - RS
|
Hey thanks!  That is just right for the job I have more questions; is this tex_name a string? Because I'm trying to work with this variable but nothing works. I tried: test_string = tex_name; (test_string is a global string variable that I show in a panel) I also tried: if(tex_name == "bluetex.pcx") ... Where am I doing something wrong? o_O
|
|
|
Re: c_trace/move - returning the 'texture' hit?
[Re: DiegoFloor]
#256177
03/15/09 06:18
03/15/09 06:18
|
Joined: Feb 2008
Posts: 3,232 Australia
EvilSOB
Expert
|
Expert
Joined: Feb 2008
Posts: 3,232
Australia
|
Yeah, its a real string, so you'll need to use str_cpy(test_string,tex_name); instead of test_string = tex_name; and if(str_cmp(tex_name,"bluetex.pcx")) instead of if(tex_name=="bluetex.pcx") (both assuming lite-c, may work for c-script, otherwise I dunno)
"There is no fate but what WE make." - CEO Cyberdyne Systems Corp. A8.30.5 Commercial
|
|
|
Re: c_trace/move - returning the 'texture' hit?
[Re: DiegoFloor]
#256234
03/15/09 14:29
03/15/09 14:29
|
Joined: Feb 2008
Posts: 3,232 Australia
EvilSOB
Expert
|
Expert
Joined: Feb 2008
Posts: 3,232
Australia
|
No problem. If it wasnt for the beginners forum, I'd probably forget the simple stuff...
"There is no fate but what WE make." - CEO Cyberdyne Systems Corp. A8.30.5 Commercial
|
|
|
Moderated by mk_1, Perro, rayp, Realspawn, Rei_Ayanami, rvL_eXile, Spirit, Superku, Tobias, TSG_Torsten, VeT
|