Groovy event recipes...

#1
It took some crude logic to wrap my head around the workings of the event handler dialogs (really it could be more explicit -- but I can't say if there is enough room for a proper translation... at least more technical programming terminology might help)

Anyway.... I worked out a clean and efficient means of giving the player constant regen proportional to their str/mag stat (or any stat really)

First let's say it's possible (though I haven't yet tested it on a faster machine to be sure it doesn't spin out of control -- I will soonish though... I should be engineering real software, not dealing with this hackneyed scripting interface Twisted )

Anyhow, the basic thrust of it is...

1) Make a Counter for the stat you want to track (strength in this case) ...use the Set Counter From Parameter instruction (took me a while to notice that one... and all of this goes in the same thread, "Sequence" per John's translation)

2) Next you'll need to have another Counter, call it Regen Whatev, and you test this to see if it's over some threshold (in this howto, we'll use 98x10 -- max str (-1) time 10... for human scale timing)

3) IF it is, then give the player 1hp and the important part... set the Regen Whatev Counter to 0!

4) OTHERWISE add the contents of your first Counter (has your current Strength) to the Whatev Counter.

5) END IF


Anywho, that is about as fancy as you can make it (given the poor selection of possibilities)


------------------------------------


For my next trick, I'm going to try to turn the pointless POISON status into a very severe BLEEDING status. Probably change CURSE into a different sort of POISON. And make SLOW a GOLEM status (you don't bleed and other stuff) ...and DARK to a combined DARK/CURSE state. PARALYZE is pretty weird, so I will try to have a counter look for it, then immediately take it off, and replace it with some other side effect (probably critical hit... so a short moment of not moving might be a plus)

edited: Actually max str is 107 (go fig) but you can set it to start at least up to 999 when testing your game (but the level up model stops you at 107... events could make it go higher presumably)
Reply

#2
nicely written.

i like the idea of including complicated event scripts here :)

i was thinking...and john or tom may have to confirm.

since you can export and import map data, you might be wise to create all these complicated events, duplicate them to however many blank maps you want to create, and if possible import the map configuration from DOM overtop. I am not sure if it is possible to preserve any events like that though when importing...just would hate to have to see you rewrite that counter over and over for all the maps
- Todd DuFore (DMPDesign)
Site Founder
Reply

#3
^You could do always on events like that.

I'm afraid there might not be too many more clever scripts though Cry

I just worked out you can't even poll for your bad status state... wtf gives SoM??

So scratch all those bad status related ideas I posted (which would've otherwise worked if you could just load your POISON status into a counter like you can... the ones you can!?)

I think I'm probably gonna learn a bit just by banging my head against SoM, but I probably won't feel like releasing anything until I finish my remake and load what I have so far into it... because I just hate working with stuff I don't have 100% control over anyway Evil

Moral of the story seems to be, SoM is awesome if you wanna remake KF1... or something similar, but not much else... frankly I'm surprised the regeneration even worked Twisted

PS: The regen script does work just as well on the slowest machine that could possibly play SoM (really unplayable but...) and tests out on as fast a machine as any running SoM at 1200p double wide resolution.
Reply

#4
Actually... I think the right way to copy paste events into projects, is probably to not use the map editor at all, and instead figure out where the events are in the files (hopefully text-readable) and try to copy the event directly into your map files. This way you could add events to preexisting projects.
Reply

#5
Here is a good one...

A warp spell. How I achieved this, is I wanted a warp spell you get first thing in the game. I actually wanted the cost of the spell to be extremely high, so you can't cast it for a good while. But as it turns out that is sort of a requirement (well if you want to lean on the safe side -- at least the cost of the spell needs to be not too close to other spells -- and if it isn't the most costly spell you'd need another IF statement)

Anyway, how this works is...

1) You'll need an "Always On" event and two Counters...

2) First you place the players current MP in the first counter. There is an instruction to do this.

3) You test if the second counter is greater than the first counter (don't worry that the second counter is not at first set, cause 0/the default is alway less)

4) IF so, then you subtract the first counter from the second counter (the second counter now knows how much magic you just spent)

