Spell System
Dec 8 2009, 7:22 pm
By: fat_flying_pigs  

Dec 8 2009, 7:22 pm fat_flying_pigs Post #1



Need Help!:

My spell system uses 12 spell casting units; for now, just use the wraith. Each of my spells has a death count ID (ie: traction beam is 1 Ruin, and repell is 2 Ruin, etc). I need a way to connect the spell death count ID to the wraith.

So far, the only idea I have is using a unit to represent the the spell, and putting it in a "Spell 1 goes here" location. I really don't want to use this method. Anyone have any other ideas? (preferably not using any units, only death counts, and efficient trigger usage)



None.

Dec 8 2009, 7:26 pm Vrael Post #2



Can you explain what you want more thoroughly? I don't understand what you mean by "connect the wraith to the DC." What is the mechanic you're trying to create?



None.

Dec 8 2009, 7:34 pm Neki Post #3



So are you asking some sort of method to do spells specifically for the wraith, and asking for some way to tell when it is the wraith casting spells?



None.

Dec 8 2009, 8:03 pm rockz Post #4

ᴄʜᴇᴇsᴇ ɪᴛ!

Current player commands exactly 1 wraith:
set deaths to 1 ruin.

Current player commands exactly 1 dropship:
set deaths to 2 ruin.

etc...



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

Dec 8 2009, 8:04 pm fat_flying_pigs Post #5



I have 40+spells, and 12 casting units.

Spells: Traction Beam, Supreme Cannon, Rain, etc.
Casting units: wraith, DS, vessel, BC, zealot, goon, HT, DT, rine, bat, ghost, medic (in that order)

The players start the game with 2 possible spells, which have 110 possible combinations. Unlike TS or HS, my spells aren't specific for a Hero, or to a casting unit. I want the wraith to cast traction beam if the player chooses it, or the cannon if they choose that. After the player chooses a spell, the next casting unit would be used (dropship) when the player chooses a 2nd spell. keep in mind, that I dont want to cast my dropship and cast my L1 spell

Currently, the only method I have is using a unit placer for each of the 12 casting units (40 spells * 12 casting units = 480 triggers to link casting unit to spell + 480 triggers minimum for the actual spell)

I need a more efficient method.



None.

Dec 8 2009, 8:09 pm FlashBeer Post #6



Just include the death count condition in the triggering of the spell.
e.g. (you said building a wraith triggers spell 1 right?)
CONDITION:
Bring [wraith] to [starport that triggers spell], Player has suffered [1] Death counts of [Ruin]
ACTION:
Remove [1] [wraith] at [starport that triggers spell]
Traction Beam

Then for your next spell
CONDITION:
Bring [wraith] to [starport that triggers spell], Player has suffered [2] Death counts of [Ruin]
ACTION:
Remove [1] [wraith] at [starport that triggers spell]
Repell



None.

Dec 8 2009, 8:12 pm SelfPossessed Post #7



To clarify, a player can control more than 1 hero at a single time? And you need a way to detect which unit the spell is casted for, given that no spell is binded to a specific hero unit?



None.

Dec 8 2009, 8:15 pm fat_flying_pigs Post #8



Oh yeah... Ok, well that just removes the unit part of it. But I still need a starting trigger because of the complexity of the spells. The spells still require 480 + 480 (minimum) triggers. So far, the spell system will take about 3,000 triggers. Any way to reduce the starting trigger will reduce all the spells as well

And players can only control 1 Hero, but there will be 6 player: 6 heroes. The spells are built dependent on each other. For example, if a L3 traction beam if casted when a L1 repulse is used, the result is the negation of the repulse, and the use of a L2 traction beam.

Post has been edited 1 time(s), last time on Dec 8 2009, 8:21 pm by fat_flying_pigs.



None.

Dec 8 2009, 8:27 pm NudeRaider Post #9

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

Have the every player's hero followed by a location and cast every spell in that location. Why do you need x12 triggers?
And why is 480 + 480 = 3000?




Dec 8 2009, 8:31 pm fat_flying_pigs Post #10



its 480 + 480 MINIMUM. That means at least, the spells will take 1 trigger. Most of them take more. The traction beam/repulse spells take about 30 since they depend on each other. many spells will be affect by others, causing the need of additional triggers.
Quote
Because every casting unit (I think he means, you produce a unit, does a spell) has a possibility of being one of the 40+ spells, meaning he needs to do one spell in twelve different slots you can cast it from, because it can be in any slot for you to cast it. Meaning he has to detect what spell the player has assigned to what slot, and then cast the spell accordingly.

