| Author |
Message |
|
LoneStar
Commander
Joined: Fri Jun 09, 2006 2:00 am Posts: 1400 Location: Canada
|
 Re: RANDOM AND ARRAY
Yop_Solo wrote: LoneStar,
With the Vid script, I made my own to fit in my script. And you know what, it seems that you think the way I put it... but you showed me a little thing that I will need to add in mine so... It was very nice to help me.
Also, do you know what is mean Yop Solo ? Did not post to help. just having fun with routine. I do not know what yop_solo means. neither does yahoo or google 
_________________ ---------------------------- -= QUANTUM Computing 101: 15 = 3 x 5 ... 48% of the time. -= There are 10 types of people in the world: Those that understand Binary and those who do not -= If Oil is made from Dinosaurs, and Plastic is made from Oil... are plastic Dinosaurs made from real Dinosaurs? -= I like to keep my friends and my enemies rich, and wait to see which is which - Tony Stark (R.I.P.)
|
| Tue Mar 17, 2009 8:34 am |
|
 |
|
Yop_Solo
Gameop
Joined: Mon Jan 26, 2009 12:27 am Posts: 123
|
 Re: RANDOM AND ARRAY
Lonestar, Yop Solo is the character name in french version of Space Balls... like your nick.
So, Vid was right, i'm using new knowledge to create a new script... and I'm learning fast, but some of command and form of uses aren't familiar to me. But, since i began my script (like 1000 lines of script at now) maybe it's not at his best, but I'm proud of it, cause I thaught to a plan and the goals of it and trying to create and learn all new commands. Vid helps me a lot and I decided to ask on the forum too to see all the way of thinking and the manner that a particular command could be use. And now, I'm really near to achieve my script that I want to apply on my server and custom a new gamestyle that I want to play and maybe you will want to play too, it isn't a gamestyle for all type of players, but I think it will be more my type so, i began and now near of my final objective.
Thanks you all for the help. My random is still jam, but the way of doing it and integrate many commands that I knew helps me to think how to apply it to my particular variables...
ciao.
_________________ Dodger known as Yop Solo, Sysop twgsdodgerbbs.ath.cx http://cyberquebec.ca/_layout/?uri=http://cyberquebec.ca/twgsdodgerbbs/
|
| Thu Mar 19, 2009 7:00 pm |
|
 |
|
LoneStar
Commander
Joined: Fri Jun 09, 2006 2:00 am Posts: 1400 Location: Canada
|
 Re: RANDOM AND ARRAY
Yop_Solo wrote: Lonestar, Yop Solo is the character name in french version of Space Balls... like your nick.
So, Vid was right, i'm using new knowledge to create a new script... and I'm learning fast, but some of command and form of uses aren't familiar to me. But, since i began my script (like 1000 lines of script at now) maybe it's not at his best, but I'm proud of it, cause I thaught to a plan and the goals of it and trying to create and learn all new commands. Vid helps me a lot and I decided to ask on the forum too to see all the way of thinking and the manner that a particular command could be use. And now, I'm really near to achieve my script that I want to apply on my server and custom a new gamestyle that I want to play and maybe you will want to play too, it isn't a gamestyle for all type of players, but I think it will be more my type so, i began and now near of my final objective.
Thanks you all for the help. My random is still jam, but the way of doing it and integrate many commands that I knew helps me to think how to apply it to my particular variables...
ciao. Bonjour Yop Solo, Penser pas que je vous taquine. Je suis certain que vous avez reusit l'aide que vous avez besoin pour vos programme. Mais, si vous avez besion plus d'aide je suis disponible. Au sujet de votre sort de jeu, je suis interester. Salut, Lone
_________________ ---------------------------- -= QUANTUM Computing 101: 15 = 3 x 5 ... 48% of the time. -= There are 10 types of people in the world: Those that understand Binary and those who do not -= If Oil is made from Dinosaurs, and Plastic is made from Oil... are plastic Dinosaurs made from real Dinosaurs? -= I like to keep my friends and my enemies rich, and wait to see which is which - Tony Stark (R.I.P.)
|
| Thu Mar 19, 2009 9:19 pm |
|
 |
|
ElderProphet
Commander
Joined: Tue Oct 07, 2003 2:00 am Posts: 1133 Location: Augusta, GA
|
 Re: RANDOM AND ARRAY
What? I'm pretty sure that is illegal there too Lonestar. Shame on you, ya PERV!
Moderator! MODERATOR!
_________________ Claim to Fame: only guy to ever crack the TW haggle algorithm, and fig/shield/hold price formula, twice.
|
| Thu Mar 19, 2009 9:39 pm |
|
 |
|
Yop_Solo
Gameop
Joined: Mon Jan 26, 2009 12:27 am Posts: 123
|
 Re: RANDOM AND ARRAY
