Jump to content
The Dark Mod Forums

Sir Taffsalot's mapping thread


Sir Taffsalot

Recommended Posts

A few things:

 

1 - rolf is bound to 'pg', which is the prison guard. I suspect odd things happen--including dropping out of the map--when an AI is bound to another AI. Delete the bind spawnarg on rolf.

2 - Place your path_corners on the floor. AI want to walk to the origin of the path_corner, which is at its bottom, so the path_corner arrival math is more accurate when path_corners stand on the floor and don't hover above it.

3 - The trigger_once you have in the hallway outside the cell should be a trigger_once_entityname, and it should be wrapped around the path_corner, not sitting next to it.

4 - On the cell door, set 'trigger_on_open/0' and 'trigger_when_opened/1'. The way you have it now, rolf is triggered when the door starts to open, and you don't want him to move until the door is fully open.

 

Make these changes and see if things are better.

 

Edit:

 

5 - Put monster_clip on the bars surrounding the cell door, leaving an opening that's door-size. This reduces the chance that rolf will bump into the surrounding bars while trying to leave.

Link to comment
Share on other sites

2. Put him on the same team as the guard and blind him (Sotha's suggestion).

 

I completely misread that. I thought you said "bind" not "blind". I did think that was an odd thing to do.

 

When you say "and it should be wrapped around the path_corner, not sitting next to it." do you mean it should be litterally sized to fit around the path_corner?

"I believe that what doesn't kill you simply makes you... stranger"

 

The Joker

Link to comment
Share on other sites

I completely misread that. I thought you said "bind" not "blind". I did think that was an odd thing to do.

 

Hah!

 

When you say "and it should be wrapped around the path_corner, not sitting next to it." do you mean it should be litterally sized to fit around the path_corner?

 

When looking down from the top, do this:

 

post-3633-0-97205100-1346530135.jpg

 

rolf will run to that path_corner, but the moment before he reaches it, he'll hit the trigger and disappear.

 

For testing, you might want to move the path_corner, trigger, and func_remove farther away from the cell. When you've got it working, move that threesome farther away, around some corners, out of the player's sight.

Link to comment
Share on other sites

Thank you for your help gentlemen! I have one final (I hope) issue that needs solving. I'm reading Graymans "In-game Map Entities" tutorial. I've made a small map to test this out but I'm having no joy. Would someone or Grayman himself be able to have a look at my map and tell me where I'm going wrong?

 

http://www.mediafire.com/?55jm0d8q2aw9mqs

 

Thank You

"I believe that what doesn't kill you simply makes you... stranger"

 

The Joker

Link to comment
Share on other sites

Copy the example script from the wiki page into a file named "city.script", modify it to match the names of the custom item and map in your mission, and place the file in the maps folder next to your *.map file.

 

You can read about script files in general on the wiki.

Link to comment
Share on other sites

I've created a script file in the maps folder, copied and pasted the text from your tut and changed the relevent text to match the custom item and map. It still won't work in the map. Also I can't see anything about script files in the wiki. I've looked under S for scripts, H for How to make Scripts and C for Creating scripts.

 

http://www.mediafire.com/?n55n5s5459cwlvl

"I believe that what doesn't kill you simply makes you... stranger"

 

The Joker

Link to comment
Share on other sites

Thanks for your help grayman but it still doesn't work even with those changes. I'm at the point where my mission is just about finished and I think I'll just release it without the map. It would be nice to have one but it's certainly no deal breaker.

"I believe that what doesn't kill you simply makes you... stranger"

 

The Joker

Link to comment
Share on other sites

What happens when you frob the scroll? For me, when I made those changes, the scroll was swapped out of inventory and the map swapped in. The graphic for the map had the same black background as your knife did. Are you seeing that, and does the icon give you the correct inventory name? ("Map")

Link to comment
Share on other sites

  • 2 months later...
The FM takes place during a masked ball. The player will be wearing a mask. As long as he stays on the ground floor he will be treated as a guest. 1st floor and basement are out of bounds. The player has to sneak there to complete objectives

 

I'll put these suggestions here as I don't want to flood the comment system with advice:

 

Could you compartmentalize the ballroom into multiple enclosed party areas: hall with 4 people eating. Door. Another hall with people chatting. Corridor. Another hall with people listening to a gramophone, etc. Party guests would stroll around from room to room enjoying their time (RIT network) and having conversations how cool the party is.

 

Civilians in a room, when alarmed, could just panic and run away to the edge of the map. Each civvie reaching the area is completely removed from the game (they get out of the building). That way the whole party could be shut down because of an intruder, which seems realistic. This would work with the RIT network nicely: there would be a "alarmed only" path-which takes the AI out of the network towards the map exit.

 

If even one civvie gets out because they were alarmed, a citywatch (or other) guard squad marches in after a short while. (The civvies go get some help.)

 

This way, you get the immersion from the civilians making the party lifelike. If things go ugly for the player, the party ends, cover is blown, you get rid of the civvies eating resources and get them replaced with real & dangerous gameplay AI. The mission would be more interesting to those players who don't quickload after each bust..

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

According to my sketches on the ground floor I have the ballroom, bar area, dining room, art gallery, main foyer, front garden and hallways inbetween so lots of places to split the party up. Yes RITs would be perfect to get the guests to walk around and mingle in the various rooms.

 

How would I do the following:

 

1. Make it so the player is treated as a guest on the ground floor but hostile on 1st floor and basement?

 

2. Make it so the player is treated as a guest on the ground floor but as soom as he is seen with a weopon drawn, attacks a guest or is caught stealing something, he is then treated as hostile.

 

Many thanks

"I believe that what doesn't kill you simply makes you... stranger"

 

The Joker

Link to comment
Share on other sites

I may also post my ideas here, so you can decide/try out what works better. In difference to real AI you could use deaf & dumb AI as I've already mentioned in the comment system. If you need an alarm behaviour as described by Sotha, you could do it like those.

 

If the player causes an alarm you call a script that does the following things.

 

1. set spawnarg target on several waypoints that leads the AI out of the building (you may use several so they don't walk all in a line what may looks strange)

2. trigger some speakers with "Oh my god there's a thief"-like sounds

 

that's it

 

for the first one you use path_run entities causing the AI to run away (well, they don't really, it just look's like)

the speakers are needed as the AI doesn't really get alerted

 

I can make you an example map if needed

 

to answer your questions:

 

1. this is relatively easy: as I guess the floors will be seperated by visportals, you can use the zone system to achieve this behaviour

there is a command call_on_entry or so that calls a script

I don't know if the players team can be changed, but if so this is all the script would have to do

2. this should also be possible via scripting and/or the objective system

 

I have to check it out

 

you could at least use an invisible, non-mandatory and reversible objective

the condition would be "if AI sees player"

so every time the player steals something the script or whatever has to check if the goal is accomplished

I'm not sure if loot objects or similar things call scripts or trigger their targets if frobbed

if so, it would solve your little problem

 

again, I can try out and post a example map if you want to

Edited by Obsttorte

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

According to what Sotha wrote

 

if you use normal AI (not deaf & dumb), and they really get alerted at one time and start fleeing, you will most certainly get enourmous performance problems, and this exactly in the moments when things went terrible wrong for the player and the guards are starting to attack him

 

really, really bad timing for such things IMO

 

btw.: AI in my former post does of course refer to the civilians

 

EDIT: I just remembered that loot indeed call its targets when frobbed

 

so you can give all your loot a tdm_callscriptfuction entity as target (can be found under targets, the description says that it calls a global script function)

the script than checks whether the "AI sees you"-objective is fullfilled and then causes the necessary changes (changing players team if possible, didn't checked yet)

Edited by Obsttorte

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

Link to comment
Share on other sites

The hostility switch is likely done by changing the AI teams on the fly. Like said, a location trigger is likely the best choice. There are gameplay implications. The player must be aware of what area is forbidden. Also the switching area should be AI free to avoid the problem of AI getting mad instantly instead of asking politely the guest to return to the guest area. I would inspect Fieldmedic's reap as you sow mission.

 

As for the weapons draw problem, I have no clue. I have a hunch it might be very difficult.

 

Since you have a forbidden area conditions, you might benefit from FM's tension meter. It is very important the game gives feedback of what is allowed and what is not. Or the forbidden area transition should be obvious.

Clipper

-The mapper's best friend.

Link to comment
Share on other sites

If the player causes an alarm you call a script that does the following things.

 

1. set spawnarg target on several waypoints that leads the AI out of the building (you may use several so they don't walk all in a line what may looks strange)

2. trigger some speakers with "Oh my god there's a thief"-like sounds

 

that's it

 

for the first one you use path_run entities causing the AI to run away (well, they don't really, it just look's like)

the speakers are needed as the AI doesn't really get alerted

 

 

I believe I did the exact same thing with the prisoners once their cell door was opened in VFAT 1 so this shouldn't be a problem

 

 

if you use normal AI (not deaf & dumb), and they really get alerted at one time and start fleeing, you will most certainly get enourmous performance problems, and this exactly in the moments when things went terrible wrong for the player and the guards are starting to attack him

 

 

As Sotha suggested I might not have any guards on the ground floor but when the guests get alerted and flee the map will spawn guards that run into the guest area. This will be on a delay and will happen once the guests have disappeared from the map. This should give the impression that the guests ran and told some guards and make it so that there isn't too much AI all working at the same time. it would also give the player a chance to hide so they dont have to reload a save because suddenly they have 6 guards attacking them at once.

 

 

Since you have a forbidden area conditions, you might benefit from FM's tension meter. It is very important the game gives feedback of what is allowed and what is not. Or the forbidden area transition should be obvious.

 

 

I forgot about Fieldmedics tension meter. I believe it increased if you were in forbidden areas or had a weopon drawn. That might come in very handy.

 

Thank you for the very helpful replies guys. I'm sure I'll be posting more questions about this. This is probably beyond my mapping skills but you'll never improve unless you try to learn new things.

Edited by Sir Taffsalot

"I believe that what doesn't kill you simply makes you... stranger"

 

The Joker

Link to comment
Share on other sites

hi there

 

As for the weapons draw problem, I have no clue. I have a hunch it might be very difficult.

 

it's not, there's a command called getCurrentWeapon()

 

2. Make it so the player is treated as a guest on the ground floor but as soom as he is seen with a weopon drawn, attacks a guest or is caught stealing something, he is then treated as hostile.

 

let's suggest we use the objective system, the player has to drew his weapon to attack so I guess we dont have to handle this separately

 

we use an as above described objective consisting out of three sub-objectives

 

1. if AI sees player

2. script-controlled #LOOT

3. script-controlled #WEAPON

 

let's start with the latter

in your main routine you use the following code

void main() {
   do {
    if($player1.getCurrentWeapon() == 'atdm:weapon_unarmed') {
	    //player carries no weapon
	    unsetWeapon();
	 }
	 else {
	    //player carries weapon
	    setWeapon();
	 } //end-if
 sys.wait(1) //wait a sec
 } while(true); //end-do
} // end-main

 

setWeapon would be a method setting the third sub-objective to fulfilled, unsetWeapon does the opposite

 

as I've already said loot triggers its targets when frobbed so you could call a script that

- sets the second sub-objective to be fulfilled

- waits a short time

- sets the second so to not fulfilled

 

the logical condition for the objective is 1 AND (2 OR 3)

 

so if the player is seen AND steels something OR has his weapon drawn the complete objective will be fulfilled

(you can leave it irreversible in opposition to what I've earlier posted)

objectives can trigger targets / call script-functions when fullfilled, this can be handled via the objectives editor

 

if you are not familiar with scripting I can make you an example map or you just ask if something is unclear

I hope that helps

FM's: Builder Roads, Old Habits, Old Habits Rebuild

Mapping and Scripting: Apples and Peaches

Sculptris Models and Tutorials: Obsttortes Models

My wiki articles: Obstipedia

Texture Blending in DR: DR ASE Blend Exporter

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

    • nbohr1more

      Was checking out old translation packs and decided to fire up TDM 1.07. Rightful Property with sub-20 FPS areas yay! ( same areas run at 180FPS with cranked eye candy on 2.12 )
      · 2 replies
    • taffernicus

      i am so euphoric to see new FMs keep coming out and I am keen to try it out in my leisure time, then suddenly my PC is spouting a couple of S.M.A.R.T errors...
      tbf i cannot afford myself to miss my network emulator image file&progress, important ebooks, hyper-v checkpoint & hyper-v export and the precious thief & TDM gamesaves. Don't fall yourself into & lay your hands on crappy SSD
       
      · 3 replies
    • 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.
      · 7 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
×
×
  • Create New...