SkyMix_RMT
8 years ago
Basically I'm trying to make a prototype of a CO-OP mission map, but everything I give to the AI it just sells it, even when I tried to remove the commandbutton from the buildings, or give them the unsellable flag.

Is there anyway to stop the AI from selling every building I transfer to it?

Through scripting only.

Thanks
Check out:
My Music  (Techno/House/Experimental)
My Website  (GeneralsCentral)
My Youtube Channel  (Inactive)
World Builder Community Discord 
Sponsor
i^love^mixery
8 years ago
Hi,

(as far as I remember)

Simply put: No. Every building you transfer will be sold. That is absolutely hard-coded and was probably done for black lotus sneak attacks in singleplayer to prevent bugs after buildings have been captured by her. Even if you use a microwave tank to attack the building, the comp will still sell it when it is transfered, even though selling a building that was disabled by a microwave tank is impossible for human players.

The only way to create buildings for the AI is to spawn them by script, either on a waypoint or to specific coordinates. That works fine and should do the trick.

You could check out one of my old maps if you are into CO-OP missions:
https://mega.nz/#!kQlCUapQ!e6E3ys83NoiZcPvvyEHK7XAqkU13NBAt214poBAAs80 
SkyMix_RMT
8 years ago
I've already played that one with a bunch of friends. They didn't enjoy it as much as I did though so I never played it again. It is a really well crafted map though.
Check out:
My Music  (Techno/House/Experimental)
My Website  (GeneralsCentral)
My Youtube Channel  (Inactive)
World Builder Community Discord 
i^love^mixery
8 years ago
Yea... it tends to be quite frustrating, it's very difficult and gets even more difficult when there are many players.

But it's a good map to learn scripting tricks from. I pretty much put everything I ever found out to be possible with scripts into the map. I wasn't done, tho. I still have newer versions with some new missions that ended up being too hardcore even for my taste and thus didn't make it through the closed beta test. Maybe at some point in the future I will balance the map out, make it fully Gentool compatible (there's a cam bug in one mission caused by gentool) and make a final release.

But currently I got actual things to get coded, far more complicated than zh maps.
SkyMix_RMT
8 years ago

The only way to create buildings for the AI is to spawn them by script, either on a waypoint or to specific coordinates. That works fine and should do the trick.

Originally Posted by: i^love^mixery 



Alright I tried this but the game just crashes as soon as I start the map.

The script goes:

*** IF ***
True
*** THEN ***
Spawn Unit 'LD-StingerSiteBottom' of type 'GLAStingerSite' on team Team 'teamSkirmishGLA' at position ((651.25,1175.44,0.00)), rotated 0.00 degrees .

I have a GLA Easy army on the game so this should work. But it doesn't, do you happen to know why?

EDIT:
I fixed the crash, I just forgot that the script must be inside the SkirmishGLA folder, now the game doesn't crash, but the stingersite doesn't spawn...

EDIT2:
It looks like the script isn't even activating because I made it show military briefing String "test" for 5000 miliseconds and it doesn't!

EDIT3:
Alright, I fixed everything, weird though, all I did was delete all players and click "Add Skirmish Players" re-do the script and it worked, I don't undestand why it wasn't working earlier....
Check out:
My Music  (Techno/House/Experimental)
My Website  (GeneralsCentral)
My Youtube Channel  (Inactive)
World Builder Community Discord