Advertisement

Scriptable magic system.

Started by March 11, 2005 06:41 PM
14 comments, last by Nice Coder 19 years, 11 months ago
Nice ideas!

Perhaps, maybe have a spell hack spell, so that (depending on what your changing), you can read (which in itself takes quite some mana), and alter (which takes mana, depending on the changes you make).

Passive vs Active spells = Very nice idea.

How about manaful materials.
These would be magical things, like phenixes, dragons blood/bones/scales, ect.
Depending on how big these things are, they have a magical latency. This means that you can't destroy an active spell, for say the door-golum, by hitting it with lv4 fireballs.

Why? Things hit an equilibrium point, between the avalible mana, and the magical abilities of its core. (core= Dragons blood, ect.).

So, if you cast a 200 mana on a golum with 300g of dragons blood, then it will loose a little bit of mana (only a little, because it has a lot of mana, and the smaller amount of mana would only slightly dent it), but it would recover quickly.

If however, you nuked it with a 2M mana fireball, it would instantly insinerate (because it uses up mana faster then the core can add more too it).

Same thing would power most of the more powerful protection spells (like the spells protecting the bad guys tower, it would have drogons blood in the mortour, and it would have a spell, which is powerfull enough that it cannot be altered, or read, or destroyed. This would protect it against weaponry , exept for bigger curses which uses more dragons blood, or other mana stuff.)

Now, of cource, you can overuse the mana in a magical substance, and once you've done that, then it looses most of its magic.

From,
Nice coder
Click here to patch the mozilla IDN exploit, or click Here then type in Network.enableidn and set its value to false. Restart the browser for the patches to work.
I think the mana battery takes care of the spell core component.
Quote:
This means that you can't destroy an active spell, for say the door-golum, by hitting it with lv4 fireballs.


hehe. usually this is the case. the golem, being an active spell will lose mana when attacking or being attacked. but here lies the magic of scripting.

cast a lv5 Passive seal on the golem! the passive seal will absorb all the lv4 fireballs in the world without mana cost! the noob door golem would be:
Golem       offense:          punch (free)       defense:          rock shield for 1 mana 

casting this using a Wolf Bone (stores 100 mana) will give you a golem that can
take 100 hits. or 25 mana fireball x 4. note that it will last forever if left alone. also this is independent of the mana battery. using a dragon wing (stores 10000 mana) will give you a golem that can take a 5000 mana nuke x2!

the skilled mage will have something like
Golem      offense:            punch (free)           lightning for 5 mana           strength+100 for 50 mana           message_master for 50 mana      defense:           Passive Seal (100 mana)+100      react:      if (hostile_spell_pow > 100 mana){         cast Passive Seal (hostile_spell_pow+5) mana            cast lightning(50);      } else      {          do_nothing();      }      if (mana_battery<10)      {         message_caster("MASTER HELP ME!!")      }              


the offense and defense are the attributes of the spell. the react specifies how the spell will function. the 2nd golem will have a casting cost of 305 mana. clearly using wolf Bone will not be possible, Dragon wing is good. the golem will have initially a 100 mana seal so anything below 100 will not harm it. It will only attack when the PAssive seal is broken. It will also re-cast a more powerfull passive seal to prevent further damage. you can't just cast a 101 fireball then cast low level fireballs to drain the active spell. It will also cast lightning against the attacker. The golem will also send a message to the caster when it is about to die (extremely useful when the golem is guarding your house!)

[Edited by - yapposai on March 12, 2005 1:46:38 AM]
---------------Magic is real, unless declared integer.- the collected sayings of Wiz Zumwalt
Advertisement
:)

But the main uses for magical items, is that they regenerate mana over time!

