Jump to content
The Dark Mod Forums

Arranging for in-game changes to inv items


Strider

Recommended Posts

So I'm working on a mission that will require some in-game alterations to an inventory object. Specifically, I want one of the objectives to say something along the lines of "Read this letter, then find a way to re-seal it so no one knows you opened it." Any suggestions on what might be the easiest way to contrive such an event? I'm not looking for anything especially complex -- maybe just make the player find a candle and "use" it on the letter (to apply a wax seal), preferably with a change in the object's appearance from a page of paper to a closed envelope. (Do we have models for closed envelopes? Don't remember seeing any.)

 

Thanks!

Edited by Strider
Link to comment
Share on other sites

I think there is a closed letter with a seal. But can't check...

 

I don't think we have a model for a 'seal', but should be easy enough to make one with a small cylindrical patch.

 

Probably the easiest way is to have the player use the seal on the letter. Stim/reponse thing.

 

Maybe have a closed letter model, the player reads it which trigger an objective (that has nothing to do with mission completion)(easy way to trigger from readable), this 'objective' swaps the model in the props of the letter when read. So the play puts it down and it's an 'open model'. Then the player uses a seal on it (stim) and it's model changes back to closed.

 

involving a candle for heat would make it more complicated. But maybe a heat stim before the seal stim would work.

Dark is the sway that mows like a harvest

Link to comment
Share on other sites

you could put an unlit fire stim on the letter so if the player accidently touches the flame to it, it catches on fire and he fails the objective ^_^

|=-=------=-=|

happycheeze.deviantart.com

 

Moddb

 

Gamers Outreach, a nonprofit that uses videogames to raise money for chairty.

|=-=------=-=|

Link to comment
Share on other sites

No I don't think there is one. How about a scroll with a ribbon around it? There are some with ribbons and some without. You could regard the ribbon ones as 'sealed' with wax. If not you'd have to make an envelope from a patch and make it a custom object and make a texture for it. So let's try to define the action you want:

 


  •  
  • Player finds sealed scroll.
  • Frobs it and it goes in inventory.
  • Shows in inventory with ribbon
  • Read it.
  • Objective triggers (this may be visible if you want or an invisible objective)
  • Scroll inventory icon and model want changing to un-ribboned or open one (same principle if it were a letter and envelope.) I am uncertain of this. Last time I heard it wasn't working properly; a script I think. Needs some research. Might not be do-able quickly.
  • Same trigger reveals new objective to find and use Lord Hogsworth's private seal to seal the scroll again. A 'candle' is a bit to general so I would say either a special red candle or better I think is a private seal. Yes a seal needs wax but that is a given - the seal is more interesting.
  • Player finds seal, frobs it to inventory then has to 'use' it so it reverses the scroll model and inventory icon to the ribboned one. This 'use' set up is do-able.

 

So what needs researching is a script or entity or something that can either add/remove to/from inventory or change model, inv_icon. I think the latter is do-able. I think I've seen a change model script or s & r or somewhere I think I've seen it.

 

I'll try and find time to have a look tomorrow but I'm tied up right now with another map.

Link to comment
Share on other sites

@Baddcog & Fidcal: I agree that the seal is the more interesting item to be involved in the process (though in this context the player will already have it in their possession at mission start). I'll fiddle around with the heat stim/special candle idea, but maybe it would be sufficient to just require the player to be within a certain range of a particular candle in the map? Like a candlestick on a desk in the study? Heh, I sound like I'm accusing somebody in Clue...

 

@HappyCheeze: Complete with custom failure movie, no doubt. "Congratulations, you were clumsy at precisely the most inopportune moment." ;)

Link to comment
Share on other sites

How would I link a bunch of lights to a single switch without having the switch target every single one of them? I'm talking about a LOT of lights, like a master switch for the whole building. I've tried the def_attach method I found in the forum search, but I'm getting an error in the dmap log and the switch isn't turning all the lights on -- only the first one, the one that the switch is directly targeting.

Link to comment
Share on other sites

Don't know. You will probably spend more time figuring this out than typing the targets. :) Remember you can clone lines eg, change target7 light7 to target8 light8 and hit Enter and repeat for 9 to 20. (assuming you know all the lights are numbered in order.) Anyway, we've already spend more time in this thread than the work involved. :laugh:

Link to comment
Share on other sites

Thanks for the tip, stumpy, but as I'm new at this, I'm not sure how to employ that information. Can you elaborate...?

Link to comment
Share on other sites

Create a plain text file in your maps folder named mymap.script (where mymap is the name of your map file.) Type into it:

swopReadables
{
$player1.replaceInvItem( $name_of_old_item , $name_of_new_item );
}

 

Now create a atdm:target_callscriptfunction and give it the property and value: call swopReadables.

 

The name swopReadables can be any suitable name of your choosing so long as they match in script and atdm:target_callscriptfunction.

 

You trigger the atdm:target_callscriptfunction from any triggering object with a target.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • OrbWeaver

      Does anyone actually use the Normalise button in the Surface inspector? Even after looking at the code I'm not quite sure what it's for.
      · 5 replies
    • Ansome

      Turns out my 15th anniversary mission idea has already been done once or twice before! I've been beaten to the punch once again, but I suppose that's to be expected when there's over 170 FMs out there, eh? I'm not complaining though, I love learning new tricks and taking inspiration from past FMs. Best of luck on your own fan missions!
      · 4 replies
    • The Black Arrow

      I wanna play Doom 3, but fhDoom has much better features than dhewm3, yet fhDoom is old, outdated and probably not supported. Damn!
      Makes me think that TDM engine for Doom 3 itself would actually be perfect.
      · 6 replies
    • Petike the Taffer

      Maybe a bit of advice ? In the FM series I'm preparing, the two main characters have the given names Toby and Agnes (it's the protagonist and deuteragonist, respectively), I've been toying with the idea of giving them family names as well, since many of the FM series have named protagonists who have surnames. Toby's from a family who were usually farriers, though he eventually wound up working as a cobbler (this serves as a daylight "front" for his night time thieving). Would it make sense if the man's popularly accepted family name was Farrier ? It's an existing, though less common English surname, and it directly refers to the profession practiced by his relatives. Your suggestions ?
      · 9 replies
    • nbohr1more

      Looks like the "Reverse April Fools" releases were too well hidden. Darkfate still hasn't acknowledge all the new releases. Did you play any of the new April Fools missions?
      · 5 replies
×
×
  • Create New...