Exactly correct. This is the only method so far, inefficient as it is.



None.

Dec 8 2009, 8:31 pm Neki Post #11



Because every casting unit (I think he means, you produce a unit, does a spell) has a possibility of being one of the 40+ spells, meaning he needs to do one spell in twelve different slots you can cast it from, because it can be in any slot for you to cast it. Meaning he has to detect what spell the player has assigned to what slot, and then cast the spell accordingly.



None.

Dec 8 2009, 8:44 pm FlashBeer Post #12



Would a spell in one slot be different than the same spell in a different slot? If so, it would require a lot of trigs as you suggest.



None.

Dec 8 2009, 8:59 pm SelfPossessed Post #13



EDIT:

Gah, I think I just said what was already said before. Nevermind me. I misread a few posts.

I don't think you can get away from having triggers that detect which spell is binded to the casting unit before casting the spell itself.

For the binding process itself, I suppose you can do it textually, moving a unit to/casting dark swarm/casting dweb on the text area to select the part of the list you want. It will still require a lot of triggers, but you won't need to lay out 40 different units for the spell types available.

If you're worried about the number of triggers, try the trigger duplicator or other text-based trigger options there are.

Post has been edited 3 time(s), last time on Dec 8 2009, 9:30 pm by SelfPossessed.



None.

Dec 8 2009, 9:42 pm rockz Post #14

ᴄʜᴇᴇsᴇ ɪᴛ!

(ie: traction beam is 1 Ruin, and repell is 2 Ruin, etc)
Make your spells each use their own unique DC per player.
Traction beam is ruin, and the number represents the level. Whenever ruins death is greater than 1, the spell is on. Also, it's usually referred to as a tractor beam, since a "tractor" pulls crap. "Traction" is heavily related to friction.

To control what spell is going to be selected, you have to dictate to the player how they are going to use said spell, which is the hardest part. This is another reason games like elements, athlit, and many other AoS remakes have such a steep learning curve.

Hero Sanctuary (I think) utilizes stances, where you have different spells based on which stance you are currently in (offensive or defensive). To switch a stance, you cast a spell. This would just be setting a DC to some number, which would be an easy condition to fulfill. Now then, since you have 12 units, I assume these are coming from 3 buildings. I would suggest you use 4 buildings:
Barracks, Gateway, Stargate, and Robotics bay. This will allow for (4+4+4)*3 spells. This wouldn't be TOO difficult on the player. If you really want the 40+, use a starport instead of the robotics bay, which would allow you to use 12*5 spells, with 5 different spell sets.

Another option (and actually a better option) is to use reavers or carriers as a multiplier. They allow for 4/5/8/10 -1 spell sets (and are upgradeable). They also let you know exactly which spell set you are on. They use units instead of DCs, but that's not necessarily a bad thing.

Finally, if you just want 12 spells, chooseable by you, you're going to have to figure out a way to choose them. If you have 40 spells, the BEST way would be to have a unit and MC the unit. Much like athlit and astrogears, this is the best way to do it. If you want to do it without that, have a building which you can build something, and each unit will add a to a certain DC. Each spell has a certain number 1-40 and you can assign them to a spell slot 1-12 after you've chosen your spell, or you can just cast the spell you want to assign it to.

After all is said and done, I think you will realize that this is just too hard. TS only has 4 spells, and most players only really use 1, or 1 at a time. Even if somehow the player is smart enough to figure out such an inconvenient system with so many variables, there's still a huge learning curve. It will be ridiculously difficult for more than a few people to get good at this game. I'd probably give up in a short amount of time.

To link the wraith with any of the 40 spells, set a DC corresponding to that wraith to the number of the spell. Use binary countoffs to transfer the spell into a buffer, which is then used to cast that particular spell. Say spell 24 is tractor beam. When you set up your spells, you set wraith as spell 24 (tractor beam). When you cast wraith, the wraith DC goes to the buffer, so the buffer is at 24. When the buffer is 24 and the level is a certain amount, you cast tractor beam at that level. To determine the level, you can either specifically upgrade tractor beam, in which you'd need a bunch of DCs for each spell, or you can upgrade the wraith slot, and store the level in the wraith DC in the 1s spot, and the spell number in the 10000s spot.

This means you'll need 10 BCs for each spell slot, and you can hold up to 64 spells.

Post has been edited 1 time(s), last time on Dec 8 2009, 9:56 pm by rockz.



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

Dec 8 2009, 10:23 pm fat_flying_pigs Post #15



