For new spells

Messages are moved here (should anyone ever want to see them again) once they are no longer applicable to the current version (e.g. suggestions that have been implemented or bugs that have been fixed).

Moderator: George Gilbert

Forum rules
Please read the Forum rules and policies before posting. You may Image to help finance the hosting costs of this forum.
Post Reply
User avatar
beowuuf
Archmastiff
Posts: 20686
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

For new spells

Post by beowuuf »

Firstly, creating new spells will rely on having the engines effects for spells broken down into basic small blocks of code. If the RTC engine doesn't have this (ie poison cloud is just one routine) then this probably won't ever come to anything : (

It seems that spells have several componennts:

1) Targetting. There seems to be five - targetting a party member, the party, a square (with the special case of constantly targetting the square -magic footprints, magic window all constantly generate effects), targetting by missile, and none (light, potions all mave no real target)

2) Checking for (and relacing) objects. Potions are the biggest one for this, needing a flask in hand and replacing it with the potion. ZOKATHRA needs nothing, but creates the rock in the hand if possible, and future spells might want other objects present

3) Effects - split into:

a) Upping an individual party stat (potions do this, or course).
b) Upping the party stats (aura of strength, fireshields)
c) Creating a temporary object on a floor tile (footprints, fluxcage, fuse blast, the window effect.graphic)
d) Changing some game property (lighting - but it's conceivable to alter sound level, game speed, party speed)
e) Missile effect - which really consists of creating a flying object with a graphic, that generates one of the other effect on the tile/creature it hits
f) Damage generated, one or a combination of the blunt/sharp/fire types

Obviously unless effects are hard coded, then lots of things can't be done. For example, invisiblity and remove invisibility would have to be included, something as complex as a magic window could not be done. But still having the range of effect already available, in sopme form that is easy to reference, would make lots of spells possible.

The next part would be how to code new spells. In this respect possibly the language can be left as is, and it's up to the designer to have to create the referencing master code block, until someone can come up with a good interface programme.
Was unable to (permenantly) kill off ian_scho (Haynuus), Ameena, oh_brother (Westian), money (Falkor), raixel (Petal) and Lord_Bones (Aurek) in the DM D&D game Time's Champions!

CONGRATULATIONS TO THOSE WHO MADE THE GAME WHAT IT WAS - GREAT!
User avatar
amaprotu
Adept
Posts: 211
Joined: Thu Jan 25, 2001 9:47 pm
Location: California, USA
Contact:

Re: For new spells

Post by amaprotu »

I would love to have a scriptable spell engine, however I think it would be a lot of work.

The way you have things set up they seem (to me) to overlap a lot. At least one and thee do and two is dependant on those.

Don't forget that you need also to be able to specify which runes create the spell and what class you need and what skill level. A possible script that would cover everything I think is (based on your ideas):

[Fireball]
runes=3,3
class=wizard
skill=1000 (obviously a random guess)
checkfor=none
summon=none
type=missle
power=1 (base damage for lowest spell?)
graphic=fireball.gif (or whatever)
sound=fireball.wav

I also think, however, for this to work the best multiple effects need to be possible, in other words more than one type and damage field. The simplist I can think of (for George) would be one along the lines of:

[Fireball]
runes=3,3
class=wizard
skill=1000 (obviously a random guess)
effect1=fireball
effect2=none
power1=1
power2=0

All spells already existing would have their own effects. Power is a factor applied to the standard power of the effect, ie a power1=2 would do a fireball that did twice the damage. This way the only new spells that could be created would be combinations of existing ones, or different strengths of existing ones. I would like additional effects however (of course) like move party forward/back (only one effect would be needed, just use a negative power) etc. With this method any checks for items etc. would be coded into the effect, which isn't as flexible but maybe easier for George.

One idea would be to have an effect summon which required the two aditional fields checkfor and summon. With this you could theoretically create spells that summoned arrows for you or upgraded arrows to more powerfull ones etc.

Just my thoughts

- Amaprotu
- Amaprotu
User avatar
beowuuf
Archmastiff
Posts: 20686
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Re: For new spells

Post by beowuuf »

