heey
i need a little help with my function.
i am maken a bejeweled solver, but i need to give the array to a function, but i don't know how i can give the whole array at once.
so, maybe that one of you can help me:P
heey
i need a little help with my function.
i am maken a bejeweled solver, but i need to give the array to a function, but i don't know how i can give the whole array at once.
so, maybe that one of you can help me:P
We merely play "against the rules". We cheat. Thats what we are good at, thats what we do.
http://www.frement.net/srl/simba_user4.png
Could you explain what you mean?
Do you mean this?
SCAR Code:Function Stuff(ArrayHere : Array Of Integer) : Boolean
~Sandstorm
no help needed anymore:P
got help on the irc from Tootoot222
but thanks anyway
We merely play "against the rules". We cheat. Thats what we are good at, thats what we do.
http://www.frement.net/srl/simba_user4.png
tootoot222 thought he could help me, he did alot, but i just have to know the last thing, he recommended me to talk with wizzup but he's busy so i am back here.
i am making a bejeweled solver.
i have to make a function that gets a array like:
function zoek(array of array of integer)
now is my problem, i got 64 diffrent combinations in that array and i need them to be all sent to teh function.
my question: how can i send a whole array of array to a function.
hope i explained it well enough now:P
//edit
i know not to post twice, but i thought that poeple who already saw my last post would not know that i wasn't there yet
We merely play "against the rules". We cheat. Thats what we are good at, thats what we do.
http://www.frement.net/srl/simba_user4.png
function zoek(array of array of integer)
will work fine..
SCAR Code:Function Zeok([ArrayName[0]])
Is that doesn't work, try this:
SCAR Code:Function Zeok([ArrayName[0][0], ArrayName[0][1]]);
I believe.
~Sandstorm
We merely play "against the rules". We cheat. Thats what we are good at, thats what we do.
http://www.frement.net/srl/simba_user4.png



And then just pass the whole array?SCAR Code:procedure zeok(I: Array of Array of Integer);
yea
i am asking al day on irc but no one knew how to do it
3 poeple tryed:S:P
this is what i got:
SCAR Code:function zoek(new: array of array of string; lvl,hoogst:Integer):Integer;
var
zet : Integer;
begin
writeln(new[1][1]);
end;
begin
index;
zoek(bej,0,0);// line 105
end.
bej is an array filled with values, 64 values.
i need to pass them all to the function
We merely play "against the rules". We cheat. Thats what we are good at, thats what we do.
http://www.frement.net/srl/simba_user4.png
Try Zeok(Bej[0],0,0);.
~Sandstorm
@Smarter Child
bej is short for bejeweld
@Sandstorm
already tryed that
We merely play "against the rules". We cheat. Thats what we are good at, thats what we do.
http://www.frement.net/srl/simba_user4.png



That should work. Can you post how you define "bej"?
And what's the error?
hoog = 8
breed = 8
SCAR Code:bej: array[0..hoog] of array[0..breed] of String; //bej[x][y]
but it must not only send bej[0][watever]
also:
bej[1][0]
bej[1][1]
bej[1][2]
bej[2][0]
bej[2][1] etc etc
We merely play "against the rules". We cheat. Thats what we are good at, thats what we do.
http://www.frement.net/srl/simba_user4.png
Define it all to Bej[0][0....64], so that mine works.
~Sandstorm
Finaly fixed.
mixster helped me out on irc.
my problem was that is made the array static at the top
and static can not be passed to the function
We merely play "against the rules". We cheat. Thats what we are good at, thats what we do.
http://www.frement.net/srl/simba_user4.png



There are currently 1 users browsing this thread. (0 members and 1 guests)