Any tutorials for advanced ACTIONS?

Questions about how to create your own dungeons and replacement graphics and sounds.

Moderator: George Gilbert

Forum rules
Please read the Forum rules and policies before posting.
Post Reply
User avatar
Gambit37
Should eat more pies
Posts: 13720
Joined: Wed May 31, 2000 1:57 pm
Location: Location, Location
Contact:

Any tutorials for advanced ACTIONS?

Post by Gambit37 »

There's a few actions I haven't tried using yet. I was wondering if anyone has any examples of how to use the following (it would save me a few more hours of testing!)

ACTION_MOVE_MOUSE_TO_OBJECT_LOCATION
ACTION_MOVE_OBJECT_LOCATION_TO_MOUSE
ACTION_MOVE_ITEM_TO_MOUSE
ACTION_MOVE_ITEM_TO_OBJECT LOCATION

Thanks in advance :)
User avatar
lbk
Craftsman
Posts: 125
Joined: Tue Feb 16, 2010 1:58 am
Location: USA

Re: Any tutorials for advanced ACTIONS?

Post by lbk »

Not the best at this, but for the action_move_object_location_to_mouse I have a little insight.

This action moves an item to the mouse. It works by having a floor_object be a refrence point, then when the action is triggered it moves the item that is "on top" to your mouse (if it is empty) By "on top" I mean the last item put down on that square:

If you have a secluded tile that a player cannot interact with, the first item the action will fetch is the one furthest down on your list in the editor. (Sorry if this is unclear, basically if you are using the editor and add a GOLD KEY to a tile, then add an IRON KEY to the same tile, this action will fetch the IRON KEY first and then if triggered again, it will fetch the GOLD KEY)

If the tile is not secluded, i.e. You, as a player, can place an item on that tile. The action will fetch the last item you, as a player placed on that tile. (An example to try and clarify things: If you have a tile that is populated with 3 GOLD KEYs when you enter the dungeon, you go to this tile and put down an EMPTY BOTTLE, when you use the action the first time, you will get an EMPTY BOTTLE.)

I have a lot less experience using action_move_mouse_to_object_location, but if it saves you any time I'll tell you what I do know.

This action is used in DMII as a way of obtaining items by clicking on a floor object (Like from a water fountain for instance) Near as I can tell it is used as an action to be triggered by a click (floor and wall objects under convert have room for like 8 different things to happen when you click on them as I am sure you know) I believe that it works in the same was as the previous action I discussed by obtaining the object "on top" and when it is triggered by a click will pick up that item and place it in an empty mouse hand.

Like I said, I am not to versed in the second action (Using it only as it is used in DMII) but good luck finding out what all these actions do. If you do get a good idea, I would like to know what they do (If you wouldn't mind sharing)
User avatar
Chaos-Shaman
High Lord
Posts: 2642
Joined: Wed May 03, 2006 7:26 pm
Location: The Gates of Hell

Re: Any tutorials for advanced ACTIONS?

Post by Chaos-Shaman »

yeah, me too. thanks lbk, that helped, now i can use that to trigger an action to give a creature an item, that is great. thankyou. it works.
keep your gor coin handy
User avatar
Lord_BoNes
Jack of all trades
Posts: 1064
Joined: Mon Dec 01, 2008 12:36 pm
Location: Ararat, Australia.

Re: Any tutorials for advanced ACTIONS?

Post by Lord_BoNes »

I have used ACTION_MOVE_ITEM_TO_OBJECT LOCATION in too many of my mechanics. The most useful purpose I have for it is to create "local effects" anywhere in the dungeon.
EG: you have a mechanic that would normally require you to put triggers on every possible tile that can be effected (I know many mechanics like this)...
Simply clone a FLOORITEM_SLIME (or another flooritem that does nothing but sit there) twice.
Have a single instance of the 1st clone somewhere secluded (like fountain's item storage is for DM2, a place the party can never actually get to).
When you want to trigger your effect, create a copy of the 2nd clone on the tile that the object is currently on (use CREATE_NEW_ON_FLOOR with your object_1 being the clone)
Now, use MOVE_ITEM_TO_OBJECT and have the object_1 as the 1st clone (the triggering object will jump to the secluded location)
Now, you can trigger your effect (using a trigger or some such on the secluded tile)
Once your effect is complete, you simply use MOVE_ITEM_TO_OBJECT with object_1 being the 2nd clone (the object will return to where it was when you used CREATE_NEW_ON_FLOOR). Once the object is back where it belongs, you just use SWAP_TILE to remove the 2nd clone, and the effect is ready to be triggered again.
NOTE: if there are any delays in the effect, then the item will disappear and then re-appear depending on your delays.

You can also use this method with MOVE_PARTY_TO_OBJECT, for various tricky mechanics. It's how I've done alot of interesting things in RTC.

I don't know if I've explained this correctly. As usual, I'll most likely just put up a tutorial on how to do it (it might be a day or two) :P
 
Image

1 death is a tragedy,
10,000,000 deaths is a statistic.
- Joseph Stalin

Check out my Return to Chaos dungeon launcher
And my Dungeon Master Clone
Post Reply