Posted by: MickLee - Saturday, September 3, 2016 7:29:28 AM
I'm working on a script that when you starting a skirmish/multiplayer ,and you will start with your own Building/armies.
Was wondering is that possible? Please do guide me thanks. [smile]
Posted by: klingondragon - Saturday, September 3, 2016 8:25:43 AM
It is possible. When I get back from holiday I can upload a map which does this.
Posted by: MickLee - Saturday, September 3, 2016 1:53:51 PM
Thanks for the head up, Much appreciated. Been struggle for long time on this. Does this mean the map will contain the scripts for them to work?
Posted by: UTD^Force - Saturday, September 3, 2016 4:04:42 PM
Hey there!
Yes, it's possible.
I haven't scripted anything for a year now :D
This is what I remember, hope it helps :)
Go to scripts, actions if true.
Then search for something like (unit/player) and search for the one that says unit [u][color=blue]???[/color][/u] is transferred to the control of player [u][color=blue]???[/color][/u]
The unit you want to be owned by a player has to have a name, and you fill the first 3 question marks with that name.
For the player names, player0 is the host (you in skirmish matches).
player1 is the second player, and so on to player7 who is the 8th player.
Good luck.
I can't make sure because I don't have CnC downloaded on my pc atm :(
Posted by: klingondragon - Saturday, September 3, 2016 5:03:37 PM
That's the gist however I will upload a map with all the scripts and teams you need to learn.
Posted by: klingondragon - Sunday, September 4, 2016 6:17:49 AM
here it is [ATTACH]1926[/Attach]
Posted by: MickLee - Sunday, September 4, 2016 10:23:21 AM
Thanks for everything klingondragon and UTD^Force. Much appreciated. [grin] Learning now
EDIT: Hello can you teach me in more detail? Not really understand...do we need to create a team/player first?
Posted by: klingondragon - Sunday, September 4, 2016 11:00:59 AM
Add the skirmish players as normal. Then add a civilian player for each player you want to transfer armies to. Place whatever objects you want to transfer on the map and assign them to the correct civilian player. Use the provided script with a modification for which team to transfer and who you want to transfer to.
Posted by: LordWizz - Friday, February 24, 2017 9:49:48 PM
[center][b][quote=Klingondragon;140892]Add the skirmish players as normal. Then add a civilian player for each player you want to transfer armies to. Place whatever objects you want to transfer on the map and assign them to the correct civilian player. Use the provided script with a modification for which team to transfer and who you want to transfer to.[/quote]
Thanks for helping anyway, but uhmm is there another way to do this...
Cuz i have 2 problems =P
[list][*]1. Your solutions only works with units, not with structures.[/list]
[url=https://postimg.org/image/o5yluf2ih/][img]https://s12.postimg.org/o5yluf2il/9f532c9b580339301f3a585a6f7b2361.png[/img][/url]
[list][*]2. We can't create more teams, you renamed PlyrBossGeneral to team "0" =P[/list]
[url=https://postimg.org/image/b6u50rx31/][img]https://s14.postimg.org/y8aq6iwqp/5d87e4f5be00dbdf2e145acb56950c63.png[/img][/url]
[url=https://postimg.org/image/yipdem2kx/][img]https://s32.postimg.org/gsnotkp05/cbb14f28d4f4153a6df6ddd69f0bca90.png[/img][/url]
I want it like this:
At the start of the game
Player0 getting some starting structures that are already theirs
and
Player1 too and Player2, Player3, till Player7
i want all players starting with 10 powerplants orso..
that is possible but i just dont know how to do it the easy way
Please tell me someone knows how to do it the easy way ^^
[/b]
[size=9][color=white][b]Thanks upfront =][/b][/color][/size][/center]
Posted by: acidbrain - Saturday, February 25, 2017 3:53:03 AM
[code]
[ns A D][E N H]Start_Transfers
*** IF ***
True.
*** THEN ***
Run Subroutine 'Transfer_player0_Pos1'.
[S A D][E N H]Transfer_player0_Pos1
*** IF ***
[???] Player 'player0' starting position is 1 .
*** THEN ***
Spawn Unit 'Transfer_player0_Avenger' of type 'AmericaTankAvenger' on Team 'teamPlyrCivilian' at waypoint Waypoint 'Pos1_SpawnShitHere'
[???] Unit 'Transfer_player0_Avenger' is transferred to the command of Player 'player0'
*** ELSE ***
Run Subroutine 'Transfer_player0_Pos2'.
[S A D][E N H]Transfer_player0_Pos2
*** IF ***
[???] Player 'player0' starting position is 2 .
*** THEN ***
Spawn Unit 'Transfer_player0_Avenger' of type 'AmericaTankAvenger' on Team 'teamPlyrCivilian' at waypoint Waypoint 'Pos2_SpawnShitHere'
[???] Unit 'Transfer_player0_Avenger' is transferred to the command of Player 'player0'
*** ELSE ***
Run Subroutine 'Transfer_player0_Pos3'.
[S A D][E N H]Transfer_player0_Pos3
*** IF ***
[???] Player 'player0' starting position is 3 .
*** THEN ***
Spawn Unit 'Transfer_player0_Avenger' of type 'AmericaTankAvenger' on Team 'teamPlyrCivilian' at waypoint Waypoint 'Pos3_SpawnShitHere'
[???] Unit 'Transfer_player0_Avenger' is transferred to the command of Player 'player0'
*** ELSE ***
Run Subroutine 'Transfer_player0_Pos4'.
[S A D][E N H]Transfer_player0_Pos4
*** IF ***
[???] Player 'player0' starting position is 4 .
*** THEN ***
Spawn Unit 'Transfer_player0_Avenger' of type 'AmericaTankAvenger' on Team 'teamPlyrCivilian' at waypoint Waypoint 'Pos4_SpawnShitHere'
[???] Unit 'Transfer_player0_Avenger' is transferred to the command of Player 'player0'
[/code]
Posted by: klingondragon - Saturday, February 25, 2017 5:47:48 AM
My method does work for structures. And, unlike all the other methods, requires just one line of script per player. On the dropdown change the structures to the extra civilian player, then use a script to transfer all a player's assets.
It's really simple (that's why I'm suggesting my method over the others).
Posted by: klingondragon - Saturday, February 25, 2017 8:34:23 AM
[img]http://klingondragon.dynu.com/img/cnclabs/forum/transfer_1.png[/img]
[img]http://klingondragon.dynu.com/img/cnclabs/forum/transfer_2.png[/img]
[img]http://klingondragon.dynu.com/img/cnclabs/forum/transfer_3.png[/img]
I would upload a picture of it working, but, I couldn't get a screenshot.
Posted by: acidbrain - Saturday, February 25, 2017 11:14:00 AM
[quote=Klingondragon]Then add a civilian player for each player you want to transfer armies to[/quote]
You dont need multiple civilian players, just spawn the objects on the extra civilian player, transfer all assets to target player and start over again for other players if needed.
If you want the spawns to be starting point related you have to create more scripts though and thats why i made those scripts because in skirmish matches you kinda have starting points...
In your example you use tech buildings, try it with faction buildings and see how they are sold when they are tranferred to a skirmish player...
[quote=LordWizz]
I want it like this:
At the start of the game
Player0 getting some starting structures that are already theirs
and
Player1 too and Player2, Player3, till Player7
[b]i want all players starting with 10 powerplants orso..[/b]
that is possible but i just dont know how to do it the easy way
Please tell me someone knows how to do it the easy way ^^
[/quote]
Read klingon, your method doesnt work with faction buildings, they are sold as soon as they are transfered...
Transfering faction buildings to skirmish players [b]doesnt work[/b]...
Greetz
Posted by: klingondragon - Saturday, February 25, 2017 4:03:45 PM
1. It's always worked for me.
2. Your method requires doing exactly what the original question said they didn't want (a script for each power plant). My method condenses it considerably.
Posted by: acidbrain - Saturday, February 25, 2017 4:32:04 PM
k then, provide a map in which you transfer factionbuildings to a skirmish player and make the skirmish player use the buildings...
And dont wiggle your way out of it like you usually do
Posted by: klingondragon - Saturday, February 25, 2017 4:39:42 PM
How do I "wiggle my way out of it"?
[img]http://klingondragon.dynu.com/img/cnclabs/forum/transfer_sell_1.png[/img]
[img]http://klingondragon.dynu.com/img/cnclabs/forum/transfer_sell_2.png[/img]
[img]http://klingondragon.dynu.com/img/cnclabs/forum/transfer_sell_3.png[/img]
Posted by: acidbrain - Saturday, February 25, 2017 4:42:11 PM
Just provide the map in which you transfer faction buildings to a skirmish ai player, prove me wrong so i can learn...Screenshots are worth sjit to me, neutral team now? thought you used a civilian player for the transfer?
Posted by: klingondragon - Saturday, February 25, 2017 4:44:18 PM
I see no reason to pander to your whims.
Posted by: acidbrain - Saturday, February 25, 2017 4:46:29 PM
[quote=Klingondragon;143695]I see no reason to pander to your whims.[/quote]
Told ya, just wiggle your way out of it ...hahah...you noob
Posted by: acidbrain - Sunday, February 26, 2017 6:35:52 AM
Where is the map klingon, am still waiting
[quote=Klingondragon]It's always worked for me.[/quote]
If it did then it wouldnt be a problem to upload a map in which you transfer faction buildings to a skirmish ai player...
I think the silence treatment will be executed just like in that new tank threat were you were convinced you were right while you were not and it was proven that you were wrong...
So much [grin]
Posted by: klingondragon - Sunday, February 26, 2017 6:57:40 AM
I was asleep. I can't make and upload a map while I'm asleep.
Why have you got it out for me?
Also I know not what tank thread you are referring to.
Posted by: acidbrain - Sunday, February 26, 2017 12:19:29 PM
[quote=Klingondragon;143704]Why have you got it out for me?[/quote]
I have nothing against you klingon but sometimes i just get so irritated about your stubbornness.
[url=http://www.cnclabs.com/forums/cnc_postst16866_Pink-Tank--no-textures.aspx?=][color=blue]This[/color][/url] is the thread i was talking about...
Greetz
Posted by: klingondragon - Sunday, February 26, 2017 12:39:29 PM
I thing you'll find, neither of us were right, neither one of use was wrong.
I don't see the part where I'm stubborn. Nor do I see the part where I was 'proven wrong'.
I only see that we tried to combat the problem from different angles. In the end, the matter was solved, and I like to think we both helped.
The same is true for this thread. The only reason I'm pushing my method over anyone else's, is because the original post mentioned that they already had a solution, but they wanted a simpler/shorter script. All the solutions I've seen (but mine) still have a lots of scripts.
Posted by: i^love^mixery - Sunday, April 23, 2017 8:02:57 AM
Oh acid... why are you so cancerous?
The usage of additional players is a good idea as long as computer players are not planned to be working for the map. With computer players you simply don't have enough player slots available. As long as computer players are not desired, this is one of the best solutions.
The "unsellable" option does not have any effect for computer enemies. You can disable the building, take away the power, freeze it with microwave tanks, remove the "sell" command button, the computer player doesn't give a crap and will still sell it.
Afaik there is only one solution to get the perfect building transfer script running without problems, working with comps:
1. Import the official comp script into your map
2. Go into every comp player's script folder and SPAWN the sellable buildings for him via script, they won't sell them.
3. Additionally place all of these sellable buildings on the map and transfer them to player0, player1 etc.
This will result in the following:
For human players, the comp folder spawn scripts won't have any effect, thus only the transfer scripts work.
For computer players, the transfered building will all be sold instantly, thus only the spawn scripts will work.
With this method there will be exactly one of the desired buildings left for each player, human or not.
Posted by: acidbrain - Sunday, April 23, 2017 8:22:37 AM
Cancerous? maybe, but i have a good memory and you are just as cancerous as i am mixery...:P
Good to see you back here btw
Posted by: i^love^mixery - Sunday, April 23, 2017 10:01:34 AM
Let me rephrase that... why are you still so cancerous? I have grown out of it. Actually I grew out of it before I even become inactive.
Furthermore, at the times when I shared the same attitude I at least knew what I was talking about as I was possibly the best zh scripter who was still active on the entire planet. You are making fun of klingondragon without having a working solution yourself, which is just wrong on so many levels.
Posted by: acidbrain - Sunday, April 23, 2017 10:11:15 AM
Lol, thats the mixery i know, the best there is...:P
You're right, i misbehaved a bit over here but klingon and i had a special bond in those days...:P
Somehow i just loved to piss in his garden...
Posted by: i^love^mixery - Sunday, April 23, 2017 10:22:22 AM