Gamestudio Links
Zorro Links
Newest Posts
Executing Trades on Next Bar Open
by vicknick. 06/13/24 08:51
Zorro Beta 2.61: PyTorch
by jcl. 06/10/24 14:42
New FXCM FIX Plugin
by flink. 06/04/24 07:30
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
0 registered members (), 1,251 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19059 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
a c_scan question, probably simple #302626
12/20/09 21:43
12/20/09 21:43
Joined: Jun 2009
Posts: 38
H
hungryhobo Offline OP
Newbie
hungryhobo  Offline OP
Newbie
H

Joined: Jun 2009
Posts: 38
Hello, I am trying to make a function that scans around the entire entity, just to determine if there are any objects within a certain distance.

i was able to do it with trace, but i want to scan in an entire ring or sphere. I keep getting syntax errors, despite following the manual. here is my code

I am using A6.

scan_mode = ignore_me + ignore_models + ignore_sprites;

scan_distance = scan(camera.x,camera.pan,sphere_scan);

if I add the scan_mode into the scan() i still get errors.

using scan, or c_scan I always get errors saying "bad or missing parameter unknown function" however, if i remove the "scan_distance =" it compiles. but I need to store the distance it is supposed to return on a scan.. what is going on?

NOTE: this worked

trace_mode = ignore_me + ignore_passable + ignore_you;
moon_trace = trace(player.x,moon.x); //find if there is anything in the way of the moon or



Last edited by hungryhobo; 12/20/09 21:44.
Re: a c_scan question, probably simple [Re: hungryhobo] #302630
12/20/09 23:34
12/20/09 23:34
Joined: Jul 2008
Posts: 1,178
England
M
MrGuest Offline
Serious User
MrGuest  Offline
Serious User
M

Joined: Jul 2008
Posts: 1,178
England
Originally Posted By: hungryhobo
scan_mode = ignore_me + ignore_models + ignore_sprites;

scan_distance = scan(camera.x,camera.pan,sphere_scan);
a while since i've used A6 now, but why are you passing sphere_scan as a parameter, surely that should be scan_mode?

Re: a c_scan question, probably simple [Re: MrGuest] #302658
12/21/09 08:27
12/21/09 08:27
Joined: Jun 2009
Posts: 38
H
hungryhobo Offline OP
Newbie
hungryhobo  Offline OP
Newbie
H

Joined: Jun 2009
Posts: 38
sphere_scan is a vector that says that it should scan in a sphere and how far out.


Moderated by  HeelX, rvL_eXile 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1