Page 1 of 5

Chronomancy Development

Posted: Thu Sep 23, 2010 5:34 pm
by edge2054
The main purpose of this thread is for me to get some feedback and help with the development of the Chronomancy meta-class. For more information concerning Chronomancy please refer to the following threads.

http://forums.te4.org/viewtopic.php?f=39&t=22109
http://forums.te4.org/viewtopic.php?f=39&t=22174
http://forums.te4.org/viewtopic.php?f=39&t=22138
http://forums.te4.org/viewtopic.php?f=39&t=22151

So far I have 9 talents coded (hacked!! I mean!!) and one completed talent tree with two more that are nearly done.

I'd like to get the following two talents done but I'm stuck on where to begin.

Damage Smearing
Activated talent that spreads incoming damage out over several turns. Similar to Time Shield but without the absorption effect. I figure the way to do this will be to set it up so incoming damage is negated and then split into self inflicted arcane damage. It needs to stack and I imagine the meat of this talent will end up in timed-effects and/or combat.

Avoid Fate
Passive. As long as your current hit point total is at least 60-(Spellpower*TL/10)% of your maximum any single attack that reduces you below 1 hit point instead reduces you to 1 hit point. Guessing the meat of this one will have to take place in actor or combat. Thinking this will need to be something like if hit points > = talent effect incoming damage can not exceed current hit points + 1.

Thoughts?

Re: Chronomancy Development

Posted: Thu Sep 23, 2010 5:59 pm
by Susramanian
The numbers for Avoid Fate look fishy. If we assume an endgame chronomancer has 100 spellpower (I'm really not sure what an appropriate number is; Archmages have way more than this) and 5 points in Avoid fate, then 60-(Spellpower*TL/10)% = 60-(100*5/10) = 60-50 = 10. So as long as the chronomancer is above 10% health, killing blows don't kill them? I know a second blow would do the job, so Avoid Fate doesn't mean indestructibility. But nudge the numbers up a bit and you could start getting 60-(Spellpower*TL/10)% down to 0, meaning true indestructibility.

I know you were probably looking for help with the coding, but I know next to nothing about it.
Did you learn what you know about Lua by messing with T4? Lately I've been having urges to code my T4 ideas, but I'm all too aware of my programming ability: craptacular. But if you've figured enough out to put together an entire new class complete with new mechanics, then it gives me hope :)

Re: Chronomancy Development

Posted: Thu Sep 23, 2010 6:07 pm
by edge2054
Yeah, I did. As to the numbers I'm double checking all the math as I go along. The cap on Avoid Fate should be 10%.

Re: Chronomancy Development

Posted: Mon Sep 27, 2010 12:11 am
by yufra
edge2054 wrote: Damage Smearing
Activated talent that spreads incoming damage out over several turns. Similar to Time Shield but without the absorption effect. I figure the way to do this will be to set it up so incoming damage is negated and then split into self inflicted arcane damage. It needs to stack and I imagine the meat of this talent will end up in timed-effects and/or combat.
I think you are right, use Time Shield as inspiration. Instead of splitting the effect into two components (one for absorbing damage, one for giving it back) create a single timed effect. The "power" of this effect would start at zero, and the effect's "on_timeout" function would check the power and if it is greater than zero then deal damage to the player (like TIME_DOT). The exact mechanics of this section are a bit fuzzy in my head... nevermined, see the code below. :D Add a check for "damage_smearing" attribute in mod.class.Actor:onTakeHit and increase the effect's power by the damage while zeroing out the "value" to remove the original damage.

Code: Select all

	on_timeout = function(self, eff)
		local damage = eff.power / eff.dur
		eff.power = eff.power - damage
		DamageType:get(DamageType.ARCANE).projector(self, self.x, self.y, DamageType.ARCANE, damage)
	end,
Avoid Fate
Passive. As long as your current hit point total is at least 60-(Spellpower*TL/10)% of your maximum any single attack that reduces you below 1 hit point instead reduces you to 1 hit point. Guessing the meat of this one will have to take place in actor or combat. Thinking this will need to be something like if hit points > = talent effect incoming damage can not exceed current hit points + 1.
I would also put this in mod.class.Actor:onTakeHit, and your suggestion sounds good to me, just reduce value to "self.life - 1". Good luck!

Re: Chronomancy Development

Posted: Mon Sep 27, 2010 2:12 am
by edge2054
Thanks Yufra!! :)

