Player doesn't capture CP

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
DaviidHL
Private Third Class
Posts: 52
Joined: Thu Apr 05, 2018 11:48 am
Projects :: Kashyyyk Droid Invasion
Games I'm Playing :: SWBF2
xbox live or psn: DaviidHL_

Player doesn't capture CP

Post by DaviidHL »

I know how to disable Cp capture for the IA

Code: Select all

AICanCaptureCP("cp2", ATT, false)
But I don't know how to disable the capture for Player, there's a command for disable and respawn regions?
User avatar
Oceans14
Command Sergeant Major
Command Sergeant Major
Posts: 296
Joined: Mon Apr 27, 2015 7:09 pm
Projects :: Athenova Campaign
Games I'm Playing :: SWBF2
Location: Planet 4546b

Re: Player doesn't capture CP

Post by Oceans14 »

You should be able to use ActivateRegion() and DeactivateRegion(), but I haven't tried these on capture regions.

Another possible solution would be to use SetClassProperty to change the capture region value for a particular CP to "". Then the region would stay but not be associated with anything - I think. I've never tried it myself.
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Player doesn't capture CP

Post by Marth8880 »

Oceans14 wrote:Another possible solution would be to use SetClassProperty to change the capture region value for a particular CP to "". Then the region would stay but not be associated with anything - I think. I've never tried it myself.
Quick note: you can't set it to an empty string, so a good alternative is " ".
Post Reply