truck ride tutorial?

Post your scripting questions / solutions here

Moderator: Moderators

User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

truck ride tutorial?

Post by wacko »

anyone knowing a tutorial for a truck following some waypoints that can carry MP-players? I just found a truck without collision and those with, I couldn't get moving :?

Or, how could I bind clip brushes to it? First thing the truck does is trying to get on top of those brushes :evil:
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

clip

Post by tltrude »

Make the clip brushes all one script_object.
Tom Trude,

Image
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

mmm, i have just one clip brush at the moment. :?

i used a truck with
classname/vehicle_german_opeltruck (I'd prefer a gmctruck, though)
model/vehicles/opeltruck.tik
targetname/truck

and a clip brush script_object with
targetname/truckclip on the rear bed/platform

and the script is

Code: Select all

main:
    exec global/ai.scr
    exec global/loadout.scr maps/testride.scr 
    exec global/friendly.scr

	  level waittill prespawn
    exec global/ambient.scr testride
    thread truckprep
      level waittill spawn
      level.script = "maps testride.scr"
end

truckprep:
$truckclip bind $truck
end

truckdrive:
wait 3
$trucktrig nottriggerable
$truck drive $wp_01
$trucktrig triggerable
end
map and script would be at http://www.decalattack.com/recyclebin/t ... _truck.zip for those who would be so kind to waste their time on my prob...
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

maybe another map worth to study?
lizardkid
Windows Zealot
Posts: 3672
Joined: Fri Mar 19, 2004 7:16 pm
Location: Helena MT

Post by lizardkid »

ill check it out...

you've just solved my problem too, binding the collision to the truck!!!! thanx Wacko! (that doesnt seem too flattering to say, but what the hey!)
Moderator

۞
Abyssus pro sapientia
Olympus pro Ignarus
۞

AND STUFF™ © 2006
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

lizardkid wrote:you've just solved my problem too, binding the collision to the truck!!!! thanx Wacko! (that doesnt seem too flattering to say, but what the hey!)
is this it's working for u? :shock:
lizardkid
Windows Zealot
Posts: 3672
Joined: Fri Mar 19, 2004 7:16 pm
Location: Helena MT

Post by lizardkid »

no no no, what i meant was i had never been able to get the collision onto the truck, i use SH and have the colision, and truck, but couldnt get it to stay on the truck. i had forgotten the bind keyword.
i havent opened up the map just yet, did you make it in SH or AA? i couldn't see anything but one untextured square in SH.

i did notice one thing about your post though, you said the truck tries to run over the script_object? try putting the collision under the ground and make sure it targets your truck. (control-e works well) then try your script.

sry if this doesn't help.
Moderator

۞
Abyssus pro sapientia
Olympus pro Ignarus
۞

AND STUFF™ © 2006
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

lizardkid wrote:i did notice one thing about your post though, you said the truck tries to run over the script_object? try putting the collision under the ground and make sure it targets your truck. (control-e works well) then try your script.
the clip brush would move up into the truck position when the level starts? and where would the center of the truck model and of the collision brush be? will give it a try but additional help is likely to be neccesary :oops:
rodney
Second Lieutenant
Posts: 172
Joined: Sat Mar 13, 2004 5:49 pm

Post by rodney »

I like the example!!!

I place a motorbiker!!!

It is good!!!

When i can not modify the speed...

When i modify the speed???

$truck speed 500000???

???

Tranks!!!
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

either i'm too stupid or it's not possible this way... :cry:

I know that I have seen a tutorial map with a collision set placed below the map but can't rember it's name or topic. Maybe this would be of help? Anyone knows which map this was?

At Manstein's leveldesign, there's a different approach (using a script_origin the player is glued to) but this is just for 1 player. Something else about that example is, that it is using a info_splinpath where I'd have to set the angles and the speed for each waypoint. Rather annoying, but maybe the best way to get the truck driving backwards which would be neccessary in my case.

If anyone had an idea of how to attach that clip brush to a GMC-truck model or knew another way to get some players on the bed of a driving truck, please let me know
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

Here is how I make collision for trucks Image

It works good for me the clips are 1 script_object after I make them a script_object I deselect them select the truck then the clip brushes and press control K so that the truck targets the script_object .
Image
User avatar
tltrude
Chuck Norris
Posts: 4774
Joined: Sun Jul 07, 2002 4:03 am
Location: Oklahoma, USA
Contact:

origin

Post by tltrude »

I see you have an origin brush as part of the script object. That's good because the trucks origin is on the ground and not in the center of the truck.
Tom Trude,

Image
User avatar
wacko
Field Marshal
Posts: 2085
Joined: Fri Jul 05, 2002 8:42 pm
Location: Germany

Post by wacko »

thanks for the help so far :)

yeah, this "clip construction" would be nice...

1st of all, what general differences are between the different vehicles I can find in the entity list? There are some in animate (no GMC though), some in static, some in vehicle. Is there an explanation to be found somewhere?
I see that some can execute a 'drive' command in the script, some can 'followpath', some do just nothing, some have a collision model, some don't. Maybe even some of them can be targeted by a clip brush and some don't!?

2nd, is there a GMC truck at all which could do anything similar to driving and could be targeted by a clip? All examples I have found are using that German Opel and I really would prefer an US quality product :wink: (I want the 'soft top' which would block the player's view during ride and drastically reduce the amount of surrounding landscape I have to build :wink:).
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

hmm never noticed the ones in the animate directory . They all seem to say for script_model use in the tiks.
Image
rodney
Second Lieutenant
Posts: 172
Joined: Sat Mar 13, 2004 5:49 pm

Post by rodney »

I have a clip... very good!!!

Much more best of this...

When i can not upload the file!!!

Please... what site i upload???

And what modify the speed of the truck???

$truck speed 500000???

I can not!!!
Post Reply