5) IF the magic is greater than slightly less than the cost of your teleport spell (factor in any possible magic regeneration going on.) ...then you can safely warp the player to where the spell takes them. At this point you could toss in another IF block and make sure that the MP spent is less than any spell you have that costs more than the teleport.

6) END IF and END IF again.

7) Now copy what's in the first counter into the second counter.

Tested, and works. And if it doesn't, I probably missed something in the explanation because I'm not looking at the event setup atm. Just use common sense before asking for clarification please Twisted


*SPOILER*
For my DoM remix project...
I call my spell Song of Sonellian, which is found on a dragon pedestal (dead fountain with the base underground) near Sonellian's grave. The spell cost 120 and takes you back to Sonellian's grave, which is just across from the players home base place and where the game effectively starts (after a playable intro) ...you have to walk back to the base until you have 120mp though. After you do, it's pretty easy to just warp between there and healing tree and recoup your 120mp (if you're cheap like that)
*SPOILER*

PS: If you want to do this for multiple spells, you can do them all in the same event with some thought. Also the first IF probably isn't necessary, but I just did it to avoid negative numbers (cause I dunno if they're allowed) and add some logic to the explanation.
Reply

#6
I just finished setting up a weight model. Basically it adds up the weight of all your inventory and penalizes you for a total of five stages...

0) No penalty -- you can swim (this weight is fixed)

1) You will now sink to the bottom in water...

2) Sorry big boy, no more dashing around...

3) You're permanently stuck in slow status....

4) You're not going anywhere like this!

It works quite well... I'll explain later Twisted
Reply

#7
Made a series of events for consuming items.

First you use the item which paralyzes you for some time (while you're busy using it)

That is the consumption phase...

Next you must digest the item for some time while it has no effect. For the first item this time is double the consuming phase.

Finally the item kicks in, and I set this phase to be four times the first phase (two times the digest phase)

During the final phase the item gradually effects the player over time.

And to further mix things up... you can be digesting two items at once. If you digest two of the same item, this prolongs the medication phase.

Eventually I might let the player mix their meds so to speak for added side effect (oh there will be good and bad)

Just saying it's possible Twisted ...for now Wink

PS: If the player uses an item before the pipeline is ready it is returned to the inventory. Well for digestion... let's just say, the more you try to do at once, the more you risk losing a benefit.
Reply

#8
Interesting, this would introduce a form of alchemy to the game.

To try to make you work a little harder ( like thats necessary!)
could you maybe monkey with it to the point where the outcome potency of the combined consumables is based on intellect...in other words if youre smarter, you combine your ingredients more skillfully and can make more potent medications.
- Todd DuFore (DMPDesign)
Site Founder
Reply

#9
I dunno... it just seems like technically you can do some very sophisticated stuff with SoM events that the developers probably never imagined, and seemed to intentionally prevent you from doing elsewhere Twisted

An alchemy system would be like mixing items. I'm generally just reporting stuff I'm doing with my own presentations... so I'll leave that exercise to the reader. I can tell you just doing the digestion setup is fairly complicated, so alchemy would be entire game in itself probably (dunno if you need something like that for Shadow Gate)

^If you did it this way, you'd want to have a special item, like the crystal flask be used to start a mixing sequence. Then items used afterward would go into the cocktail. Then you could have like a cork item or something to end the sequence. Better yet might be a pseudo-command item slot that starts and stops. The only problem I've experienced with this approach is SoM seems to list x1 after every item in your inventory, even if there is just one in the game, which is lame. The same x1 is used everywhere, so you can't just remove it from the exe, or you will have no way of knowing how much of anything there is Twisted
Reply

#10
If we ever implement something like this in a game, I would recommend making a map that had an alchemy area to create the mixtures in, that way you could force them to be on one map to do it, and not have to worry about getting the events on all the other maps heh.
- Todd DuFore (DMPDesign)
Site Founder
Reply





Users browsing this thread:
6 Guest(s)