Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

2 Pages12>
Options
Go to last post Go to first unread
Offline ronky  
#1 Posted : Friday, February 1, 2019 8:06:45 AM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12


Hi,

I hope you guys can help me out.

I already searched on this forum and on google and have not found a solution.

I would like to make the below changes to a custom map without touching commandset.ini and map.ini so that it can be played online without problems.


1. General: Air Force

Is it possible to make the "carpet bomber science" only available for Air Force General once he has 3 stars?

By standard Air Force General has access to carpet bomber science from the beginning and can use it once he finished building a strategy center.


2. General: China Vanilla & China Nuke

I would like to deactive the use of sw but the uranium shell and nuclear tank upgrade should still be available.

My ideas how to solve it:

2.1 Is it possible to disable the launch nuke shortcut and launch nuke button?

or

2.2 Adjust the sw recharge time to 999?

or

2.3 What I can also do is move the two buttons for uranium shell and nuclear tank upgrad to another building (propaganda center for example).

But would it be possible to increase the costs for these two updates as the player does not have to build a nuke missile silo anymore?
Sponsor
Offline SkyMix_RMT  
#2 Posted : Friday, February 1, 2019 2:56:52 PM(UTC)
SkyMix_RMT
Major
Joined: 2/21/2015(UTC)
Posts: 386
Portugal

Thanks: 80 times
Was thanked: 132 time(s) in 96 post(s)
Originally Posted by: ronky Go to Quoted Post
1. General: Air Force

Is it possible to make the "carpet bomber science" only available for Air Force General once he has 3 stars?

(Edit: Check below for answer)

Originally Posted by: ronky Go to Quoted Post
2.1 Is it possible to disable the launch nuke shortcut and launch nuke button?

From the building, yes, from the shortcut, not sure.

Originally Posted by: ronky Go to Quoted Post
2.2 Adjust the sw recharge time to 999?

Not possible.

Originally Posted by: ronky Go to Quoted Post
2.3 What I can also do is move the two buttons for uranium shell and nuclear tank upgrad to another building (propaganda center for example).

It is possible.

Originally Posted by: ronky Go to Quoted Post
But would it be possible to increase the costs for these two updates as the player does not have to build a nuke missile silo anymore?

No.

Edited by user Wednesday, February 6, 2019 8:50:34 AM(UTC)  | Reason: Not specified

Check out:

My Music (Techno/House/Experimental)

My Website (GeneralsCentral)

My Youtube Channel (Inactive)

World Builder Community Discord
Offline AdrianeMapMaker  
#3 Posted : Sunday, February 3, 2019 6:20:58 AM(UTC)
AdrianeMapMaker
General
C&C Labs Staff: Labs Staff MemberMaps Staff: Maps Staff Member
Joined: 3/8/2016(UTC)
Posts: 1,156
Philippines

Thanks: 312 times
Was thanked: 185 time(s) in 149 post(s)
Originally Posted by: SkyMix_RMT Go to Quoted Post
Originally Posted by: ronky Go to Quoted Post
1. General: Air Force

Is it possible to make the "carpet bomber science" only available for Air Force General once he has 3 stars?


```No.```

Originally Posted by: ronky Go to Quoted Post
2.2 Adjust the sw recharge time to 999?


