PDA

View Full Version : Hammer, Scorpio, Buzz? Can you do this?


imported_FlyingNun
11-06-2003, 02:36 PM
I would really like a few sniper rifles to spawn in place of the panzerfausts in SD and RE maps. That way I can turn off allowing sniper rifles and limit their usage.

I have looked at all of the gsc files in pak5 but have no clue where to start becuase I cannot find anything related to the spawn parameters of the panzerfausts. been scratching my head over this one for a few days now. Any help would be appreciated.

thanks, Nun

{PJG} ProjectJunoGold Admin

bullet-worm
11-06-2003, 03:25 PM
I would almost bet those are going to be in the specific map files, as they have to be PLACED in the map. Might not be hard to find...

If I get a few minutes I'll do a quick search through the map files and see if I can find where (and how) they are spawning the rocket/sg42 placements

worm

imported_FlyingNun
11-06-2003, 04:30 PM
Thanks worm!

Nun

bullet-worm
11-06-2003, 06:03 PM
At first glance, it looks like the weapons are placed (as entities) in the map editor. The disable only goes back and deletes them before the map starts. Unfortunately, that will likely mean you will need to edit the map in the map editor to change it...

But thats at first glance, I'll keep looking but i wouldn't get my hopes up.

worm

imported_FlyingNun
11-06-2003, 06:15 PM
hmm

So your saying that all of the weapons are placed on the ground at whatever coordinates, then all but the panzerfausts are removed before the map actually starts?

If this is the case....strange!!

Sitting_Duck
11-06-2003, 06:20 PM
Well you should be able to spawn the weapons into the map server side....like how we did for MoH. The key to all of this will be to follow the scripting done for the panzerfaust, where as long as it is in the hands of an individual you can not collect another.....Yep it should work just fine. I'm at my job right now so investigating it is not possible...even though my supervisor/boss is as jazzed about CoD as I am. :!:

imported_FlyingNun
11-06-2003, 06:35 PM
Thankyou SittingDuck.

I'm really looking forward to getting this to work. I have mentioned it to several squad buddies and friends and they all like the idea.

I'm at work too so I can't look into it either.

By the way, nice work on your BT realism mod. I used it in my server for awhile. Now that COD is out though I got rid of that server. :)


Nun

{PJG} ProjectJunoGold Admin

bullet-worm
11-07-2003, 02:36 PM
Okay, found where they are spawning the items, it is actually INSIDE the map files (.bsp files). Here is what one looks like:

"origin" "1157 4391 7"
"model" "xmodel/weapon_panzerfaust_ammo"
"classname" "mpweapon_panzerfaust"
"angles" "0 270 180"

I imagine a little lookup to what a sniper rifles model is and its classname is, and a little switch-a-roo, and you will have a sniper laying on the ground there. However, this will be a large mod (size wize) as it would be the whole .bsp file again. (I think every map is over 10 Meg!)

I am sure there must be a way to spawn objects onto a map in a sererate script, but I really have way too many other things I am working on right now to go down that trail. I hope someone else who is familiar with spawning objects into maps will help out!

worm

imported_FlyingNun
11-07-2003, 04:54 PM
thanks worm!

May I ask what program you used to open the bsp file? would like to try the ol' switcharoo.

Nun

bullet-worm
11-07-2003, 06:11 PM
I just used wordpad... way to big for notepad...

but there are already people spawning objects into maps (such as spawnpoints) without going to that extreme. I don't really know how to do it yet, but it IS being done. Check out some of the modder boards! This forum is mostly server support, with a lot of admins, and not a lot of modders.

worm

Pyldrvr
11-08-2003, 03:32 PM
try this link and see if it helps you.

http://www.iwnation.com/Forums/index.php?showtopic=513

Sitting_Duck
11-08-2003, 04:55 PM
Ok you don't need to recompile a bsp file to spawn a new object into a map. As long as its server side you should be able to script it, since it is an existing item within the game files. You would not need to "switch out" the "base" object, either turn that object off or adjust the "base" items coordinates to fit your new item. This way there are no conflicts between the two so the new item will not "crash" the script.

So if this if the coordinates for the faust and you wanted a sniper rifle...
"origin" "1157 4391 7"
"model" "xmodel/weapon_panzerfaust_ammo"
"classname" "mpweapon_panzerfaust"
"angles" "0 270 180"

//New item

"origin" "1205 4399 7"
"model" "xmodel/weapon_name_ammo"
"classname" "mpweapon_name"
"angles" "0 270 180"

The best way I found in moh to get a new object spawned was to have a command line of sorts which executed a seperate script file.
I am at work again so I don't have my old files in front of me. But I did have a "how to" at themoddingtheater.com a long time ago. This gave you examples to work with. The greatest concern is not having conflicts with the base objects. So I would always spawn one item first in an open area. I would make sure it was there, then after that as I placed groups of new objects I would check for my origional item. This item was an indicator if there was any problems. (if it was gone, there was a conflict.)


1205 4399 7 = The first group of numbers is either N-S or E-W, the last number determines depth on the map. Depth is crucial because you could end up with a newly spawned object under the ground and not see it. Or you could end up with a hovering ammo crate depending on what you are spawning.

This same theory to spawning objects can also be used for spawning new spawn points for players. CoD seems to have a great number of them right now but in the future its a great tool for custom maps which lack them.

I hope I made some sense, and I am on the right track. This is all theory with CoD for me since I haven't tested the proven methods of MOH yet.

Sitting_Duck
11-08-2003, 05:10 PM
I tracked down one of my old posts concerning the method of spawning new items to a map. Naturally the language is a little different, but the principal should work.
http://www.modtheater.com/forum/showthread.php?t=6117 If I have time on Monday I'll give this a shot.

imported_FlyingNun
11-09-2003, 09:51 PM
thanks Duck

I'm not good with scripting. You guys are, so I wait patiently.

Nun

thecleaner
11-09-2003, 10:42 PM
yeah me either, is there a way to make this into a mod?
with mabye an option to what u want spawned in, and what u want to leave on the weapons menu in game..

Sitting_Duck
11-10-2003, 12:17 AM
Once you get the script right to spawn an object, all you will need then is the object name. I figure placing the new weapons around the panzerfaust crate it will be easy enough.

If my day calms down tomorrow I'll take a looksy.

TaeBo-
12-18-2003, 07:20 PM
I would really like to get this working also. I think I may be able to change all of the entities with a script, and that is what I am messing around with now. However, all of them would be changed to the same gun, and there would be no way to limit the amount in each box, unless you made for each map, but even then I am not sure.