Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (degenerate_762), 1,128 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
return vector #271553
06/13/09 20:17
06/13/09 20:17
Joined: Jul 2007
Posts: 288
Germany, NRW
Martek Offline OP
Member
Martek  Offline OP
Member

Joined: Jul 2007
Posts: 288
Germany, NRW
Hey,
is it possible to return a vector? If tried:
Code:
VECTOR vec;
return vec;

, but I got an error. How could I do this, or have to work around this?

Mfg, Martek


3D Gamestudio A7 Extra
Re: return vector [Re: Martek] #271558
06/13/09 20:52
06/13/09 20:52
Joined: Jul 2007
Posts: 288
Germany, NRW
Martek Offline OP
Member
Martek  Offline OP
Member

Joined: Jul 2007
Posts: 288
Germany, NRW
I've solved my problem. Fear told me the answer, it is written in the manual.
If anyone is interessted, I solved it like this:
Code:
function myFunction(VECTOR* vec)
{
VECTOR* vec;
return vec;
}



3D Gamestudio A7 Extra
Re: return vector [Re: Martek] #271645
06/14/09 10:10
06/14/09 10:10
Joined: Jun 2006
Posts: 2,640
Earth
Germanunkol Offline
Expert
Germanunkol  Offline
Expert

Joined: Jun 2006
Posts: 2,640
Earth
Uh... so which vec are you returning now?
Not the one that was passed to the function...


~"I never let school interfere with my education"~
-Mark Twain
Re: return vector [Re: Germanunkol] #274581
06/27/09 12:41
06/27/09 12:41
Joined: Jul 2007
Posts: 288
Germany, NRW
Martek Offline OP
Member
Martek  Offline OP
Member

Joined: Jul 2007
Posts: 288
Germany, NRW
Oh yes, you are right, my failure. The correct one is:
Code:
function myFunction(VECTOR* vec)
{
return vec;
}




3D Gamestudio A7 Extra

Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

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