I was envisaging it being more work for the designer so less for Geoerge. Maybe to the point of actually being able to state the raw sub-programmes that need to be called (ie George relaeses the names and properties needed for each possible effect. Say, boosting the party as partyboost(stat, number, duration).

Also, having to define each level of spell (lo, um...), so that you can code extra effects for higher level spells, or spells that will only work if large mana symbols are put in. Also, unique monster effects can be created as spells - not including a power symbol would make it impossible for characters to access them.

As I think your original posting waaaay back had effects spilt into each effect called the same runes, and all would be cast at once - which would be good. But once again more hassle for the designer. Want high level fireballs to have a three square effect? Then each sqaure would have to be given it's own (same) spell effect being cast, just altering the relative position of the effect to the party.

The power rating is too vague, actually having to state
damage = 10 + ran(50), <bit number representing each possible damage type it inflicts>
might be better

I just feel that the closer the coding is to the source, then the more flexible the system will be to get the best out of the effects hard coded into the game.


And yes, I was trying to type thinking so the parts do overlap...it was just a thought starter anyway : )
Was unable to (permenantly) kill off ian_scho (Haynuus), Ameena, oh_brother (Westian), money (Falkor), raixel (Petal) and Lord_Bones (Aurek) in the DM D&D game Time's Champions!

CONGRATULATIONS TO THOSE WHO MADE THE GAME WHAT IT WAS - GREAT!
User avatar
amaprotu
Adept
Posts: 211
Joined: Thu Jan 25, 2001 9:47 pm
Location: California, USA
Contact:

Re: For new spells

Post by amaprotu »

All right, time to admit my ignorance of how scripting actually works (from George's point of view). I imagine some sort of line around how close to the actual C code the script can get. I mean if the script is nothing more than C code, how does it work in a precompiled program? Does it compile it at the begining of the program? I kinda thought that any scripting was a psuedo language created by the creators of the program using the scripts. As such I always thought it was easier to just read in variables from the script files and use them that way. Maybe I'm wrong and it is easy to implement a scripting method involving calling built in program ruitines.

If it is basiacally read in the variables and use them, my approach to programming (maybe a bad one?) has always been the less parsing the better. Anyways I digress. Whatever method used, I want modifiable spells! =)

- Amaprotu
- Amaprotu
theadder
Journeyman
Posts: 63
Joined: Tue Jul 18, 2000 8:00 pm

Re: For new spells

Post by theadder »

Yes, scripting is a pseudo language defined by the programmer. The game has to "parse" each line of the script to create the effect - no compiling takes place. When the player casts a "turn monster into cat" spell, the game has to go through each line of that spell's script and execute it in turn. Realistically, in modern PC's, the time it takes to do this (unless your spell contains 3,000,000 lines of script) would be negligable so pre-compiling would be pointless anyway.

In terms of calling procedures and functions of the actual software from within the scripts, this is an excellent idea. All George would have to do is code the effects into functions and give us documentation of how to call the functions. This is known as macro programming - and I don't know if it can be done in C. If so, great.
With macro programming, functions can be called by referencing their name in a variable - which requires the ability of the programming language to be able to compile small blocks of code at runtime. For example, a line in a script could say:

effect=callfunction booststats(stamina,arc(4*sqr(stamina)))

or whatever. When executing this line, the software would simply take the entire line after the word callfunction and execute it as though it were pre-compiled into the software. Obviously, all the relevant variable names (stamina in this case) and mathematical functions would need to be known to the designer.

Anyway, if macro programming is possible - what a brilliant idea to free up George and put the burden on the designer. If it isn't, forget everything I just said and get off down the pub with yer...
User avatar
amaprotu
Adept
Posts: 211
Joined: Thu Jan 25, 2001 9:47 pm
Location: California, USA
Contact:

Re: For new spells

Post by amaprotu »

That is basically how I thought it worked, thanks theadder.

I personally do not think there is the ability to assign function calls to variable names, this just doesn't fit with my image of how programs are made. Do you know any programing language that does allow this?? I could see basic or java (script?) maybe since they aren't compiled, but maybe I'm wrong and compiled programs can be more flexible than I thought.

My image of scripting in action is something along the lines of a lot of case statements relating variables read in to function calls or used as in-game variables.

However if I'm wrong.... wow that would be cool. =)

- Mahkahl
- Amaprotu
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Re: For new spells

Post by Gambit37 »

I imagine any spell scripting language to work in a similar way to the CON scripts (!) used in Duke 3D. Anyone familiar with those? They look like this and are parsed and/or compiled (not sure) at run time:

actor RUBBERCAN WEAK

ifaction RUBCANDENT {
ifactioncount 16 {
strength 0
action RUBCAN

&nbsp &nbsp &nbsp &nbsp ifpdistl RETRIEVEDISTANCE {&nbsp &nbsp &nbsp &nbsp // If player's close...
&nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp wackplayer&nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp &nbsp // Boot... TO THE HEAD!
&nbsp &nbsp &nbsp &nbsp }
break
}
}
&nbsp &nbsp &nbsp &nbsp
enda