also tags are useful.<br><br>For eg. A golum script<br><br><pre><br>Event Character_Near(char as character)<br>if char = caster then exit event<br>if self.passive.protection = null then<br> if self.mana &gt; 200 then<br> cast "Passive Protection Spell #21", 200, self.<br> else<br> dodge()<br> end if<br>end if<br>if self.mana &gt; 1000 then<br> self.Addbehaviour Chase(character)<br> Cast "Fireball", 200, character<br>else<br> Self.removebehaviour Chase(character)<br>end if<br>Dodge<br>end event<br></pre><br><br>Also, wizards do need food you know, it takes a lot of magic to make something appear out of thin air! (then again, they could just get a few golums to get the food, and the water, and keep out attackers).<br><br>also, they could be social, and they would do things, because the other person helped them in the past (was nice to them, gave them a nice discount &#111;n a spell-book, ect.)<br><br>From,<br>Nice coder
Click here to patch the mozilla IDN exploit, or click Here then type in Network.enableidn and set its value to false. Restart the browser for the patches to work.
hehe got carried away with the programming part. anyways a good UI is really needed. Using templates where you fill in the blanks seems good.

I usually look at wizards from the DragonLance books. wizards are extremely powerful but limited in use. A wizard can cast a nuke but will need several days to recuperate. here lies the balance. the concentration or stamina bar limits the number of spells a wizard can cast. he can cast 5 real good fireballs but what about the army of trolls chasing him, the wizard will still be overwhelmed since his primary weapons (spells) have run out. a warrior in a similar situation may still fight his way out. a thief may sneak out, run away.

That is why is suggested buffs as always draining mana. without buffs , wizards can be killed by mostly anyone. using buffs will drain mana possibly more and more mana as time goes by.

the spell hacking also provides alternate means to defeating some spells by looking how the spells are made up and finding a loophole.

implementing houses (see wavinator posts) also becomes feasible. give players something to protect and the means to protect these places. players will always try to get in where they are prohibited ;P it seems cool to test your character against something another person made spell.

Quote:
Coming back home and receiving lightning bolts is a bit of a giveaway that either your spell is defective or that someone has been making it defective for you, thank you very much.


true, but you probably get damaged. imagine getting home from a battle with low HP. you lower you defenses expecting a nice healing from your house, then BAM! dead by the same trap you laid out and the hacker waiting nearby to loot your corpse. having a detect skill will warn you before getting in the deadly range so you can disarm it. or a thief sneaks into your house hacking the spell but doing nothing. he could wait inside your house, or steal something and you wouldn't know. knowing that somebody changed your spell could be useful at times.


---------------Magic is real, unless declared integer.- the collected sayings of Wiz Zumwalt
Quote:
Original post by yapposai
hehe got carried away with the programming part. anyways a good UI is really needed. Using templates where you fill in the blanks seems good.

I usually look at wizards from the DragonLance books. wizards are extremely powerful but limited in use. A wizard can cast a nuke but will need several days to recuperate. here lies the balance. the concentration or stamina bar limits the number of spells a wizard can cast. he can cast 5 real good fireballs but what about the army of trolls chasing him, the wizard will still be overwhelmed since his primary weapons (spells) have run out. a warrior in a similar situation may still fight his way out. a thief may sneak out, run away.

That is why is suggested buffs as always draining mana. without buffs , wizards can be killed by mostly anyone. using buffs will drain mana possibly more and more mana as time goes by.

the spell hacking also provides alternate means to defeating some spells by looking how the spells are made up and finding a loophole.

implementing houses (see wavinator posts) also becomes feasible. give players something to protect and the means to protect these places. players will always try to get in where they are prohibited ;P it seems cool to test your character against something another person made spell.

Quote:
Coming back home and receiving lightning bolts is a bit of a giveaway that either your spell is defective or that someone has been making it defective for you, thank you very much.


true, but you probably get damaged. imagine getting home from a battle with low HP. you lower you defenses expecting a nice healing from your house, then BAM! dead by the same trap you laid out and the hacker waiting nearby to loot your corpse. having a detect skill will warn you before getting in the deadly range so you can disarm it. or a thief sneaks into your house hacking the spell but doing nothing. he could wait inside your house, or steal something and you wouldn't know. knowing that somebody changed your spell could be useful at times.


The way that i'm envisioning wizards would be that they have mana. Mana goes up and down as they do stuff/ get hurt/ make potions/ eat/ fight things/ ect.

Novices usually have 100K mana, with 1K exp.
Poor wizards have 200K mana, 2K exp.
Wizards have 300K mana, 5K exp.
Good wizards have 500K mana, 10K exp.
Great wizards have 750K mana, 50K exp,
There are a few more classes, which have 1M, 1.5M, and 2M mana respectivelly.
At 2M mana, you can basically anialate a moderatly protected city. But that would use up all your mana, reducing you to a novice.

For this reson, wizards usually have a mana storehouse in there houses (which is connected to the defences, so if your attacking the house of a really good wizard, then you have defences which can fire 2Mm (2 mega mana) nukes at you, and deflect the blasts easily (because it has a few billion collected mana.)

However if your just training, then you would only have 100K mana on you, and your house would have 50-100K mana too, so it could defend itself against other classes (which are slightly magical, and can also have mana, they just don't get as much of it, and require more experience in order to be able to do things properly), but against a stronger wizard, these things will simply be blown away.

See where this is going?

You would have your village 'wizards' which are basically savants, so they do all the magic in the buildings. Making lights that don't wear out, doing tricks, making defencive structures, ect. These would probably stay near the novise (because you have a potential, which is random in the character itself, so you won't get past say 300K mana most of the time, no matter how hard you try), so it will be able to do a few things, but not a whole lot, and i've used, too, many, commas, in, this, sentance, so, i'll, stop, right, about,,,,,, now.

From,
Nice coder
Click here to patch the mozilla IDN exploit, or click Here then type in Network.enableidn and set its value to false. Restart the browser for the patches to work.

This topic is closed to new replies.

Advertisement