Sorry, bin kein Fachmann.
Hat jetzt geklappt, und ich Poste den Startscript und einen der Beteiligten Scripts mal,weil der Post sonst zu lang wird. Die Scripts sind fast alle änlich aufgebaut.
Start!
Script aaa
Version: 0
for Script Engine Version: 44
Description
Description
Arguments
Source Text
001 @ START [THIS] -> call script 'SATF.Werft' : Chose Position=null
002 @ START [THIS] -> call script 'SonnenKraft' : Chose Position=null
003 @ START [THIS] -> call script 'SuperPiratenwerft' : Chose Position=null
004 @ START [THIS] -> call script 'DisruptorHammerhai' : Chose Position=null
005 @ START [THIS] -> call script 'ExperimentellerSchiffbau' : Chose Position=null
006 @ START [THIS] -> call script 'ExperimentelleWaffen' : Chose Position=null
007 @ START [THIS] -> call script 'GKSWerft' : Chose Position=null
008 @ START [THIS] -> call script 'TerranerRacketenfabrik' : Chose Position=null
009 @ START [THIS] -> call script 'TerranerWerft' : Chose Position=null
010 return null
Aufgerufenes Script welches richtig lief!
Script SATF.Werft
Version: 1
for Script Engine Version: 44
Description
ATF-Schiffwerft
Arguments
1: setLoc , Var/Sector Position , 'Chose Position'
Source Text
001 $x = $setLoc[0]
002 $y = $setLoc[1]
003 $z = $setLoc[2]
004 $sec = $setLoc[3]
005
006
007 $neueStation = create station: type=Terraner Schiffswerft owner=ATF addto=Titan x=100000 y=10000 z=5000
008
009 = $neueStation -> install 15 units of 2 GJ Schild
010 $sstr = $neueStation -> get maximum shield strength
011 $neueStation -> set current shield strength to $sstr
012
013 $neueStation -> set name to $ATFStuetzpunkt
014
015 $neueStation -> station trade and production tasks: on=[TRUE]
016
017
018 $s1 = Ägir
019 $s2 = Fenrir
020 $s3 = Mjöllnir
021 $s4 = Odin
022 $s5 = Skirnir
023 $s6 = Thor
024 $s7 = Tyr
025 $s8 = Vali
026 $s9 = Vidar
027 $s10 = Walküre
028
029
030
031 $neueStation -> add product to factory or dock: $s1
032 $neueStation -> add product to factory or dock: $s2
033 $neueStation -> add product to factory or dock: $s3
034 $neueStation -> add product to factory or dock: $s4
035 $neueStation -> add product to factory or dock: $s5
036 $neueStation -> add product to factory or dock: $s6
037 $neueStation -> add product to factory or dock: $s7
038 $neueStation -> add product to factory or dock: $s8
039 $neueStation -> add product to factory or dock: $s9
040 $neueStation -> add product to factory or dock: $s10
041
042
043 check1:
044 = $neueStation -> add 1 units of $s1
045 = $neueStation -> add 1 units of $s2
046 = $neueStation -> add 1 units of $s3
047 = $neueStation -> add 1 units of $s4
048 = $neueStation -> add 1 units of $s5
049 = $neueStation -> add 1 units of $s6
050 = $neueStation -> add 1 units of $s7
051 = $neueStation -> add 1 units of $s8
052 = $neueStation -> add 1 units of $s9
053 = $neueStation -> add 1 units of $s10
054
055
056
057
058 $amount = $S1 -> get best store amount of ware $S1
059 $amount = $S1 -> get best store amount of ware $s2
060 $amount = $S1 -> get best store amount of ware $s3
061 $amount = $S1 -> get best store amount of ware $s4
062 $amount = $S1 -> get best store amount of ware $s5
063 $amount = $S1 -> get best store amount of ware $s6
064 $amount = $S1 -> get best store amount of ware $s7
065 $amount = $S1 -> get best store amount of ware $s8
066 $amount = $S1 -> get best store amount of ware $s9
067 $amount = $S1 -> get best store amount of ware $s10
068
069
070
071
072 @ = wait 50000000 ms
073 goto label check1
074 return null
Aufgerufenes Script mit Positionsfehler
Script ExperimentellerSchiffbau
Version: 3
for Script Engine Version: 44
Description
Erstellt eine Werft mit Experimentelen Schiffen
Arguments
1: setLoc , Var/Sector Position , 'Chose Position'
Source Text
001 $x = $setLoc[0]
002 $y = $setLoc[1]
003 $z = $setLoc[2]
004 $sec = $setLoc[3]
005
006
007 $neueStation = create station: type=Boronen Boron Schiffswerft owner=Boronen addto=Rolks Los x=50000 y=5000 z=5000
008
009 = $neueStation -> install 10 units of 2 GJ Schild
010 $sstr = $neueStation -> get maximum shield strength
011 $neueStation -> set current shield strength to $sstr
012
013 $neueStation -> set name to $ExperimentelleWerft
014
015 $neueStation -> station trade and production tasks: on=[TRUE]
016
017
018 $s1 = Agamemnon
019 $s2 = Euros
020 $s3 = Falke Verteidiger
021 $s4 = Hyperion Angreifer
022 $s5 = Venti
023 $s6 = Notos Frachter
024 $s7 = Akurei Frachter
025
026
027
028 $neueStation -> add product to factory or dock: $s1
029 $neueStation -> add product to factory or dock: $s2
030 $neueStation -> add product to factory or dock: $s3
031 $neueStation -> add product to factory or dock: $s4
032 $neueStation -> add product to factory or dock: $s5
033 $neueStation -> add product to factory or dock: $s6
034 $neueStation -> add product to factory or dock: $s7
035
036
037
038 check1:
039 = $neueStation -> add 1 units of $s1
040 = $neueStation -> add 1 units of $s2
041 = $neueStation -> add 1 units of $s3
042 = $neueStation -> add 1 units of $s4
043 = $neueStation -> add 1 units of $s5
044 = $neueStation -> add 1 units of $s6
045 = $neueStation -> add 1 units of $s7
046
047
048
049
050 $amount = $S1 -> get best store amount of ware $S1
051 $amount = $S1 -> get best store amount of ware $s2
052 $amount = $S1 -> get best store amount of ware $s3
053 $amount = $S1 -> get best store amount of ware $s4
054 $amount = $S1 -> get best store amount of ware $s5
055 $amount = $S1 -> get best store amount of ware $s6
056 $amount = $S1 -> get best store amount of ware $s7
057
058
059
060
061 @ = wait 1000000 ms
062 goto label check1
063 return null
Die Wrft war nach der ausführung nicht in Rolks Los sondern in Mahlstrom, wo ich mich beim test aufgehalten habe.
Danke für die Hilfe im vorraus
LG
Momo 2001
@Schaf123
Wie gesagt bin ich neu beim Scripten und übe noch, werde deine Tips/anmerkungen aber mal genauer betrachten.
Vieleicht kann ich ja noch richtig was von den alten hasen oder so lernen.
Das In Zeile 1-4 ist von nam Experiment übergebliben wo die Werft in einem zufälligen sector gebaut werden sollte. werde es bei der Überarbeitung entfernen.
Besten dank auch an Dich