Quote
Would a spell in one slot be different than the same spell in a different slot? If so, it would require a lot of trigs as you suggest.
Spells are the same regardless of the slot they are in.

Quote
To link the wraith with any of the 40 spells, set a DC corresponding to that wraith to the number of the spell. Use binary countoffs to transfer the spell into a buffer, which is then used to cast that particular spell. Say spell 24 is tractor beam. When you set up your spells, you set wraith as spell 24 (tractor beam). When you cast wraith, the wraith DC goes to the buffer, so the buffer is at 24. When the buffer is 24 and the level is a certain amount, you cast tractor beam at that level. To determine the level, you can either specifically upgrade tractor beam, in which you'd need a bunch of DCs for each spell, or you can upgrade the wraith slot, and store the level in the wraith DC in the 1s spot, and the spell number in the 10000s spot.

This means you'll need 10 BCs for each spell slot, and you can hold up to 64 spells.

i'm confused. This sounds like I'll need 10 death counts for each slow, and I can total 64 spells. Can you please elaborate exactly how I would use this method?



None.

Dec 8 2009, 11:01 pm rockz Post #16

ᴄʜᴇᴇsᴇ ɪᴛ!

Spells are numbered from 1-40 (can be increased) and will be referred to as spell X.
Slots are numbered from 1-12 (can be increased if you want to) and will be referred to as slot Y.
Each slot has its own DC associated with it and will be referred to as slot DC Y.
Binary countoffs (or BCs) require a buffer to reset. You may as well make one for each slot, and refer to them as Buffer Y.
There will also be a spell cast DC which acts very much like a buffer, but will be the condition which determines which spell is cast.

Step 1:
Player needs to assign spells to slots. Somehow, (as detailed in previous post) you assign Spell X to Slot Y by storing X in Slot DC Y using a binary countoff.

Step 2:
Slot Y is assigned to Spell X. Player casts slot Y.
Transfer Slot DC Y to buffer Y and spell cast DC.
Spell cast DC runs the spell you want

Step 3:
Transfer buffer Y back into Slot DC Y.

