Could someone help me with modifiing Chimera cannons?

Started by Ondrejoda, June 12, 2017, 01:40:29 AM

Previous topic - Next topic

Ondrejoda

Can I change the code that it can locate Creeper and shoot AC, when AC Ammo is in the cannon?

Ondrejoda

Because i would like to change the code to be an ally that it will shoot AC onto the creeper.

GoodMorning

I don't know the original mission, so I can do little for you.
A narrative is a lightly-marked path to another reality.

Ondrejoda

If you did win the story mode, it is in the "Alpha Sector":wirgilw:Chimera, and i can post the code too, but not now. Sorry. (and could you check my other topic?)

GoodMorning

Yes, but recreating is probably easier than modifying.

Something like...


$Capacity:100
$ShotAmount:10

once
@InitialiseFiringState #Time until armed, ammunition level, capacity, connectability, etc...
@SetupGraphics
endonce

Self CONST_AMMOAC GetUnitAttribute <-ShotAmount gte if
@FindTargetCreeperCell
<-CreeperInRange if
@CreateProjectile
@BarrelRecoil
Self CONST_AMMOAC dup2 GetUnitAttribute <-ShotAmount sub SetUnitAttribute
endif
endif
A narrative is a lightly-marked path to another reality.