From 50ffbf0f455f1ff34e98f0bdac3b7a9bf09d9192 Mon Sep 17 00:00:00 2001 From: Mittendrein Markus Date: Sun, 14 Feb 2016 18:10:24 +0100 Subject: Colorize Scrolls with a color specific to their "magic element" --- TemplePushing.c4s/System.c4g/MagicAir.c | 17 +++++++++++++++++ TemplePushing.c4s/System.c4g/MagicEarth.c | 11 +++++++++++ TemplePushing.c4s/System.c4g/MagicFire.c | 11 +++++++++++ TemplePushing.c4s/System.c4g/MagicWater.c | 10 ++++++++++ TemplePushing.c4s/System.c4g/Scroll.c | 6 ++++++ 5 files changed, 55 insertions(+) create mode 100644 TemplePushing.c4s/System.c4g/MagicAir.c create mode 100644 TemplePushing.c4s/System.c4g/MagicEarth.c create mode 100644 TemplePushing.c4s/System.c4g/MagicFire.c create mode 100644 TemplePushing.c4s/System.c4g/MagicWater.c (limited to 'TemplePushing.c4s/System.c4g') diff --git a/TemplePushing.c4s/System.c4g/MagicAir.c b/TemplePushing.c4s/System.c4g/MagicAir.c new file mode 100644 index 0000000..2c4a60d --- /dev/null +++ b/TemplePushing.c4s/System.c4g/MagicAir.c @@ -0,0 +1,17 @@ +/*-- No color-modulation for scrolls --*/ +#strict 2 +#appendto ABLA +#appendto MBOT +#appendto GVTY +#appendto MLGT +#appendto CFAL +#appendto MINV +#appendto MDFL +#appendto AFST +#appendto MATT +#appendto TSHL + +func ScrollColor() +{ + return RGB(255, 255, 255); +} diff --git a/TemplePushing.c4s/System.c4g/MagicEarth.c b/TemplePushing.c4s/System.c4g/MagicEarth.c new file mode 100644 index 0000000..ab71cfd --- /dev/null +++ b/TemplePushing.c4s/System.c4g/MagicEarth.c @@ -0,0 +1,11 @@ +/*-- Green color for scrolls --*/ +#strict 2 +#appendto MSSH +#appendto MARK +#appendto MGPL +#appendto MGCY + +func ScrollColor() +{ + return RGB(0, 192, 0); +} diff --git a/TemplePushing.c4s/System.c4g/MagicFire.c b/TemplePushing.c4s/System.c4g/MagicFire.c new file mode 100644 index 0000000..5a09c55 --- /dev/null +++ b/TemplePushing.c4s/System.c4g/MagicFire.c @@ -0,0 +1,11 @@ +/*-- Red color for scrolls --*/ +#strict 2 +#appendto MDBT +#appendto MFRB +#appendto LAVS +#appendto MGFL + +func ScrollColor() +{ + return RGB(255, 0, 0); +} diff --git a/TemplePushing.c4s/System.c4g/MagicWater.c b/TemplePushing.c4s/System.c4g/MagicWater.c new file mode 100644 index 0000000..39abd7a --- /dev/null +++ b/TemplePushing.c4s/System.c4g/MagicWater.c @@ -0,0 +1,10 @@ +/*-- Blue color for scrolls --*/ +#strict 2 +#appendto MFWV +#appendto ICNL +#appendto MICS + +func ScrollColor() +{ + return RGB(0, 0, 255); +} diff --git a/TemplePushing.c4s/System.c4g/Scroll.c b/TemplePushing.c4s/System.c4g/Scroll.c index 7cf2ee1..15ae5e0 100644 --- a/TemplePushing.c4s/System.c4g/Scroll.c +++ b/TemplePushing.c4s/System.c4g/Scroll.c @@ -45,3 +45,9 @@ private func DoMagic(object pByClonk) SetVisibility(VIS_Owner | VIS_Allies, this); return _inherited(pByClonk); } + +func SetSpell(id spell) +{ + SetClrModulation(spell->~ScrollColor()); + return _inherited(spell, ...); +} -- cgit v1.2.3-54-g00ecf