By the way Wormhole almost works. The way we had it written up the targeted version worked fine. I tweaked it a bit and thought I'd just use the teleport code and now only the random version works right >.>.

I'm sure I'm missing something obvious but the wormholes themselves are fine, the targeting is just getting it's wires crossed someplace. i.e. the meat of it is good, you can port back and forth and even swap places with creatures ;)

*minor bug though, it won't put the stairs back if you make a wormhole on the stairs*

Re: Chronomancy Development

Posted: Sun Oct 03, 2010 12:41 pm
by edge2054
Thanks to yufra's help and my wife's willingness to take care of a teething seven month old while I hung out on the computer wormhole now works!!

The tile could use some help though, it's using the maze portal tile right now which looks pretty tacky on grass.

If anyone would like to contribute a tile that'd be awesome. The spell works much like stone wall, replaces a patch of floor with something else, in this case a wormhole you can use to travel to the exit wormhole.

Tonight I think I'll try to get Damage Smearing done to finish up that tree.

Re: Chronomancy Development

Posted: Sun Oct 03, 2010 5:13 pm
by Mushroomhermit
As requested...

Image

Hope this suits your needs.

Re: Chronomancy Development

Posted: Sun Oct 03, 2010 5:14 pm
by darkgod
Neat :)

Re: Chronomancy Development

Posted: Sun Oct 03, 2010 8:08 pm
by edge2054
Thanks Mushroom :)

Re: Chronomancy Development

Posted: Sun Oct 03, 2010 9:12 pm
by edge2054
Any suggestions on how I incorporate the above graphic? It ends up being a blackhole on a black tile.

Code: Select all

local entrance = mod.class.Object.new{
            old_feat = game.level.map(self.x, self.y, Map.TERRAIN),
            name = "wormhole", image = "terrain/wormhole.png",
            display = '&', color_r=255, color_g=255, color_b=255, back_color=colors.STEEL_BLUE,

Re: Chronomancy Development

Posted: Sun Oct 03, 2010 9:50 pm
by Shoob
edge2054 wrote:Any suggestions on how I incorporate the above graphic? It ends up being a blackhole on a black tile.

Code: Select all

local entrance = mod.class.Object.new{
            old_feat = game.level.map(self.x, self.y, Map.TERRAIN),
            name = "wormhole", image = "terrain/wormhole.png",
            display = '&', color_r=255, color_g=255, color_b=255, back_color=colors.STEEL_BLUE,

Code: Select all

local entrance = mod.class.Object.new{
            old_feat = game.level.map(self.x, self.y, Map.TERRAIN),
            name = "wormhole", image = old_feat.image,
            add_displays = {mod.class.Grid.new{image="terrain/wormhole.png", dislpay_on_seen=true, display_on_remember=true} },
            display = '&', color_r=255, color_g=255, color_b=255, back_color=colors.STEEL_BLUE,
try that... (if I am reading that to old_feat is the old terrain feature, correctly)

There are probably other ways to do it as well.

Re: Chronomancy Development

Posted: Sun Oct 03, 2010 10:04 pm
by edge2054
Yeah, DG sold me on the idea of making it a trap instead.

Which'll add a lot more utility to the spell.

*studies up on the trap code*

Re: Chronomancy Development

Posted: Wed Oct 06, 2010 5:03 am
by edge2054
Still haven't finished up wormhole but did manage to get the Gravity tree done over the last couple of days. Not even going to pretend it's balanced yet but all my spell effects are working.

Here's a screenshot of some of the talent trees.

Re: Chronomancy Development

Posted: Wed Oct 06, 2010 4:25 pm
by yufra
Edge, I was just thinking about wormhole and realized that we need to check for no_teleport flags to make sure we don't accidentally end up inside of a vault. There is also the teleport flag specific to Mount Doom that we probably need to look at.

Re: Chronomancy Development

Posted: Sun Oct 10, 2010 12:05 am
by edge2054
Yeah, you're right. We'll have to get together on IRC and finish that talent up when we both have time again.