Ignoring Step 1, which shouldn't change during regular gameplay, that's 2 binary countoffs, which would bet 10 triggers per slot. You'd need 2 DCs for each slot, plus 1 DC for spell casting. That's 25 DCs. You can drop it down to 13 if you want to use a single buffer, but you'll need to figure out how to do it on your own, because it's too hard to explain (and I don't know how off the top of my head).

I'm going to change my mind a little from my last post, so bear with me. To assign a level, I would add another set of DCs, two for each spell. One DC holds your current level of the spell you are using, and the other will be used to determine the actual cast level of the spell. That's 80 DCS, or 105 DCs total. Chances are you will be running out of DCs soon, so there's ways to store more in DCs. For example, if you don't allow them to change spell slots once assigned, you can store the level in the spell slot DC. However, that's for you to figure out.

Let's say ruins is the spell to cast Tractor Beam, Jump Gate is Tractor Beam's level, and tractor beam is spell 24.

if
Spell cast dc is 24
Jump gate is 3
then
set ruins to 3

if
ruins is 3
then
cast tractor beam level 3

Chances are tractor beam will have some sort of timer on it to determine how long it lasts, so let's say it lasts 300 cycles. That means you'll have a separate condition in there which checks that the timer hasn't run out. When you cast repulse, you subtract from ruins, and subtract however much you want from the timer as well if time increases with level. If repulse has its own effect and isn't just a counter to tractor beam, you'll need to figure out a way to cancel it out if you cast it after a higher level tractor beam. That's going to be the hardest part, IMO, next to triggering all this crap.



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

Dec 9 2009, 1:12 am FlashBeer Post #17



FIRING THE SPELLS FROM THE SLOTS
Here's how I figure to reduce the amount of triggers:
12 slots = 12 different DCs
When picking spells, each slot DC will be set to the spell's DC #
(i.e. Catina = slot 1, set Catina Deaths to 2, 2 Deaths = Repel, therefore slot 1 is Repel)
(i.e. Ruins = slot 2, set Ruin Deaths to 1, 1 Death = Traction Beam, therefore slot 2 is Traction Beam)

Now for the actual spell: (The spell effect that comes after triggering the spell)
You need 2 more different DC:
1 DC is the buffer
1 DC determines which spell is being used
(i.e. Khydarin Crystal is the DC used
Player suffered [1] Death of [Khydarin Crystal] >> Set Deaths of [Khydarin Crystal] for Player to [0], Run Repel)
(Setting the deaths of Khydarin Crystal back to 0 Keeps the spell from re-triggering)

Now that you know which spell is in which slot, and what which spell does what, you need to link them together (which means what?)
Collapse Box


You should now have the correct ID# to trigger the spell
all you need to do now is regain the information of the slot's spell you just used
(i.e. Death Counts of Ruins is now 0, so you need to re-tell which spell was in that slot)
Take your buffer DC and use binary count-off to put it back.
Collapse Box


Instead of 12 slots x 40 spells = 480 Triggers,
This method should take about (12 slots x 6 Binary Count-offs) + 6 Buffer count-offs + 40 spells = 118 Triggers
Of course this isn't including the Triggers necessary to assign spells to slots...
Which would be another 12 slots x 40 spells = 480 Triggers
(i.e. set [ruins] to [1]... set [ruins] to [2]... set [ruins] to [3]...
set [catina] to [1]... set [catina] to [2]... set [catina] to [3]...)
Unless...


SETTING UP THE SPELLS WITH THE SLOTS


Choosing a spell sets an ID# for only 1 type of DC, then use binary count-off to transfer that to the slot number
Collapse Box


So this makes it:
40 ID triggers + (6 Count-off x 12 Slots) = 112 Triggers
So instead of 480 setup triggers + 480 casting triggers = 960 triggers
The new method should make 112 setup + 118 casting = 230 minimum

Hopefully this would help.

Post has been edited 2 time(s), last time on Dec 9 2009, 1:21 am by FlashBeer.



None.

Dec 9 2009, 2:44 am rockz Post #18

ᴄʜᴇᴇsᴇ ɪᴛ!

There will be many problems which arise, but one I can point out now is that the buffer doesn't know innately which slot to go back into (which is why I suggested 2 DCs for each slot). You'll need 12 *6 buffer triggers minimum.



"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"

Dec 9 2009, 3:19 am FlashBeer Post #19



Quote from rockz
There will be many problems which arise, but one I can point out now is that the buffer doesn't know innately which slot to go back into (which is why I suggested 2 DCs for each slot). You'll need 12 *6 buffer triggers minimum.

Oh yea, seems I forgot about that part.
I just thought again, that he could recycle the early triggers for designating which spell goes in which slot to tell which slot the buffer goes back into.

For the part where I said:
Collapse Box

Just add an action to the last trigger:

You build a [Dropship], Suffered at least [1] Death of [Ruins] >> Add [1] Death of [Khydarin Crystal], Add [1] Death of [Vespene Geyser], Subtract [1] Deaths of [Ruins], Slot 1 is not chosen

Which will restart this trigger:
Collapse Box


Then add another action to this last trigger to reset the condition of the buffer triggers:
Slot 1 is not Chosen, Player has suffered at least [1] Death of [Spell ID'er] >> Add [8] Deaths of Catina, Subtract [1] Death of [Spell ID'er], Slot 1 is not chosen, Slot 2 is not chosen, Slot 3 is not chosen, Slot 4 is not chosen, etc... etc...

And also replace all the [Spell ID'er] I used with [Vespene Gas] if you were using this exact example.



None.

Dec 9 2009, 4:32 am fat_flying_pigs Post #20



I understand now, thank you very much.



None.

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[10:41 am]
v9bettel -- Nice
[01:39 am]
Ultraviolet -- no u elky skeleton guy, I'll use em better
[10:50 pm]
Vrael -- Ultraviolet
Ultraviolet shouted: How about you all send me your minerals instead of washing them into the gambling void? I'm saving up for a new name color and/or glow
hey cut it out I'm getting all the minerals
[10:11 pm]
Ultraviolet -- :P
[10:11 pm]
Ultraviolet -- How about you all send me your minerals instead of washing them into the gambling void? I'm saving up for a new name color and/or glow
[2024-4-17. : 11:50 pm]
O)FaRTy1billion[MM] -- nice, now i have more than enough
[2024-4-17. : 11:49 pm]
O)FaRTy1billion[MM] -- if i don't gamble them away first
[2024-4-17. : 11:49 pm]
O)FaRTy1billion[MM] -- o, due to a donation i now have enough minerals to send you minerals
[2024-4-17. : 3:26 am]
O)FaRTy1billion[MM] -- i have to ask for minerals first tho cuz i don't have enough to send
[2024-4-17. : 1:53 am]
Vrael -- bet u'll ask for my minerals first and then just send me some lousy vespene gas instead
Please log in to shout.


Members Online: storuswhes, Roy