Although this example doesn't relate to spells, it gives you an idea of how the scripts work. But it would require a compiler/parser to be written for it to work and clearly all the available functions and variables would need to be defined by George and made publicly available if it were to be used. I think it's quite a large undertaking, but it would be great if it could be done.
User avatar
amaprotu
Adept
Posts: 211
Joined: Thu Jan 25, 2001 9:47 pm
Location: California, USA
Contact:

Re: For new spells

Post by amaprotu »

At first glance I would love a system that really opened up the engine for creating new spells with scripts, or even using scripts for other things (connecting spell effects to puzzles or something). However there is value in simplicity. As great as a really powerfull script engine is, it is harder to use. I would love to see the day when any user so inclined can easily create a new dungeon with new spells or spell variations. This is all justsort of rambling, I guess. My point really is that if I had to write something as complicated as your sample gambit just to whack someone, I might create two or three new spells. If I bothered at all. I admit the scripting I proposed is less powerfull (by facter of 10 or so). I would like most to see something in between. But more than that I would like to see any kind of spell scripting at all. :)
- Amaprotu
User avatar
Zyx
DSA Master
Posts: 2592
Joined: Mon Jun 05, 2000 1:53 pm
Location: in the mind
Contact:

err....

Post by Zyx »

Fox and Visual Fox allow macro programming
(With "evaluate()" and "&" ).
Very helpful, but who programs games in VFP?
User avatar
amaprotu
Adept
Posts: 211
Joined: Thu Jan 25, 2001 9:47 pm
Location: California, USA
Contact:

Re: For new spells

Post by amaprotu »

There is one person whom I have never seen comment on the scripting of spells or making your own spells etc.

George. :)

I kinda wonder what the only person whos opinion 'really' matters thinks about this. :P

- Amaprotu
- Amaprotu
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Re: For new spells

Post by George Gilbert »

There's a reason for that ;-)

Scripting is hard to do in a robust way (i.e. so that the code would catch any typos and mis-configurations) and I wouldn't be happy releasing something that isn't solid. I'm not keen on doing it in the near future, but once things have settled down and RTC is a good copy of DM (and CSB) then I can start thinking about expanding it!
User avatar
sucinum
Pal Master
Posts: 872
Joined: Wed Apr 18, 2001 1:00 am
Location: Karlsruhe, Germany
Contact:

Re: For new spells

Post by sucinum »

you could make it possible to change the rune-combinatons of the spells, so that in a new dungeon you dont know all spells from the beginning. that would be enough :)
or maybe the ability to cast "double" spells (a fifth line of runes would be needed), so you add just another rune and have a double-fireball or a double-lightning, maybe a twice-as-strong Vi-potion. with these options, dungeons could be designed MUCH harder :wink:
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Re: For new spells

Post by Gambit37 »

Harder doesn't necessarily make something better - take a look at DM Java to see what I mean.
User avatar
sucinum
Pal Master
Posts: 872
Joined: Wed Apr 18, 2001 1:00 am
Location: Karlsruhe, Germany
Contact:

Re: For new spells

Post by sucinum »

ok, lets forget the double spells. but setting new rune combinations could return MUCH of the gameplay we all had when playing dungeon master the first time, and this with each new dungeon.
User avatar
amaprotu
Adept
Posts: 211
Joined: Thu Jan 25, 2001 9:47 pm
Location: California, USA
Contact:

Re: For new spells

Post by amaprotu »

Heh I think you need to dl and play RTC amber, check out what has already been done to the spell system.
- Amaprotu
User avatar
amaprotu
Adept
Posts: 211
Joined: Thu Jan 25, 2001 9:47 pm
Location: California, USA
Contact:

Re: For new spells

Post by amaprotu »

That came out a wrong.
I had just read in another thread that you (amber) havn't actually run RTC, and I think the rune system in place would allow for the control to make a dungeon harder, more interesting in the maner you wish. In fact I think it does it better, because no matter what you change the spells to someone can sit there trying all the combinations til the get it.

On the other hand I am *for* any kind of customization to the spells that is at all possible. Changing the runes, messing with how much power the spell does, changing the skill level needed to make/do the spell etc are all things I would love to have control of in a dungeon I create. The more control given to dungeon designers the more varrying and better dungeons will be made.

Also, is there a way to edit past posts and I just missed it?

- Amaprotu <p><img src="http://www.ulink.net/amaprotu/images/lo ... ="logo.jpg (32741 bytes)" align="top" border="0" width="359" height="71">

