Knuckle Cracker

Creeper World 3 => The Coder's Corner => Topic started by: Nebulous on May 14, 2016, 12:00:22 AM

Title: New Units
Post by: Nebulous on May 14, 2016, 12:00:22 AM
Can you specifically make units that the player can use like a normal unit that reacts to something differently?
Title: Re: New Units
Post by: Builder17 on May 14, 2016, 03:17:14 AM
That requires lot of CRPL coding , but if you want keep normal units as well just don't activate alternative control mode.

Some links about this: https://knucklecracker.com/forums/index.php?topic=17895

https://knucklecracker.com/forums/index.php?topic=16270

So it's maybe easier to use normal unit and CRPL core attached into it.

Explain more about your idea , please.

Edit: Something like this makes CRPL core follow player unit.

Self CONST_NULLIFIERDAMAGES FALSE SetUnitAttribute
Self CONST_TAKEMAPSPACE FALSE SetUnitAttribute
Self CONST_CREATEPZ FALSE SetUnitAttribute
Self CONST_SUPPORTSDIGITALIS FALSE SetUnitAttribute
Self CONST_COUNTSFORVICTORY FALSE SetUnitAttribute
#ClearTraceLog
#ShowTraceLog
CurrentCoords GetUnitAt ->Unit
endonce

<-Unit CONST_COORDX GetUnitAttribute ->CX
<-Unit CONST_COORDY GetUnitAttribute ->CY
#<-CX <-CY Trace2
<-CX <-CY SetCurrentCoords
Title: Re: New Units
Post by: GoodMorning on May 14, 2016, 05:56:18 AM
Agreed. Possible but very lengthy. So much that even the Sleeper uses a Digitalis workaround.
Title: Re: New Units
Post by: Nebulous on May 14, 2016, 09:37:29 AM
Thanks! I'll check these out!