Author Topic: Physics of Magic  (Read 22974 times)

Trowel

  • Newcomer
  • Posts: 10
  • Karma: +0/-0
    • View Profile
Physics of Magic
« on: November 17, 2013, 10:54:51 PM »
Well it's been a while since I posted here (real life got in the way) but I've got some free time on my hands now and wanted to put it towards making a roguelike with a difference.

I've always been interested in 'pseudo-physics', as a kid I would draw up a bunch of physics theories for everything from time travel to the creation of an entire universe.. Though being terrible at maths it was of course all made up. But of course what makes sense in real life, doesn't necessarily limit what can make sense in a video game ...

And that got me thinking about magic. What if I created a roguelike world where magic logically existed and had it's own set of coherent properties that actually were actually based on 'magic physics'.. Eg: Rather than a magic missile firing in a straight line because I pressed a key, how about the missile being composed of a structure of magic particles which can be affected by the environment as much as the caster.

So what about having a particle that represented 'thrust', which is bound to a particle which produces a huge amount of 'energy' when it 'decays', thus in simple terms, creating a magic missile. But what if each of these particles had 'spin' and could destabilise each-other under certain conditions by 'spinning themselves apart', that is another logical way the spell energy could be created. And it could have interesting effects if for example we have an 'interdimensional particle' which spins in harmony with time and space. Imagine if that particle was ripped apart, it could create a tear in time, giving us a logical reason for a portal to appear, or teleport etc.

It probably all sounds crazy and I'm not explaining it well at all (don't write posts when your tired), but I'm thinking of turning this all into a game. I just wondered if anybody had any thoughts for where else I could go with this sort of theme, my current thinking is to integrate it with the plot so at least all of this 'complexity' has a purpose and becomes a part of the game rather than an unnecessary chore.

Perhaps I'll come refine the idea when I'm feeling more awake, until then feel free to laugh at my craziness and imagine my torment trying to implement quantum physics into a roguelike..  :'(

Gr3yling

  • Rogueliker
  • ***
  • Posts: 168
  • Karma: +0/-0
    • View Profile
    • Email
Re: Physics of Magic
« Reply #1 on: November 17, 2013, 11:42:18 PM »
I just want to say that I think this is a great idea.  It sounds like it has potential.

Quendus

  • Rogueliker
  • ***
  • Posts: 447
  • Karma: +0/-0
  • $@ \in \{1,W\} \times \{1,H\}$
    • View Profile
    • Klein Roguelikes
Re: Physics of Magic
« Reply #2 on: November 18, 2013, 05:40:16 AM »
I toyed with an idea a bit like this a while back - there were particles of magic flying around the map, and you could draw symbols on the map to influence how they behaved. Instead of standing in place and casting a spell, you would move around drawing symbols that made the particles do something that accomplished your goals. The particles could change between different energy states and magic types (standard four elements plus a few other things).

I never put gameplay into this toy system because there was a big problem with it - accomplishing anything in the system meant a lot of walking around doing things that had no immediate effect, during which time any opponent would be either at your throat or miles away from the target tile. An AI opponent working in the same system would be a total pushover, and an opponent who could interfere with your work would make it impossible to get anything done. It probably would have been more suited to a puzzle game.

There's definitely potential in this kind of idea though - I'd like to see what your version looks like (and if it's more suited to a tactics game).

Samildanach

  • 7DRL Reviewer
  • Rogueliker
  • *
  • Posts: 453
  • Karma: +1/-0
    • View Profile
    • The Indie Ocean
Re: Physics of Magic
« Reply #3 on: November 18, 2013, 12:39:00 PM »
I like the idea, though I'm not sure how it would be implemented. I'm definitely keen to see anything that comes of this.

Xecutor

  • 7DRL Reviewer
  • Rogueliker
  • *
  • Posts: 263
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #4 on: November 18, 2013, 02:50:54 PM »
Thinking about it theoretically is surely fun. But putting all this together in a consistent way is hard job.
And once you will have more or less consistent system, another problem will appear. Balance.
'User made magic' systems tent to be really hard to balance.

I will surely like to see a complete game of this kind someday :)

Vanguard

  • Rogueliker
  • ***
  • Posts: 1112
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #5 on: November 18, 2013, 04:42:42 PM »
Thinking about it theoretically is surely fun. But putting all this together in a consistent way is hard job.
And once you will have more or less consistent system, another problem will appear. Balance.
'User made magic' systems tent to be really hard to balance.