a.k.a
<b>Mahkahl Darkwolfe of Avvisione</b>
Flez Fuu of <b>Fuu</b></p>
- Amaprotu
User avatar
sucinum
Pal Master
Posts: 872
Joined: Wed Apr 18, 2001 1:00 am
Location: Karlsruhe, Germany
Contact:

Re: For new spells

Post by sucinum »

heh, i think i know most features of RTC by this forum, i just dont have enough time to test RTC really good and i dont want to play it for just 20 mins. i think searching the runes is a good thing, and new combinations would even improve that (you cant try all combinations as long as you dont have the runes :wink: ). ok, now a really good idea:
a button, where all 4 chars cast their prepared spell at once (the 2 behind with a delay of half a screen)
or hotkeys to cast spells as a shortcut instead of clicking the runes (maybe with a short cast delay not prevent flooding the screen with fireballs or such)
and maybe some direct healing spells which dont require bottles would be ok.
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Re: For new spells

Post by Gambit37 »

Your suggestion about a hotkey for launching all spells reminds me of the 'Panic Button' in Hexen - pressing backspace would launch ONE of every item that you're carrying.

Not sure this kind of functionality works in DM style games - it kind of makes things too easy. A similar discussion happened on the DMJava board regarding having an auto-attack button.

I feel that it's down to the player to manage their party strategy, and adding extra features to make this easier actually detracts from that aspect of the gameplay. If I want a no brainer shoot em up, I'll play Quake or Unreal Tournament...
User avatar
beowuuf
Archmastiff
Posts: 20686
Joined: Sat Sep 16, 2000 2:00 pm
Location: Basingstoke, UK

Re: For new spells

Post by beowuuf »

I think the individual rune keys are enough just now and still retain balance - you can belt out fireballs etc quite fast, but usually at the expence of how well you control the party with the mouse (if at all).
Was unable to (permenantly) kill off ian_scho (Haynuus), Ameena, oh_brother (Westian), money (Falkor), raixel (Petal) and Lord_Bones (Aurek) in the DM D&D game Time's Champions!

CONGRATULATIONS TO THOSE WHO MADE THE GAME WHAT IT WAS - GREAT!
User avatar
cowsmanaut
Moo Master
Posts: 4380
Joined: Fri Jun 30, 2000 12:53 am
Location: canada

HERE, HERE!

Post by cowsmanaut »

I agree Gambit! I see far to many suggestions in both forums that suggest taking away the controll we are given.

DM is one of the few games that really allow you to be in control. *you* have to Learn & remember the spells, *You* have to cast them one rune at a time. *you* have to pick up that key and put it in your back pack and then take it out again to put it in the keyhole.. You have to sleep, eat, heal your party.

This gives you a sence of truly having your fate in your own hands. that you can identify with those characters since you are doing the actions for them. I dunno.. I think a few people should go play Hexen if you want it simple..
User avatar
Gambit37
Should eat more pies
Posts: 13769
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Re: For new spells

Post by Gambit37 »

Wow! Drake, could it be that we finally agree on something!???? :)
twinfalls
Journeyman
Posts: 81
Joined: Tue Sep 19, 2000 11:05 am

Keep the original DM gameplay

Post by twinfalls »

Wow, I agree with Drake & Gambit. Drake is here giving an excellent description of this gameplay I like soo much in DM.
User avatar
sucinum
Pal Master
Posts: 872
Joined: Wed Apr 18, 2001 1:00 am
Location: Karlsruhe, Germany
Contact:

Re: For new spells

Post by sucinum »

if i think right about it, then the system atm is the best and doesnt need any improvent.
Rick
Novice
Posts: 29
Joined: Tue Aug 07, 2001 5:19 pm

Re: For new spells

Post by Rick »

Hey why not just hijack (steal, grab pir8 or however u call it) AD&D rules? I mean just the infrastructure.

Effect type: poison / cold damage / fire damage etc.
Duration:
Target:
Area: n x n squares
etc.

The player's handbook has very good description of all spells, and tell us their effects etc. Once you have a good infrastructure, it's easier to put it into code. Waddaya think?

Once you have a predefined set of spells, all you have to do is assign them a rune combination. If you invent more runes (like say 15 per influence/form), you can have up to 256 different spells! That way we don't have to worry about scripts.
User avatar
George Gilbert
Dungeon Master
Posts: 3022
Joined: Mon Sep 25, 2000 11:04 am
Location: London, England
Contact:

Post by George Gilbert »

Spells can now be customised in V0.35
Post Reply