```Not possible.````



Skymix .. Dude you serious? .. its actually possible bro

Edited by user Sunday, February 3, 2019 6:23:47 AM(UTC)  | Reason: Not specified

A part of ZH worldbuilders map making community
https://discord.gg/tJ6zyGb

UserPostedImage





Offline i^love^mixery  
#4 Posted : Monday, February 4, 2019 12:41:46 PM(UTC)
i^love^mixery
Colonel
Joined: 10/13/2008(UTC)
Posts: 782

Thanks: 7 times
Was thanked: 201 time(s) in 147 post(s)
Originally Posted by: ronky Go to Quoted Post


Is it possible to make the "carpet bomber science" only available for Air Force General once he has 3 stars?

By standard Air Force General has access to carpet bomber science from the beginning and can use it once he finished building a strategy center.



Yes, it is actually possible with this workaround:
Use the script Player -> Science -> Set Science Availability

Remove it from the beginning, re-add it with the same script once the player has reached 3 stars.

Use this script condition to check if player is 3 stars yet:
Player -> Science -> Player acquired a skill -> SCIENCE_Rank3

You have to create these scripts for all 8 possible players (player0 - player7). You don't need to check for factions, as the science will only be available for air force general anyway.


Originally Posted by: ronky Go to Quoted Post


2. General: China Vanilla & China Nuke

I would like to deactive the use of sw but the uranium shell and nuclear tank upgrade should still be available.

My ideas how to solve it:

2.1 Is it possible to disable the launch nuke shortcut and launch nuke button?

or

2.2 Adjust the sw recharge time to 999?

or

2.3 What I can also do is move the two buttons for uranium shell and nuclear tank upgrad to another building (propaganda center for example).

But would it be possible to increase the costs for these two updates as the player does not have to build a nuke missile silo anymore?


You cannot increase the costs, so moving the buttons to a different building might throw things off balance

You can remove the command button from the superweapon itself, but afaik with scripts you can't remove the command button from the ability shortcut bar on the right of the screen, so the nuke will still be launch-able.

You also can't change the countdown time, because the unit is not named.

The only thing I can think of:
Replace the Nuke Missile Silo with a different superweapon of an entirely different faction (Particle Cannon or Scud Launcher), add the command buttons for the upgrades to that superweapon, remove the command button to launch the superweapons... it would work but also confuse the hell out of people. The trick is that SW launch command buttons of an entirely different faction will not be displayed in the shortcut bar.

Alternatively you could sell-off the base of a player who dared to launch the nuke. But then you have to warn them with briefings of course.

Edited by user Monday, February 4, 2019 12:43:32 PM(UTC)  | Reason: Not specified

thanks 1 user thanked i^love^mixery for this useful post.
UTD^Force on 2/8/2019(UTC)
Offline ronky  
#5 Posted : Monday, February 4, 2019 3:17:49 PM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12

Wow, thanks for the feedback and advise ilovemixery!


Regarding the sw:

Good idea with the sw from another faction but I agree that it will confuse players too much.

Hence I decided to move the upgrades from nuclear silo to propaganda center.

But only if the internet center has been built first.

For these I added four separate scripts in the PLyrCivilian folder:


*** IF ***
'ChinaInternetCenter' has been built by Player 'PlyrCivilian'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaUraniumShells' is added to all objects of type 'ChinaPropagandaCenter' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'ChinaPropagandaCenter' in slot number 13 (1-12).
[???] Command button: 'Command_UpgradeChinaNuclearTanks' is added to all objects of type 'ChinaPropagandaCenter' in slot number 11 (1-12).

*** IF ***
'Tank_ChinaInternetCenter' has been built by Player 'PlyrCivilian'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaUraniumShells' is added to all objects of type 'Tank_ChinaPropagandaCenter' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Tank_ChinaPropagandaCenter' in slot number 13 (1-12).
[???] Command button: 'Command_UpgradeChinaNuclearTanks' is added to all objects of type 'Tank_ChinaPropagandaCenter' in slot number 11 (1-12).


*** IF ***
'Nuke_ChinaInternetCenter' has been built by Player 'PlyrCivilian'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Nuke_ChinaPropagandaCenter' in slot number 13 (1-12).


*** IF ***
'Infa_ChinaInternetCenter' has been built by Player 'PlyrCivilian'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).


Unfortunately these scripts only work for me in multiplayer games but not for others.

How do I change these to make them work for other players as well?

I also have the same problem with GLA Upgrades, they appear in Supply Stash once Palace has been built.

Again these changes work only for me but not for other players.


*** IF ***
'Chem_GLAPalace' has been built by Player 'PlyrCivilian'
*** THEN ***
[???] Command button: 'Command_UpgradeGLAAPBullets' is added to all objects of type 'Chem_GLASupplyStash' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeGLAAPRockets' is added to all objects of type 'Chem_GLASupplyStash' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeGLABuggyAmmo' is added to all objects of type 'Chem_GLASupplyStash' in slot number 6 (1-12).
[???] Command button: 'Command_UpgradeGLAJunkRepair' is added to all objects of type 'Chem_GLASupplyStash' in slot number 8 (1-12).
[???] Command button: 'Command_UpgradeGLARadarVanScan' is added to all objects of type 'Chem_GLASupplyStash' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeGLAWorkerShoes' is added to all objects of type 'Chem_GLASupplyStash' in slot number 10 (1-12).

*** IF ***
'Slth_GLAPalace' has been built by Player 'PlyrCivilian'
*** THEN ***
[???] Command button: 'Command_UpgradeGLAAPBullets' is added to all objects of type 'Slth_GLASupplyStash' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeGLAAPRockets' is added to all objects of type 'Slth_GLASupplyStash' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeGLABuggyAmmo' is added to all objects of type 'Slth_GLASupplyStash' in slot number 6 (1-12).
[???] Command button: 'Command_UpgradeGLAJunkRepair' is added to all objects of type 'Slth_GLASupplyStash' in slot number 8 (1-12).
[???] Command button: 'Command_UpgradeGLARadarVanScan' is added to all objects of type 'Slth_GLASupplyStash' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeGLAWorkerShoes' is added to all objects of type 'Slth_GLASupplyStash' in slot number 10 (1-12).

*** IF ***
'Demo_GLAPalace' has been built by Player 'PlyrCivilian'
*** THEN ***
[???] Command button: 'Command_UpgradeGLAAPBullets' is added to all objects of type 'Demo_GLASupplyStash' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeGLAAPRockets' is added to all objects of type 'Demo_GLASupplyStash' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeGLABuggyAmmo' is added to all objects of type 'Demo_GLASupplyStash' in slot number 6 (1-12).
[???] Command button: 'Command_UpgradeGLAJunkRepair' is added to all objects of type 'Demo_GLASupplyStash' in slot number 8 (1-12).
[???] Command button: 'Command_UpgradeGLARadarVanScan' is added to all objects of type 'Demo_GLASupplyStash' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeGLAWorkerShoes' is added to all objects of type 'Demo_GLASupplyStash' in slot number 10 (1-12).

*** IF ***
'GLAPalace' has been built by Player 'PlyrCivilian'
*** THEN ***
[???] Command button: 'Command_UpgradeGLAAPBullets' is added to all objects of type 'GLASupplyStash' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeGLAAPRockets' is added to all objects of type 'GLASupplyStash' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeGLABuggyAmmo' is added to all objects of type 'GLASupplyStash' in slot number 6 (1-12).
[???] Command button: 'Command_UpgradeGLAJunkRepair' is added to all objects of type 'GLASupplyStash' in slot number 8 (1-12).
[???] Command button: 'Command_UpgradeGLARadarVanScan' is added to all objects of type 'GLASupplyStash' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeGLAWorkerShoes' is added to all objects of type 'GLASupplyStash' in slot number 10 (1-12).






Offline i^love^mixery  
#6 Posted : Tuesday, February 5, 2019 6:29:43 AM(UTC)
i^love^mixery
Colonel
Joined: 10/13/2008(UTC)
Posts: 782

Thanks: 7 times
Was thanked: 201 time(s) in 147 post(s)
Replace "PlyrCivilian" with "LocalPlayer" and see if it works.

As long as you only script commands buttons with "LocalPlayer" it might work. For pretty much anything else it will cause a mismatch.

Also don't forget to add some briefings to tell people wtf is going on

Edited by user Tuesday, February 5, 2019 6:30:37 AM(UTC)  | Reason: Not specified

Offline ronky  
#7 Posted : Tuesday, February 5, 2019 8:40:17 AM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12

Thanks for the advise, I will try it out. Obviously I have a detailed briefing included already.


Another question:


1. Is it possible to make Lotus unable to capture oil? But she should still be able to capture buildings.

Currently I removed her capture function altogether.



2. I removed the Demo Bike from Demo General and replaced it with a normal GLA Bike.
Unfortunately I can not mount the normal GLA Bike with any Demo Infantry units or workers.
Is there a way to solve this?
Offline i^love^mixery  
#8 Posted : Tuesday, February 5, 2019 12:54:07 PM(UTC)
i^love^mixery
Colonel
Joined: 10/13/2008(UTC)
Posts: 782

Thanks: 7 times
Was thanked: 201 time(s) in 147 post(s)
Originally Posted by: ronky Go to Quoted Post
Thanks for the advise, I will try it out. Obviously I have a detailed briefing included already.


Another question:


1. Is it possible to make Lotus unable to capture oil? But she should still be able to capture buildings.

Currently I removed her capture function altogether.



How did you remove the capture function? I don't think deleting the command button will suffice, you can still just click on a building to capture it, no?

Anyway, there is no way without ini.

Originally Posted by: ronky Go to Quoted Post


2. I removed the Demo Bike from Demo General and replaced it with a normal GLA Bike.
Unfortunately I can not mount the normal GLA Bike with any Demo Infantry units or workers.
Is there a way to solve this?


Not really, no.

Edited by user Tuesday, February 5, 2019 12:54:44 PM(UTC)  | Reason: Not specified

Offline ronky  
#9 Posted : Tuesday, February 5, 2019 3:59:26 PM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12

I removed Lotus capture ability by the below script, she can not capture anything anymore at all, no matter what.

*** IF ***
True.
*** THEN ***
[???] Command button: 'Command_ChinaInfantryBlackLotusCaptureHack' is removed from all objects of type 'ChinaInfantryBlackLotus'.
[???] Command button: 'Command_ChinaInfantryBlackLotusCaptureHack' is removed from all objects of type 'Infa_ChinaInfantryBlackLotus'.
[???] Command button: 'Command_ChinaInfantryBlackLotusCaptureHack' is removed from all objects of type 'Nuke_ChinaInfantryBlackLotus'.
[???] Command button: 'Command_ChinaInfantryBlackLotusCaptureHack' is removed from all objects of type 'Tank_ChinaInfantryBlackLotus'.

_____


I tried playing a couple of games with replacing "PlyrCivilian" with "Localplayer" as suggested by you.

Now the other players have access to the upgrades in supply stash and propaganda center.

Unfortunately the game mismatches after 10-15 minutes or so.

Any idea how to solve the problem?

Should I maybe use player0 - player5 instead of "Localplayer"? Similar to the AFG carpet bomber script you suggested?
Offline i^love^mixery  
#10 Posted : Tuesday, February 5, 2019 10:20:15 PM(UTC)
i^love^mixery
Colonel
Joined: 10/13/2008(UTC)
Posts: 782

Thanks: 7 times
Was thanked: 201 time(s) in 147 post(s)
The thing is, unlike the science script, you can't limit the add/remove command button scripts to a player. So If player1 builds the required buildings, the commands buttons will also be added to player0's buildings (if both players have the same faction).

You will have to work with LocalPlayer somehow.

I will check tomorrow for a variant that doesn't mismatch.
Offline ronky  
#11 Posted : Wednesday, February 6, 2019 4:01:37 AM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12

Much appreciate your help and hope you find a solution regarding the mismatching.

I know that the below script (not the one I use) works without mismatching.

But that script is simpler as it doesnt take into account that you have to build, building X before upgrades will be available in building Y.


*** IF ***
True.
*** THEN ***
[???] Command button: 'Tank_Command_UpgradeChinaUraniumShells' is added to all objects of type 'Tank_ChinaPropagandaCenter' in slot number 5 (1-12).
[???] Command button: 'Tank_Command_UpgradeChinaNuclearTanks' is added to all objects of type 'Tank_ChinaPropagandaCenter' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeChinaUraniumShells' is added to all objects of type 'ChinaPropagandaCenter' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeChinaNuclearTanks' is added to all objects of type 'ChinaPropagandaCenter' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'ChinaPropagandaCenter' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Nuke_ChinaPropagandaCenter' in slot number 9 (1-12).
Offline SkyMix_RMT  
#12 Posted : Wednesday, February 6, 2019 8:49:49 AM(UTC)
SkyMix_RMT
Major
Joined: 2/21/2015(UTC)
Posts: 386
Portugal

Thanks: 80 times
Was thanked: 132 time(s) in 96 post(s)
Didn't know you could check if a player had acquired rank 3. Edited my reply.
Check out:

My Music (Techno/House/Experimental)

My Website (GeneralsCentral)

My Youtube Channel (Inactive)

World Builder Community Discord
Offline ronky  
#13 Posted : Thursday, February 7, 2019 3:16:57 PM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12

So I scripted like seen below now and it works in LAN mode with just me as a player. Will report if it works online without mismatching.


*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player0'
*** OR ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player1'
*** OR ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player2'
*** OR ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player3'
*** OR ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player4'
*** OR ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player5'
*** OR ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player6'
*** OR ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).

//

*** IF ***
[???] 'Tank_ChinaInternetCenter' has been built by Player 'player0'
*** OR ***
[???] 'Tank_ChinaInternetCenter' has been built by Player 'player1'
*** OR ***
[???] 'Tank_ChinaInternetCenter' has been built by Player 'player2'
*** OR ***
[???] 'Tank_ChinaInternetCenter' has been built by Player 'player3'
*** OR ***
[???] 'Tank_ChinaInternetCenter' has been built by Player 'player4'
*** OR ***
[???] 'Tank_ChinaInternetCenter' has been built by Player 'player5'
*** OR ***
[???] 'Tank_ChinaInternetCenter' has been built by Player 'player6'
*** OR ***
[???] 'Tank_ChinaInternetCenter' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaUraniumShells' is added to all objects of type 'Tank_ChinaPropagandaCenter' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Tank_ChinaPropagandaCenter' in slot number 13 (1-12).
[???] Command button: 'Command_UpgradeChinaNuclearTanks' is added to all objects of type 'Tank_ChinaPropagandaCenter' in slot number 11 (1-12).


//


*** IF ***
[???] 'Nuke_ChinaInternetCenter' has been built by Player 'player0'
*** OR ***
[???] 'Nuke_ChinaInternetCenter' has been built by Player 'player1'
*** OR ***
[???] 'Nuke_ChinaInternetCenter' has been built by Player 'player2'
*** OR ***
[???] 'Nuke_ChinaInternetCenter' has been built by Player 'player3'
*** OR ***
[???] 'Nuke_ChinaInternetCenter' has been built by Player 'player4'
*** OR ***
[???] 'Nuke_ChinaInternetCenter' has been built by Player 'player5'
*** OR ***
[???] 'Nuke_ChinaInternetCenter' has been built by Player 'player6'
*** OR ***
[???] 'Nuke_ChinaInternetCenter' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Nuke_ChinaPropagandaCenter' in slot number 13 (1-12).


//

*** IF ***
[???] 'ChinaInternetCenter' has been built by Player 'player0'
*** OR ***
[???] 'ChinaInternetCenter' has been built by Player 'player1'
*** OR ***
[???] 'ChinaInternetCenter' has been built by Player 'player2'
*** OR ***
[???] 'ChinaInternetCenter' has been built by Player 'player3'
*** OR ***
[???] 'ChinaInternetCenter' has been built by Player 'player4'
*** OR ***
[???] 'ChinaInternetCenter' has been built by Player 'player5'
*** OR ***
[???] 'ChinaInternetCenter' has been built by Player 'player6'
*** OR ***
[???] 'ChinaInternetCenter' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaUraniumShells' is added to all objects of type 'ChinaPropagandaCenter' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'ChinaPropagandaCenter' in slot number 13 (1-12).
[???] Command button: 'Command_UpgradeChinaNuclearTanks' is added to all objects of type 'ChinaPropagandaCenter' in slot number 11 (1-12).


____________________________


*** IF ***
[???] 'Demo_GLAPalace' has been built by Player 'player0'
*** OR ***
[???] 'Demo_GLAPalace' has been built by Player 'player1'
*** OR ***
[???] 'Demo_GLAPalace' has been built by Player 'player2'
*** OR ***
[???] 'Demo_GLAPalace' has been built by Player 'player3'
*** OR ***
[???] 'Demo_GLAPalace' has been built by Player 'player4'
*** OR ***
[???] 'Demo_GLAPalace' has been built by Player 'player5'
*** OR ***
[???] 'Demo_GLAPalace' has been built by Player 'player6'
*** OR ***
[???] 'Demo_GLAPalace' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeGLAAPBullets' is added to all objects of type 'Demo_GLASupplyStash' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeGLAAPRockets' is added to all objects of type 'Demo_GLASupplyStash' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeGLABuggyAmmo' is added to all objects of type 'Demo_GLASupplyStash' in slot number 6 (1-12).
[???] Command button: 'Command_UpgradeGLAJunkRepair' is added to all objects of type 'Demo_GLASupplyStash' in slot number 8 (1-12).
[???] Command button: 'Command_UpgradeGLARadarVanScan' is added to all objects of type 'Demo_GLASupplyStash' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeGLAWorkerShoes' is added to all objects of type 'Demo_GLASupplyStash' in slot number 10 (1-12).

//

*** IF ***
[???] 'GLAPalace' has been built by Player 'player0'
*** OR ***
[???] 'GLAPalace' has been built by Player 'player1'
*** OR ***
[???] 'GLAPalace' has been built by Player 'player2'
*** OR ***
[???] 'GLAPalace' has been built by Player 'player3'
*** OR ***
[???] 'GLAPalace' has been built by Player 'player4'
*** OR ***
[???] 'GLAPalace' has been built by Player 'player5'
*** OR ***
[???] 'GLAPalace' has been built by Player 'player6'
*** OR ***
[???] 'GLAPalace' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeGLAAPBullets' is added to all objects of type 'GLASupplyStash' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeGLAAPRockets' is added to all objects of type 'GLASupplyStash' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeGLABuggyAmmo' is added to all objects of type 'GLASupplyStash' in slot number 6 (1-12).
[???] Command button: 'Command_UpgradeGLAJunkRepair' is added to all objects of type 'GLASupplyStash' in slot number 8 (1-12).
[???] Command button: 'Command_UpgradeGLARadarVanScan' is added to all objects of type 'GLASupplyStash' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeGLAWorkerShoes' is added to all objects of type 'GLASupplyStash' in slot number 10 (1-12).

//


*** IF ***
[???] 'Slth_GLAPalace' has been built by Player 'player0'
*** OR ***
[???] 'Slth_GLAPalace' has been built by Player 'player1'
*** OR ***
[???] 'Slth_GLAPalace' has been built by Player 'player2'
*** OR ***
[???] 'Slth_GLAPalace' has been built by Player 'player3'
*** OR ***
[???] 'Slth_GLAPalace' has been built by Player 'player4'
*** OR ***
[???] 'Slth_GLAPalace' has been built by Player 'player5'
*** OR ***
[???] 'Slth_GLAPalace' has been built by Player 'player6'
*** OR ***
[???] 'Slth_GLAPalace' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeGLAAPBullets' is added to all objects of type 'Slth_GLASupplyStash' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeGLAAPRockets' is added to all objects of type 'Slth_GLASupplyStash' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeGLABuggyAmmo' is added to all objects of type 'Slth_GLASupplyStash' in slot number 6 (1-12).
[???] Command button: 'Command_UpgradeGLAJunkRepair' is added to all objects of type 'Slth_GLASupplyStash' in slot number 8 (1-12).
[???] Command button: 'Command_UpgradeGLARadarVanScan' is added to all objects of type 'Slth_GLASupplyStash' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeGLAWorkerShoes' is added to all objects of type 'Slth_GLASupplyStash' in slot number 10 (1-12).


//

*** IF ***
[???] 'Chem_GLAPalace' has been built by Player 'player0'
*** OR ***
[???] 'Chem_GLAPalace' has been built by Player 'player1'
*** OR ***
[???] 'Chem_GLAPalace' has been built by Player 'player2'
*** OR ***
[???] 'Chem_GLAPalace' has been built by Player 'player3'
*** OR ***
[???] 'Chem_GLAPalace' has been built by Player 'player4'
*** OR ***
[???] 'Chem_GLAPalace' has been built by Player 'player5'
*** OR ***
[???] 'Chem_GLAPalace' has been built by Player 'player6'
*** OR ***
[???] 'Chem_GLAPalace' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeGLAAPBullets' is added to all objects of type 'Chem_GLASupplyStash' in slot number 7 (1-12).
[???] Command button: 'Command_UpgradeGLAAPRockets' is added to all objects of type 'Chem_GLASupplyStash' in slot number 5 (1-12).
[???] Command button: 'Command_UpgradeGLABuggyAmmo' is added to all objects of type 'Chem_GLASupplyStash' in slot number 6 (1-12).
[???] Command button: 'Command_UpgradeGLAJunkRepair' is added to all objects of type 'Chem_GLASupplyStash' in slot number 8 (1-12).
[???] Command button: 'Command_UpgradeGLARadarVanScan' is added to all objects of type 'Chem_GLASupplyStash' in slot number 9 (1-12).
[???] Command button: 'Command_UpgradeGLAWorkerShoes' is added to all objects of type 'Chem_GLASupplyStash' in slot number 10 (1-12).

Offline SkyMix_RMT  
#14 Posted : Friday, February 8, 2019 5:10:14 AM(UTC)
SkyMix_RMT
Major
Joined: 2/21/2015(UTC)
Posts: 386
Portugal

Thanks: 80 times
Was thanked: 132 time(s) in 96 post(s)
There is a problem with those scripts, like mixery said, if for example only player0 builds a internet center then all players from 0 to 7 will have uranium shells, neutron shells and nuclear tanks in their propaganda centers (as long as they are the same faction)

Edited by user Friday, February 8, 2019 5:40:59 AM(UTC)  | Reason: Not specified

Check out:

My Music (Techno/House/Experimental)

My Website (GeneralsCentral)

My Youtube Channel (Inactive)

World Builder Community Discord
Offline ronky  
#15 Posted : Friday, February 8, 2019 5:36:52 AM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12

Makes sense, what if I make eight separate scripts out of one? Would the outcome be the same? So like this:


*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player0'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).

*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player1'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).


*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player2'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).


*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player3'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).


*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player4'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).


*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player5'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).


*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player6'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).


*** IF ***
[???] 'Infa_ChinaInternetCenter' has been built by Player 'player7'
*** THEN ***
[???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Infa_ChinaPropagandaCenter' in slot number 13 (1-12).

Offline SkyMix_RMT  
#16 Posted : Friday, February 8, 2019 5:46:21 AM(UTC)
SkyMix_RMT
Major
Joined: 2/21/2015(UTC)
Posts: 386
Portugal

Thanks: 80 times
Was thanked: 132 time(s) in 96 post(s)
Yes the outcome would be the same because the script adds a command button to ALL players' propaganda center and not just player0 or player1 propaganda center.
The only way to do add command button to a single players' propaganda center is using the local player method, because the local player script only runs for the a player locally and not for the entire server, it will only add the buttons to the local player who built the propaganda center, and that might be the reason behind the mismatches.
Check out:

My Music (Techno/House/Experimental)

My Website (GeneralsCentral)

My Youtube Channel (Inactive)

World Builder Community Discord
Offline ronky  
#17 Posted : Friday, February 8, 2019 8:28:10 AM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12

Originally Posted by: SkyMix_RMT Go to Quoted Post
Yes the outcome would be the same because the script adds a command button to ALL players' propaganda center and not just player0 or player1 propaganda center.
The only way to do add command button to a single players' propaganda center is using the local player method, because the local player script only runs for the a player locally and not for the entire server, it will only add the buttons to the local player who built the propaganda center, and that might be the reason behind the mismatches.


So I checked all script options in World Builder and there does not seem to be a direct or indirect way to add one or several scripts which are enabling upgrades in building X of PlayerY if Player Y builds, building Z first. By using PlyrCivilian only host of the game gets the upgrades, if using Localplayer it works but the game mismatches, if using player0-7 everyone gets the upgrades. So there is no real solution?

There are like hundreds of very sophisticated script options in World Builder but something simple like that isn't included?

Edited by user Friday, February 8, 2019 8:29:24 AM(UTC)  | Reason: Not specified

Offline i^love^mixery  
#18 Posted : Saturday, February 9, 2019 7:31:24 AM(UTC)
i^love^mixery
Colonel
Joined: 10/13/2008(UTC)
Posts: 782

Thanks: 7 times
Was thanked: 201 time(s) in 147 post(s)
Originally Posted by: ronky Go to Quoted Post
There are like hundreds of very sophisticated script options in World Builder but something simple like that isn't included?


You couldn't imagine how often I had the same thought.

You also can't teleport units, can't set current or max healthpoints, can't use variables at all and many more things...

Anyway, I had an idea how this might work without mismatch but I actually somehow managed to forgot during the last 3 days, give me a moment Big Smile
Offline i^love^mixery  
#19 Posted : Saturday, February 9, 2019 9:03:28 AM(UTC)
i^love^mixery
Colonel
Joined: 10/13/2008(UTC)
Posts: 782

Thanks: 7 times
Was thanked: 201 time(s) in 147 post(s)
Finally found my derailed train of thought, put it back on track and tested the result:

- Removing the command button does not cause mismatch
- Adding the command button causes mismatch

With that in mind I tried to fix it with these two scripts:

script "add"
(active, don't deactivate upon success)
Code:

*** IF ***
    True.
*** THEN ***
  [???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Nuke_ChinaCommandCenter' in slot number  6  (1-12).
  Enable Script 'remove'.


script "remove"
(non-active, do deactivate upon success)
Code:

*** IF ***
     Player '<Local Player>' has Less Than  1  unit or structure of type 'Nuke_ChinaBarracks'
*** THEN ***
  [???] Command button: 'Command_UpgradeChinaNeutronShells' is removed from all objects of type 'Nuke_ChinaCommandCenter'.



The result was quite ridiculous.

The game was off-sync but did not mismatch. On one machine player0 built the upgrade, on the other he didn't. The player's cash was not in sync (verified). And even if player0 built a mobile nuke and used the neutrone shells the shells worked normally on both machines and the game didn't mismatch, which is absolutely surprising. Simply put, on one machine the nuke used neutrone shells without the upgrade having been built. That sounds very alarming, this solution should not be used. Cash being off-sync is a big no (imagine cash requirements for units/buildings).

Then I came up with, quite frankly put, an ingenious solution:

(active, don't deactivate upon success)
Code:

*** IF ***
     Player '<Local Player>' has Less Than  1  unit or structure of type 'Nuke_ChinaInternetCenter'
*** THEN ***
  [???] Command button: 'Command_UpgradeChinaNeutronShells' is removed from all objects of type 'Nuke_ChinaNuclearMissileLauncher'.
  [???] Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Nuke_ChinaNuclearMissileLauncher' in slot number  16  (1-12).
*** ELSE ***
   Command button: 'Command_UpgradeChinaNeutronShells' is removed from all objects of type 'Nuke_ChinaNuclearMissileLauncher'.
   Command button: 'Command_UpgradeChinaNeutronShells' is added to all objects of type 'Nuke_ChinaNuclearMissileLauncher' in slot number  6  (1-12).


Note that one time the slot number is 16, the other time it's 6.

With this trick the game does not desync, because the other machine thinks it's legit if a player built an upgrade that is being listed in slot 16, even though the upgrade is not click-able (not even through the keyboard shortcut), simply because 16 is off-limit. The AI would probably still be able to build the upgrade, but I am quite sure that doesn't matter in this case (plus I don't think AI even uses neutrone shell nukes).

There, however, is one tiny glitch:
In order to update command button positions, the object needs to be re-selected. That means: If one player has the requirements to "see" the command button, and, while having the object selected, loses the requirements, the command button will still be there and click-able until the object is re-selected. It is the same the other way around, the button is not there until the object was re-selected.

If you, absolutely positively, need to fix that tiny bug, this would be the way to force-deselect everything, but will require some more work to check if the condition changed:
Code:

*** IF ***
[prerequities changed]
*** THEN ***
  Disable mouse and keyboard input.
  Enable mouse and keyboard input.



If you are unsure why and how syncing with LocalPlayer works you might want to check this topic:
http://www.cnclabs.com/f...e-it-in-Multiplayer.aspx

Edited by user Saturday, February 9, 2019 9:54:02 AM(UTC)  | Reason: Not specified

Offline ronky  
#20 Posted : Wednesday, February 20, 2019 7:11:58 AM(UTC)
ronky
Private
Joined: 2/1/2019(UTC)
Posts: 12

@ i^love^mixery:

I added your scripts and they seem to work. I will do some online multiplayer testing to check if a mismatch will occur or not. Thanks a lot for your help, much appreciated! Your thinking is really out of the box.


I have one last problem for which you might come up with a solution.

I removed the demo bike from demo general and gave him a normal gla bike instead.

Unfortunately demo infantry units like workers can not mount the bike because it is a gla and not a demo bike.

Is there a direct or indirect way to make a demo worker be able to mount a gla bike?

Tactical need: Placing a worker on a bike and send him to the base of the enemy at the start of the game to make him build a tunnel.
Users browsing this topic
Guest
2 Pages12>
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.