What's even more difficult is making them mechanically compelling.  But on the other hand, it's really easy to thematically justify any mechanics you come up with.  That's why it's better to start with a good set of rules and grow a setting around them than the other way around.

Trowel

  • Newcomer
  • Posts: 10
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #6 on: November 22, 2013, 06:00:23 AM »
Thanks for the responses guys and sorry I'm so late in replying to this! I've been really busy working on a Drupal project that is just eating up my free time. As soon as I get that project out of the way I'll try to get a demo up, just something to toy around with ;)

I toyed with an idea a bit like this a while back - there were particles of magic flying around the map, and you could draw symbols on the map to influence how they behaved. Instead of standing in place and casting a spell, you would move around drawing symbols that made the particles do something that accomplished your goals. The particles could change between different energy states and magic types (standard four elements plus a few other things).

That sounds pretty fun actually. My thinking was rather more boring I'm afraid. I was thinking of creating some kind of 'visual magic editor' which you could unlock in the game and that would allow you to combine various components into spells. I haven't really figured out the exact implementation yet though, I might extend it into being a central game-play mechanic if I can think of a way for that to be possible. Currently though I'm just thinking of having spells that can be influenced by symbols or by the environment etc. So you might fire a spell only for it to pass over some hidden symbol and explode into several different missiles killing several monsters in the area but injuring yourself as well.

Thinking about it theoretically is surely fun. But putting all this together in a consistent way is hard job.
And once you will have more or less consistent system, another problem will appear. Balance.
'User made magic' systems tent to be really hard to balance.

Really good point here actually, balance will probably be the most difficult thing to implement. Creating your own spells could be fun but how would you stop someone from creating a 'super spell' which they could just recreate each time. One idea I had is that the more powerful spells might have an element of 'corruption' to them, meaning they could lower your accuracy each time they're used.

Or how about spells that degrade over time. Who says magic stored in a wand or staff can't decompose? Think of it a bit like lighting a ten year old firework, sure it could make a pretty display but there will be a bigger chance that it will miss-fire. Perhaps this could be a way to add a strategy element to spell selection? (though it could just get annoying, like another form of food clock).

Thinking about it theoretically is surely fun. But putting all this together in a consistent way is hard job.
And once you will have more or less consistent system, another problem will appear. Balance.
'User made magic' systems tent to be really hard to balance.

What's even more difficult is making them mechanically compelling.  But on the other hand, it's really easy to thematically justify any mechanics you come up with.  That's why it's better to start with a good set of rules and grow a setting around them than the other way around.

Another good point actually, how can you make a system that is both compelling and yet simple enough to operate with just a few keybindings? I think to a certain degree some clever on screen 'visual effects' can add excitement to an otherwise straightforward system. One thing I like the idea of that I haven't seen implemented is chain reactions. I like the idea that a spell can bounce off a wall, taking a chunk out of it and take out several monsters before exploding in the middle of the dungeon.

As has been pointed out already in this thread though, it's all ok to sit here and type up all these 'great' ideas but there is probably a good reason why they haven't been implemented yet and it's not because people haven't thought of them already :)

Vanguard

  • Rogueliker
  • ***
  • Posts: 1112
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #7 on: November 22, 2013, 09:49:06 AM »
One thing I like the idea of that I haven't seen implemented is chain reactions. I like the idea that a spell can bounce off a wall, taking a chunk out of it and take out several monsters before exploding in the middle of the dungeon.

Spelunky is really good at this.  It's full of simple objects that interact with each other to produce complex effects.  Like, you might throw a rock at a monster, accidentally set off an arrow trap, and watch as the arrow strikes a box of explosives that detonates and kills the damsel you were trying to rescue.

akeley

  • Rogueliker
  • ***
  • Posts: 348
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #8 on: November 23, 2013, 10:20:34 AM »
Like, you might throw a rock at a monster, accidentally set off an arrow trap, and watch as the arrow strikes a box of explosives that detonates and kills the damsel you were trying to rescue.