Héhéhé... We aren't the same person... lol Thanks you Lonestar... my random seems to bug ... but i'm not sure... the problem is not the random itself, but the counter is not working. If you had an example of a counter, it will help me. Parameters : The counter will be an array. Each time the array's value is equal to an other array's value, the counter will add one. The counter is an array too. The counter's array size is equal to first array size. Code: SETVAR $WWW 1 SETVAR $YYY 1 WHILE ($YYY <= $MaxSysActual) WHILE ($WWW <= NbPlanets) IF ($SectorNumbers[$YYY] = $SEQUENCE[$WWW]) ADD $COUNT[$YYY] 1 END ADD $WWW 1 END ADD $YYY 1 END When the counter will work, i will be able to set up my limitation with a simple IF...
_________________ Dodger known as Yop Solo, Sysop twgsdodgerbbs.ath.cx http://cyberquebec.ca/_layout/?uri=http://cyberquebec.ca/twgsdodgerbbs/
|
| Thu Mar 19, 2009 11:30 pm |
|
 |
|
Vid Kid
Commander
Joined: Sun Feb 25, 2001 3:00 am Posts: 1838 Location: Guam USA
|
 Re: RANDOM AND ARRAY
Quote: SETVAR $WWW 1 SETVAR $YYY 1 WHILE ($YYY <= $MaxSysActual) WHILE ($WWW <= NbPlanets) IF ($SectorNumbers[$YYY] = $SEQUENCE[$WWW]) ADD $COUNT[$YYY] 1 END ADD $WWW 1 END ADD $YYY 1 END
change the line that says : WHILE ($WWW <= NbPlanets) to say : WHILE ($WWW <= $NbPlanets)
_________________ TWGS V2 Vids World on Guam Port 2002 Telnet://vkworld.ddns.net:2002 Discord @ DiverDave#8374 Vid's World Discord
Founding Member -=[Team Kraaken]=- Ka Pla
 Winners of Gridwars 2010 MBN Fall Tournament 2011 winners Team Kraaken Undisputed Champions of 2019 HHT Just for showing up!
The Oldist , Longist Running , Orginal Registered Owner of a TWGS server : Vids World On Guam
|
| Fri Mar 20, 2009 7:11 am |
|
 |
|
LoneStar
Commander
Joined: Fri Jun 09, 2006 2:00 am Posts: 1400 Location: Canada
|
 Re: RANDOM AND ARRAY
Yop_Solo wrote: Code: SETVAR $WWW 1 SETVAR $YYY 1 WHILE ($YYY <= $MaxSysActual) WHILE ($WWW <= NbPlanets) IF ($SectorNumbers[$YYY] = $SEQUENCE[$WWW]) ADD $COUNT[$YYY] 1 END ADD $WWW 1 END ADD $YYY 1 END When the counter will work, i will be able to set up my limitation with a simple IF... You might want to reset the $WWW value with each iteration of $YYY. Example: Code: SETVAR $YYY 1 WHILE ($YYY <= $MaxSysActual) SETVAR $WWW 1 WHILE ($WWW <= $NbPlanets) IF ($SectorNumbers[$YYY] = $SEQUENCE[$WWW]) ADD $COUNT[$YYY] 1 END ADD $WWW 1 END ADD $YYY 1 END Other than that, the only problem I can forsee, based on experience, would be bounds checking and data-typing. Without actually seeing the context of the routine, it would be hard to provide much more insite.
_________________ ---------------------------- -= QUANTUM Computing 101: 15 = 3 x 5 ... 48% of the time. -= There are 10 types of people in the world: Those that understand Binary and those who do not -= If Oil is made from Dinosaurs, and Plastic is made from Oil... are plastic Dinosaurs made from real Dinosaurs? -= I like to keep my friends and my enemies rich, and wait to see which is which - Tony Stark (R.I.P.)
|
| Fri Mar 20, 2009 7:27 am |
|
 |
|
Promethius
Ambassador
Joined: Mon Feb 09, 2004 3:00 am Posts: 3141 Location: Kansas
|
 Re: RANDOM AND ARRAY
[quote="Yop_Solo"]Héhéhé... We aren't the same person... lol Thanks you Lonestar... my random seems to bug ... but i'm not sure... the problem is not the random itself, but the counter is not working. If you had an example of a counter, it will help me. Parameters : The counter will be an array. Each time the array's value is equal to an other array's value, the counter will add one. The counter is an array too. The counter's array size is equal to first array size. Code: SETVAR $WWW 1 SETVAR $YYY 1 WHILE ($YYY <= $MaxSysActual)
setVar $WWW 1 <-------------- Add
WHILE ($WWW <= NbPlanets) IF ($SectorNumbers[$YYY] = $SEQUENCE[$WWW]) ADD $COUNT[$YYY] 1 END ADD $WWW 1 END ADD $YYY 1 END $WWW is not reset after the first interior "while/end" -- After the first loop $www will be greater than NbPlanets. The YYY loop will just spin until it is greater than $maxSysActual. $WWW has to be reset each time on the interior of the loop. [Edit] Should have read the entire thread responses. LS caught the issue [/edit]
_________________
/ Promethius / Enigma / Wolfen /
"A man who has no skills can be taught, a man who has no honor has nothing."
|
| Fri Mar 20, 2009 11:50 am |
|
 |
|
Who is online |
Users browsing this forum: Bing [Bot] and 61 guests |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum
|
|