Game Development Community

Spells instead of guns...could use some advice :)

by James Hill · in Torque Game Engine · 10/01/2004 (5:37 pm) · 4 replies

Hello everyone, I'm currently working on implementing a spell system for our game. My only problem is, I don't really know where to get started. I tried following the spellcasting post by Stefan, but I couldn't find the defaultBind.cs or the config.cs.

I had an idea to make a separate .cs for each spell, and scripting it like the weapons tutorial. But I soon realized that I still didn't have a way of firing it because there was no weapon to mount or shoot the projectile. If anybody has any experience using TGE for spellcasting, some advice would be greatly appreciated. Thx :)

#1
10/01/2004 (5:50 pm)
Please becareful of dbl posting, if you mis posted just delete the content of the other one and indicate so

-Ron
#2
10/02/2004 (2:28 am)
Just an idea I have right now :)
Create an image with an invisible shape, you need this because you need the muzzle transform when you fire the projectile, or the projectile will be fired from the center of the player bounding box, if I remember well, but perhaps it isn't so important. Change the recoil animation to the magical movement the player has to do to cast the spell, and fire a projectile that can be a fireball or what else you want. This should do the trick without much effort
btw: defaultbind.cs is in example/starter.fps/client/scripts config.cs is in example/starter.fps/client
#3
10/02/2004 (6:56 am)
Ah sweet. I ended up making the weapon a very small sphere, just need to change the onMount sequence. Thanks for the suggestions, and thanks for letting me know where those files are. My noob self never checked the client folder. :)
#4
10/02/2004 (12:53 pm)
Check out the scripts in Realm Wars too, I know the female spellcaster in that game has at least 2 or 3 spells.