If this is a real example, I might give it another chance. I`ve a phobia of platformers and while I play them occasionally, they`re always on my gaming  backburner. But I`m a sucker for emergent gameplay so this sounds pretty cool.

Vanguard

  • Rogueliker
  • ***
  • Posts: 1112
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #9 on: November 23, 2013, 05:38:44 PM »
That example is 100% real.  Spelunky is full of naturalistic Rube Goldberg devices.  The commercial version does them better, but the freeware Spelunky is still good at it.

Hulander

  • Newcomer
  • Posts: 1
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #10 on: November 27, 2013, 07:39:37 PM »
I think this is a really cool idea. Another game that made player created spells fun was Magicka, although that was more of a party game I still think it would be possible to modify the concept so it plays well in other types of game. For instance instead of having an infinite amount of spell power each spell type would be considered a resource. I think this would make the game a bit more interesting since the player would need to figure out the best spell to use at a given time instead of just casting the same spell over and over.

One way to avoid the super spell would be to add some kind of danger element to spells, like the more effects you add to a spell the more dangerous its for the player to use it. This would allow the player to create crazy spells but they would probably not survive after they used it.

Quendus

  • Rogueliker
  • ***
  • Posts: 447
  • Karma: +0/-0
  • $@ \in \{1,W\} \times \{1,H\}$
    • View Profile
    • Klein Roguelikes
Re: Physics of Magic
« Reply #11 on: November 28, 2013, 04:33:12 AM »
The podcast is a bit long, but there are some parallels between spell customisation and unit customisation in strategy games: http://flashofsteel.com/index.php/2012/07/23/three-moves-ahead-episode-178-unit-customization-and-game-design/

Krenium

  • Newcomer
  • Posts: 14
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #12 on: December 02, 2013, 12:57:10 PM »
I have put a lot of thought into this topic. I mean a lot. One thing I've always wanted to do is create a roguelike where you are tasked with researching magic. Everyone always goes on and on in their games about how wizards attend academies and study diligently. And I think to myself, wouldn't it be rewarding if the player actually had to research and discover magic for himself?

I've always wanted to tie linguistics into it. For instance, maybe the aspiring mage says the word "peh" out loud and he notices that the air around him seems a little warmer. He investigates further by saying "pehra" and the effect seems to be strengthened. He adds the word "rhi" in front which has proven to strengthen the effects of most magic in past experiments, and suddenly he has discovered a spell to keep himself warm on the most frigid of nights! Now he has learned a spell which he can call on time and time again. His learning wasn't constrained by some skill tree and his experience isn't denoted by XP; he learned the spell through experimentation and he is naturally more experienced as a result.

I eventually came to the conclusion that a convincing procedurally-generated system like this must be based upon a strongly axiomatic system. Thinking of it in terms of physics and particles could be a clever way to model this. This particle always travels against gravity. This particle has a half-life of 10 turns. That particle exerts a strong force on others around it. When this particle and this particle collide, it creates a new particle and releases energy. Simple rules often have profound influences and can be used to build unexpected things. The key is to let the player have access to this power, unhindered by cumbersome interfaces and overly-prescriptive rules and abilities.

Regarding the topic of spamming "super spells:" I agree this can diminish the fun and novelty of any game. I can't remember where I first came across the concept—I believe it may have been an anime?—but there was this universe where saying a word out loud caused a magical spell, but no one was physically able to speak that word ever again. It simply vanished from existence at that point. I found the concept to be utterly fascinating. However, this would negate the benefit of discovery, so perhaps a compromise could be made: each successive use of a spell diminishes its potency, so eventually you have to branch out to other things. But in the mean time, you can leverage your discovery.
« Last Edit: December 02, 2013, 01:14:05 PM by Krenium »

Krenium

  • Newcomer
  • Posts: 14
  • Karma: +0/-0
    • View Profile
Re: Physics of Magic
« Reply #13 on: December 02, 2013, 01:12:33 PM »
(Double-post; sorry!)

AgingMinotaur

  • Rogueliker
  • ***
  • Posts: 805
  • Karma: +2/-0
  • Original Discriminating Buffalo Man
    • View Profile
    • Land of Strangers
Re: Physics of Magic
« Reply #14 on: December 02, 2013, 01:23:53 PM »
I eventually came to the conclusion that a convincing procedurally-generated system like this must be based upon a strongly axiomatic system. [...] Simple rules often have profound influences and can be used to build unexpected things. The key is to let the player have access to this power, unhindered by cumbersome interfaces and overly-prescriptive rules and abilities.
Interesting. I remember the point'n'click adventure game Loom had a system where you learned to weave new spells, each spell consisting of a series of notes. There were even some puzzles where you reversed the effect of a spell by playing it backwards. Of course, this was all fixed content, and a system where some of the axioms are randomized for each playthrough could be quite cool, providing something akin to your typical identification subgame.

As always,
Minotauros
This matir, as laborintus, Dedalus hous, hath many halkes and hurnes ... wyndynges and wrynkelynges.