showing us the scripts might help too, and you don't need a new gsc file for every trigger(just add threads), infact you dont need a new gsc at all, its just a good way to organize sections of the maps scripting.Soviet wrote:i guess so. I copied and pasted the brush on the top and put it on the bottom. I changed the targetname and made an alternate script for the new trigger and linked to it in main .gsc. When i went to test it it was the same as it always was
Soviet's Mapping Help
Moderator: Core Staff
heres the one for my first trigger
heres the one for my second trigger
Code: Select all
main() {
level.elevatorDown = true; // elevator starts at bottom: true/false
level.elevatorMoving = false; // elevator is not currently moving
thread elevator_start();
}
elevator_start() {
elevator = getentarray ("elevatorswitch","targetname");
if ( isdefined(elevator) )
for (i = 0; i < elevator.size; i++)
elevator[i] thread elevator_think();
}
elevator_think() {
while (1) {
self waittill ("trigger");
if (!level.elevatorMoving)
thread elevator_move();
}
}
elevator_move() {
elevatormodel = getent ("elevatormodel", "targetname");
level.elevatorMoving = true;
speed = 2;
height = 192;
wait (1);
if (level.elevatorDown) { // moves to top
elevatormodel playsound ("elevator1"); // sound definition for soundaliases.csv
wait (1); // wait a second to hear the motor start and then start the movement of the lift - feels more realistic
elevatormodel moveZ (-250,4,1,1);
elevatormodel waittill ("movedone");
level.elevatorDown = false;
}
else { // moves to bottom
elevatormodel playsound ("elevator1"); // sound definition for soundaliases.csv
wait (1); // wait a second to hear the motor start and then start the movement of the lift - feels more realistic
elevatormodel moveZ (250,4,1,1);
elevatormodel waittill ("movedone");
level.elevatorDown = true;
}
level.elevatorMoving = false;
}
Code: Select all
main() {
level.elevatorDown = true; // elevator starts at bottom: true/false
level.elevatorMoving = false; // elevator is not currently moving
thread elevator_start();
}
elevator_start() {
elevator = getentarray ("elevatorswitch2","targetname");
if ( isdefined(elevator) )
for (i = 0; i < elevator.size; i++)
elevator[i] thread elevator_think();
}
elevator_think() {
while (1) {
self waittill ("trigger");
if (!level.elevatorMoving)
thread elevator_move();
}
}
elevator_move() {
elevatormodel = getent ("elevatormodel", "targetname");
level.elevatorMoving = true;
speed = 2;
height = 192;
wait (1);
if (level.elevatorDown) { // moves to top
elevatormodel playsound ("elevator1"); // sound definition for soundaliases.csv
wait (1); // wait a second to hear the motor start and then start the movement of the lift - feels more realistic
elevatormodel moveZ (-250,4,1,1);
elevatormodel waittill ("movedone");
level.elevatorDown = false;
}
else { // moves to bottom
elevatormodel playsound ("elevator1"); // sound definition for soundaliases.csv
wait (1); // wait a second to hear the motor start and then start the movement of the lift - feels more realistic
elevatormodel moveZ (250,4,1,1);
elevatormodel waittill ("movedone");
level.elevatorDown = true;
}
level.elevatorMoving = false;
}
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
For a start you cannot use "level.elevatordown" twice. As level means it is used in the entire script. So if level.elevatordown is down on one elevator, then it will be down for the other. Make sure you rename all "level" stuff.
(Thats why you should never copy and paste
)
(Thats why you should never copy and paste


Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Not 100% sure if this is necessary or not... but in my main folder. I have a folder called "xmodel" with all of the xmodels extracted from the pk3s in there (1 of the pk3s has this folder)Soviet wrote:well i sort of got the elevator to work...whatever. thanks for the help on that.
i did what you said for the models, but it still doesn't work. I recompiled with those folders filled with the files in my call of duty/main folder and they still aren't clipped, suggestions?
Other than that, I have 2 folder called collmaps and env in my textures folder.

Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
The clipped models are inside the collmaps folder, you need to open the model from there by going to file>load and point it to the textures\collmaps folder to find the model.Soviet wrote:well i sort of got the elevator to work...whatever. thanks for the help on that.
i did what you said for the models, but it still doesn't work. I recompiled with those folders filled with the files in my call of duty/main folder and they still aren't clipped, suggestions?
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Nein. You do not have to open the collmaps folder 
The way I do it...
right-click.
Misc<model
Type in...
model
xmodel/<modelname>
And then compile. And that works fine for me.

The way I do it...
right-click.
Misc<model
Type in...
model
xmodel/<modelname>
And then compile. And that works fine for me.

Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
well then maybe it is as long as the folder you get the model from is in main, then upon compiling the model receives clipping due to the presence of the actual model file in the main folder 
---edit---
after extracting xmodel folder to main and recomiling, the models are still not clipped. Right now i'm too lazy to try luke's method, will work on it later

---edit---
after extracting xmodel folder to main and recomiling, the models are still not clipped. Right now i'm too lazy to try luke's method, will work on it later
k


Coding is Poetry. Mapping is Art.
"Cause im the sexiest mapper ever...except for nm, that sexy man" - Soviet
-=[CoDJumper.com Movies]=-
[Ambush] || [Backlot] || [Bloc] || [Bog] || [Broadcast] || [Chinatown] || [Countdown]
[Crash] || [Creek] || [Crossfire] || [District] || [Downpour] || [Killhouse] || [Overgrown]
[Pipeline] || [Shipment & Wetwork] || [Showdown] || [Strike] || [Vacant]
"Cause im the sexiest mapper ever...except for nm, that sexy man" - Soviet
-=[CoDJumper.com Movies]=-
[Ambush] || [Backlot] || [Bloc] || [Bog] || [Broadcast] || [Chinatown] || [Countdown]
[Crash] || [Creek] || [Crossfire] || [District] || [Downpour] || [Killhouse] || [Overgrown]
[Pipeline] || [Shipment & Wetwork] || [Showdown] || [Strike] || [Vacant]
-
- Core Staff
- Posts: 13315
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
I believe script models are not solid because they can be scripted. If you want to move a solid model, then you have to use lukes method (with a slight change).Soviet wrote:ah well, stupid meI was using the script_model entity instead of the misc_model entity. Commence in beating me with a bloody baseball bat please
Load the collmap (file<load)
Then delete the model (not the clips).
Now get the model back using "script_model"
And make all the clip brushes as a script_brushmodel
Then move them together.

Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
thanks, ill keep that in mind if i ever want to do it. Unfortunately all i wanted was a stationary solid modelDrofder2004 wrote:I believe script models are not solid because they can be scripted. If you want to move a solid model, then you have to use lukes method (with a slight change).Soviet wrote:ah well, stupid meI was using the script_model entity instead of the misc_model entity. Commence in beating me with a bloody baseball bat please
Load the collmap (file<load)
Then delete the model (not the clips).
Now get the model back using "script_model"
And make all the clip brushes as a script_brushmodel
Then move them together.
ok, next comes a more complex subject: lighting. I am not sure if i am going at it the correct way. I added worldspawn entities and created my first light. The lighting does not appearing to be working on that light though...here are my light's properties

if it matters the light is located in a contained area with no access to outdoor light.
and all my worldspawn settings are default for mp_depot and applied to the inner visible part of the skybox using the ctrl+shift+click method
now, i am not absolutely complete with my map but i wished to add lighting to experiment before i continued. There are no skybox leaks that i am aware of because drofder created the skybox. The only error i am seeing upon compiling is
other than that i koow of nothing else that would effect my attempts of making a light.

if it matters the light is located in a contained area with no access to outdoor light.
and all my worldspawn settings are default for mp_depot and applied to the inner visible part of the skybox using the ctrl+shift+click method
Code: Select all
"_color" "200 200 205"
"ambient" "0.16"
"sunlight" "1"
"suncolor" "100 100 210"
"sundirection" "-45 95 0"
"sundiffusecolor" "200 200 210"
"diffusefraction" "0.6"
Code: Select all
Floatplane: bad normal
The problem with the light not working is because you've put the worldspawn settings in the wrong place, they should be entered under worldspawn, which is at the bottom of the entity list.
The only values you can use on lights, to make the light bigger ect, are listed in the info box when light is selected.
The only values you can use on lights, to make the light bigger ect, are listed in the info box when light is selected.
So remove all those worldspawn settings from the light entity, and either enter the worldspawn settings manually in "worldspawn" or dl this tool which will enter them for u(outside of radiant), and u can choose from all the stock map values to use in ur map if u wanted http://www.modsonline.com/index.php?mod ... ll&id=1082"light" overrides the default 300 intensity.
Nonlinear checkbox gives inverse square falloff instead of linear
Angle adds light:surface angle calculations (only valid for "Linear" lights) (wolf)
Lights pointed at a target will be spotlights.
"radius" overrides the default 64 unit radius of a spotlight at the target point.
"exponent" changes the default 0 exponent for the angle falloff. Must be a non-negative integer. High numbers (10-20) are needed for narrow spotlight angles to show falloff over angle.
"fade" falloff/radius adjustment value. multiply the run of the slope by "fade" (1.0f default) (only valid for "Linear" lights) (wolf)
"overbrightShift" controls overbright radius. 0 is default, 1 is no overbrighting at all, fractions in between do linear interpolation.
Who is online
Users browsing this forum: No registered users and 1 guest