Page 1 of 3
50mm AT GUN brush/model _ROX, JV, HELP???
Posted: Mon May 12, 2003 2:45 pm
by Slyk
Thought of _Rox and JV first, but I've got this brush worked model of a 50mm AT gun and turned it into a script_object. . . but, alas, I'm an idiot about how to get it to fire. IS that possible? Doesn't have to have any real left/right and up/down movement, just produce a fired shell, smoke/flash and sound. Hoping someone can tell me what is involved. Don't 'need' it to work, but would be cool....having Russians shooting Panzer with 88s just doesn't do it for me...........
Guess you could pretend that the 88s are actually Russian 85s and build a new base for them..hmmmmmm
http://www.contacthelpline.org/images/50mmatgun1.jpg - (image too big - fix it - Surg)

Posted: Mon May 12, 2003 3:17 pm
by SNap007be
crate this model in a 3D Program, not just from brushes, then compare it to another SH one and copy and modify the properties.
Posted: Mon May 12, 2003 4:47 pm
by Slyk
I based it loosely on the nebelwerfer model...same height, axle width etc. Guess that would be the closest thing to model it too, but I'm not up on doing any moddeling with other programs. Just wondering if somehow a trigger can work the thing with scripting. Would you set up a new .tik file and then add emitter entities for the smoke/flash origins, etc. AND, if so, how????????
Posted: Mon May 12, 2003 6:59 pm
by SNap007be
Sorry, dunno like this, suggest you start studying MS and 3DMax, for the future.
Posted: Mon May 12, 2003 7:22 pm
by Yarik
So far the only thing you CAN do is import and export as a MOHAA model. You cant really do anything with it as far as muzzle or flashes go or animations for that matter. I suggest you go to
http://www.discreet.com/products/gmax/game_request.html
Vote and fill out the form. If a lot of people do it then they will release a game pack wich will include plugins so you will be able to do everything from animations muzzle flash smoke etc etc....
Posted: Tue May 13, 2003 2:05 am
by Slyk
I was thinking that there was a thread a few months ago about some sort of emitter that would fire like a gun. If that IS true, then it seem like I might be able to use some sort of lever with a trigger that would 'fire' a script to create the illusion of a cannon firing.........or maybe not. Have to check that out and do some digging. Not too interested in any animations right now...how I figured it, I would just put this guns in stationary locations with very narrow fields of view, basically where they would ambush a tank and have no option to move left/right.
Posted: Tue May 13, 2003 6:34 am
by jv_map
Probably you could just spawn a projectile and send it forward
Example:
Code: Select all
at50fire:
local.shell = spawn projectile
local.shell addvelocity ($at50.forwardvector * 128)
local.shell dlight 0.8 0.6 0.5 // emit light
local.shell dmlife 2 // don't fly for more than 2 secs
local.shell explodeontouch
local.shell explosionmodel "emitters/mortar_dirt.tik"
local.shell hitdamage 10000 // a lot
local.shell impactmarkshader "blastmark"
local.shell meansofdeath explosion
local.shell smashthroughglass 0
end
Possibly you have to set angles and speed instead of using addvelocity. In the example I assumed a at50 targetname of $at50.
Posted: Tue May 13, 2003 8:06 am
by mohaa_rox
And to get those smoke stuff that come out from the barrel, as well as the rockets flying, read my nebelwerfer tut.
Posted: Tue May 13, 2003 12:30 pm
by Slyk
Thanks JV, _Rox........ I'll try that right away and see what I get. I was pretty sure most of it could be done with scripting, just how much and WHAT. Guessing that I could add a 'gravity' to the projectile also, right? I'll try to get a firing lever to work also for a visual cue.
Huge thanks guys! Hope I can work it out.
Posted: Wed May 14, 2003 4:06 pm
by Slyk
Ok, have my trigger and switch working that gives the user a lever to pull to fire the gun. EXCEPT the gun doesn't produce the 'shell' per the JV script suggestion. I'm sure it's me because I am totally unsure of what type of 'emitter/script_object/etc' thing to use to produce the shell. I assumed I could put an emitter in just in front of the gun muzzle and have the script create the effect from that point. Any ideas?
Posted: Wed May 14, 2003 4:39 pm
by jv_map
You don't need an emitter, it should be possible to spawn a projectile anywhere.
Posted: Wed May 14, 2003 5:22 pm
by Slyk
Ok, but 'what' spawns the projectile? If not an entity, then I'm guessing that I need to add coordinates for the location, right? My other design experience (different engine) always was based on using an entity to spawn an object.
Sorry to be so dense in this area, learning a lot though.
Posted: Thu May 15, 2003 7:54 am
by jv_map
Yes you need to define an origin key as well. Guess I forgot that in my example

Posted: Thu May 15, 2003 2:35 pm
by Slyk
Got my lever working that 'fires' the gun sound which is cool. Can't get the 'reload' alias to work though. BUT, biggest issue is still can't get the origin to spawn anything. Maybe I'm wrong, but this is what I did:
script_orgin-- key: $targetname value: shell
then used your (JVs) script above. No spawn of anything...IDEAS??
Posted: Thu May 15, 2003 3:17 pm
by mohaa_rox
u need to define what local.shell is. For example:
local.shell = $shell.origin