The teory of custom stock maps without downloads

Post your scripting questions / solutions here

Moderator: Moderators

Post Reply
User avatar
mcunha98
Lieutenant Colonel
Posts: 384
Joined: Sat Jan 17, 2004 1:52 am
Location: Brasil
Contact:

The teory of custom stock maps without downloads

Post by mcunha98 »

Hi,

In many servers of NET i see customized maps based into the stock maps (things like Destroyed Village with King Tiger Tanks, Remagem with cracked walls and V2 destroyed) all without need force download of a pk3 customized.

Exists a tutorial or way to i know this method of custom stock maps ????
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

Do a search for "spawn object in stock maps". It is all done in the server side script, so learn any scripting you can and you should be well off.
Admin .MAP Forums
Image
Head above heels.
Green Beret
Major General
Posts: 746
Joined: Mon Apr 19, 2004 12:21 pm
Contact:

Post by Green Beret »

here is a sample

Code: Select all

local.bike = spawn script_model
local.bike model "static/vehicle_bmwbike.tik" //for/obj/obj_team4
local.bike.origin = ( 228 474 384 ) //coords(see below)
local.bike.angles = ( 0 0 0 )
local.bike.scale = 1.0
local.bike ghost

to get the coords(were u want the item)just cruise around the map,finsd were u want your item,and type coord in the console :wink:
Image
User avatar
mcunha98
Lieutenant Colonel
Posts: 384
Joined: Sat Jan 17, 2004 1:52 am
Location: Brasil
Contact:

Post by mcunha98 »

Oh my GOD !!!!

You tell for i use a script to spawn things in map.
Ok, in past i learn something about this way of making objects.
But, i dont understand the "logic" of this method. In all sample i see, the objects spawn its a truck, flak, etc...
My questions:

1) How i create for example a new wall (a simple brush) ???

2) Where i put the new .scr file, in server ?
How client understand this configuration ????

3) Is possible change/add spawn points of axis/allies and is possible edit stock maps of single player (i reforce, a TUTORIAL is welcome)
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

mcunha98 wrote:1) How i create for example a new wall (a simple brush) ???
You can't. Not unless you have a model that looks like a wall.
mcunha98 wrote:2) Where i put the new .scr file, in server ? How client understand this configuration ????
You do not create a new script file, you edit the existing ones ( located inside the file "Pak5.pk3" ).
mcunha98 wrote:3) Is possible change/add spawn points of axis/allies and is possible edit stock maps of single player (i reforce, a TUTORIAL is welcome)
Spawn change is possible by moving players spawned in a specific spawn to a new location. I've done just this in the "Hunt spawn fix" mod, get it here.
Admin .MAP Forums
Image
Head above heels.
User avatar
mcunha98
Lieutenant Colonel
Posts: 384
Joined: Sat Jan 17, 2004 1:52 am
Location: Brasil
Contact:

Post by mcunha98 »

You can't. Not unless you have a model that looks like a wall.
I dont understud your words.
Please more details...
User avatar
hogleg
General
Posts: 1577
Joined: Tue Sep 09, 2003 5:23 pm
Location: Down South Hillbilly Country

Post by hogleg »

You can't script a brush to appear in a stock map.
If you make a wall with a modeling program you can spawn that into the map.
"all the governments in the world are corrupt and in the hands of the Illuminati"
Grassy
First Lieutenant
Posts: 221
Joined: Sun Aug 22, 2004 11:36 am

Post by Grassy »

Or to fix a glitch (see defenition) in an existing map you can spawn a script_object, give it some dimensions and make it solid. Rough and ready way to do it but the only way if the maps source file is not available.

Code: Select all

//------- to add in a clip brush for player blocking //-------
local.clipbrush = spawn script_object
local.clipbrush.origin = ( 4080 4128 -16 )
local.clipbrush setsize ( 0 0 0 ) ( 42 152 568 )
local.clipbrush solid
Glitch;
An area of a map that causes a player to be hidden from view by others, or allows the player to shoot others from a concealed position behind an object or structure.
User avatar
|NSC|-Steelie-NS*LR*
Sergeant
Posts: 54
Joined: Mon Dec 27, 2004 11:24 am
Location: The Netherlands
Contact:

Post by |NSC|-Steelie-NS*LR* »

k, but how do you find the tik's of what you wanna spawn? because in Radiant there are different paths of things then you guys wrote here.
where do you find em?

EDIT:

I've found them: you can find 'em in pak 0, under static.
Rookie One.pl
Site Admin
Posts: 2752
Joined: Fri Jan 31, 2003 7:49 pm
Location: Nowa Wies Tworoska, Poland
Contact:

Post by Rookie One.pl »

Not static only. ;) If you want to spawn MG42s, they are in models/statweapons.
Admin
Image
Image
Honour guide me.

here's my stuff - inequation.org | here's where I work - thefarm51.com
User avatar
G3mInI
First Lieutenant
Posts: 187
Joined: Sat Jun 29, 2002 3:49 am

Post by G3mInI »

Spawning a wall with texture actually can be done. I have done it. But sometimes I get strange results in my setsize. Would like for the gurus to further test and/or explain just how it works.

example:

local.wall = spawn worldspawn origin ( 640 -235 512 )
local.wall setsize ( -256 -8 -256 ) ( 256 8 256 )
local.wall nodamage


Now then I just threw those coordinates out. But if you actually use this and spawn a brush alongside a wall or touching a wall it will assume that walls texture. I have done it. Also once I tried to block a door in a stock map, so I spawned a worldspawn the same size as the door except made it 16 units thick instead of 8. It took on the french door texture but showed up perpendicular to the door. However the actual brush was in the door frame as I could not enter the door, but the texture was sticking out perpendicular to the door and I could walk right through it. I did this on Southern France for the door that is the entrance to the only single room in the map. Its up on the second level near one corner of the map. Has two windows in it.

This needs more testing, cause it sure would be nice to effectively spawn a textured brush. Im thinking the only catch thus far is it needs to touch or overlap an existing brush in the map.
I also was getting some sort of lightmap error in the console. It's been too long since I did this and I have not tried it again. So maybe it really cant be done afterall.

G3mInI
*Area51*G3mInI****Gen

http://www.area51moh.com
Rookie One.pl
Site Admin
Posts: 2752
Joined: Fri Jan 31, 2003 7:49 pm
Location: Nowa Wies Tworoska, Poland
Contact:

Post by Rookie One.pl »

Wow! I'd never come up with an idea of spawning a worldspawn, I thought this is the class of the whole game world... :shock: I'll have a look into it when I've got a bit more time, sounds promising... :P
Admin
Image
Image
Honour guide me.

here's my stuff - inequation.org | here's where I work - thefarm51.com
Post Reply