Making Barbwire Hurt?

Post your scripting questions / solutions here

Moderator: Moderators

TheStorm
Captain
Posts: 233
Joined: Mon Oct 07, 2002 7:45 am
Location: Gavle, Sweden
Contact:

Re: Making Barbwire Hurt?

Post by TheStorm »

Sgt.Pepper wrote:Hey There,

I asked this at TMT, but I'm afraid I didn't quite understand the response I got, and to avoid making myself look more like a idiot there, I decide to show you guys my lack of knowledge!
I can just say that no one over at TMT will see you as an idiot for asking questions or not understanding the answers. Just be clear about what part you didn't understand (or just say that you didn't get anything). Give the people a chance to explain in an other way or someone else might come up with another idea etc.

We where all n00bs from the beginning.....I have not yet seen a newborn child with any talent for mapping/scripting :P :lol:
TMT admin, visit www.modtheater.com
HITP Lead Mapper
Member of Electronic Arts MOHteam
Sgt.Pepper
Sergeant
Posts: 69
Joined: Tue Feb 25, 2003 5:41 pm
Location: Canada

Post by Sgt.Pepper »

Thanks for the encouraging words Storm. I'm just trying not to be a nuisance. I do search before I post, but as you said it sometimes comes down to the wording that can make the difference in the replies. Plus, between searching and looking at other scripts, I think I mess myself up, more then I help myself. I just hope that if I keep reading then bits and peices will fall into place. Plus, I would hate to post something that's been done a few times already, so I try to word things in a non-offensive way.

In reply to jv_map,

thanks for that detailed reply. At a quick glace, I do understand some of what you've written. So I'll mess about with it, and see what I can come up with. Unfortunately it's a busy week at school, so it'll have to wait for the weekend.

For the end result, I would like to have it so that when someone tries to leave the map they will say something along the lines "I'm am trying go under the map". Utterly humiliate someone who tries it. In my post at TMT I was given a line to add that prints a message for the person in the trigger, so that can be used to warn the person as well. A lot of work for map fixes, but it also serves as a great learning experience.

Thanks again for your replies.
WarTech
Colour Sergeant
Posts: 88
Joined: Mon May 05, 2003 3:15 am

Post by WarTech »

Sgt.Pepper wrote:Thanks for that detailed reply, it really helped clear the box space up. I assumed the wire was spawned from the center, so I adjusted the box to fit the wire, and after a few miscalculations it worked.

I'm really thankful for all the help I got here. This has been bugging me for some time now. I keep getting a laugh out of having myself go near the wire and blowing up!

So now I'll mess around with the damage level and search other scripts for an appropriate death message.

Thanks again, it is much appreciated.
Hi Sgt.Pepper

I want to do the same with my barbwire. CAN YOU PLEASE post your script for the barbwire and how to use it. I dont know much about the script but want to learn it. So far I can only spawn simple items into the maps. Please Help. Thanks in advance.
Sgt.Pepper
Sergeant
Posts: 69
Joined: Tue Feb 25, 2003 5:41 pm
Location: Canada

Post by Sgt.Pepper »

I'm sorry WarTech, I got your PM, but neglected to reply. I've been busy these past few weeks. :oops:

Ok, here is the script that these fine people helped me with. You can get more information browsing through this thread. Lots of info posted here.

/Allie Map Fix
local.wire = spawn script_model
local.wire model "static/barbwire_long_two_post.tik"
local.wire.origin = ( 3279.00 -82.00 384.00 )
local.wire.angles = (0 0 0)
local.wire.scale = 0.70
local.wire solid

local.trig = spawn trigger_multiple
local.trig targetname hurt
local.trig setsize ( 3247.00 -306.00 328.00 ) ( 3311.00 142.00 440.00 )
local.trig setthread _mythread
local.trig wait 0.05 // How often the trig acts
local.trig delay 0 // How long before trig acts



$world farplane_color "0.752941 0.752941 0.752941"
level.fogplane = 6700
$world farplane level.fogplane

level waitTill prespawn


//*** Precache Dm Stuff
exec global/DMprecache.scr
exec global/ambient.scr
exec global/door_locked.scr::lock

level.script = maps/dm/Angryfields.scr
level.music = "MP_Holland_DM"


level waittill spawn

_mythread:
$hurt volumedamage 1000



If that turns out as I intended, then the parts you are interested in should be in red. Some of the values you will have to mess with. I upped the volumedamage for testing.

Hope that helps.
nuggets
General
Posts: 1006
Joined: Fri Feb 28, 2003 2:57 am
Location: U-england-K (england in the UK) :P
Contact:

Post by nuggets »

just create a trigger->mulitple in radiant around the barbwire
key:targetname
value: barbwire_trigger
key: setthread
value: barbwire

barbwire:
self volumedamage 1000 //dependant on the damage you want ot cause
end

i can't see why u'd want to bother spawning the barbwire and trigger instead of just creating it :?:
hope this helps, prob not cos it's all foreign 2 me :-/
Sgt.Pepper
Sergeant
Posts: 69
Joined: Tue Feb 25, 2003 5:41 pm
Location: Canada

Post by Sgt.Pepper »

I'm doing it through scripting because it's stock maps that the barbwire was added to. Or it's a custom map that I wanted to fix. But as time went on I just wanted to see what could be done just through scripting. For some reason I find it really fascinating to see what can be done to stock maps.
nuggets
General
Posts: 1006
Joined: Fri Feb 28, 2003 2:57 am
Location: U-england-K (england in the UK) :P
Contact:

Post by nuggets »

ahhh i see...

scripting is the dog's b*ll*ocks i can't argue with that, have u tried converting the SP maps into MP maps?

although the ai don't actually shoot any1 (which is a problem) can you ad visdata to it to increase the fps,

through the scripting all the ai can be removed, so it's only the question of... will it be playable?
hope this helps, prob not cos it's all foreign 2 me :-/
Sgt.Pepper
Sergeant
Posts: 69
Joined: Tue Feb 25, 2003 5:41 pm
Location: Canada

Post by Sgt.Pepper »

Yeah, it certainly is a pain in the butt, scripting. Especially considering I'm a total noob at it. It's a matter of endlessly looking at other stuff and seeing how it can be applied in different situations.

No, I haven't tried making an SP map MP. I think that would take a lot of work. As you say, even without the AI, making the map playable would be the hardest part. I would think that one would have to decompile it in order to add sections, or remove them to make gameplay better.
Post Reply