Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- this is a custom aircraft script that was in development before i went to rehab. if you can figure out the remainder, the script is all yours.
- I've never released this or shown progress of this due to lack of success, I've got it working at the bare minimum, and I'm hoping more people contributing to this project will unlock its full potential. DO NOT give this out to others, I will give it out to those who I see fit and am constantly in contact with.
- Let me know how your progress goes and if you get stuck, I'll give tips and snippets to get to the next part.
- -Bunny
- */
- build_custom_aircraft( type )
- {
- model = undefined;
- death_model = undefined;
- death_fx = "explosions/large_vehicle_explosion";
- death_sound = "explo_metal_rand";
- health = 2000;
- min_health = 1000;
- max_health = 5000;
- team = "allies";
- bombs = false;
- turretType = "default_aircraft_turret";
- turretModel = "weapon_machinegun_tiger";
- func = undefined;
- spawn = undefined;
- if( type == "rufe" )
- {
- model = "defaultvehicle";
- death_fx = "explosions/large_vehicle_explosion";
- death_model = "defaultvehicle";
- health = 750;
- min_health = 500;
- max_health = 1000;
- team = "allies";
- func = ::axis_plane_init;
- spawn = SpawnVehicle( "defaultvehicle", "new_plane", "defaultvehicle", self.origin + 30, self getplayerangles() );
- // maps\_vehicle::build_predeathfx( "explosions/large_vehicle_explosion", "tag_origin", undefined, undefined, undefined, undefined, undefined, true );
- }
- maps\_vehicle::build_template( "stuka", model, type );
- maps\_vehicle::build_localinit( func );
- maps\_vehicle::build_deathmodel( model, death_model );
- // build_deathfx( effect, tag, sound, bEffectLooping, delay, bSoundlooping, waitDelay, stayontag, notifyString )
- maps\_vehicle::build_deathfx( death_fx, "tag_engine", death_sound, undefined, undefined, undefined, undefined ); // TODO change to actual explosion fx/sound when we get it
- maps\_vehicle::build_life( health, min_health, max_health );
- maps\_vehicle::build_treadfx();
- maps\_vehicle::build_team( team );
- // Bomb stuff: TODO Rebuild.x with actual explosion fx, sound, and bomb model when we get them
- // quakepower, quaketime, quakeradius, range, min_damage, max_damage
- // maps\_planeweapons::build_bomb_explosions( type, 0.5, 2.0, 1024, 768, 400, 25 );
- // maps\_planeweapons::build_bombs( type, "com_trashbag", "explosions/fx_mortarExp_dirt", "artillery_explosion" );
- maps\_vehicle::build_turret( turretType, "tag_gunLeft", turretModel, true );
- maps\_vehicle::build_turret( turretType, "tag_gunRight", turretModel, true );
- }
- axis_plane_init()
- {
- set_target( self, "air_target", "air_target_offscreen" );
- }
- set_target( ent, shader, offscreen_shader, offset )
- {
- if( !IsDefined( offset ) )
- {
- target_set( ent, ( 0, 0, 0 ) );
- }
- else
- {
- target_set( ent, offset );
- }
- target_setshader( ent, level.hud_shaders[shader] );
- if( IsDefined( offscreen_shader ) )
- {
- target_setoffscreenshader( ent, level.hud_shaders[offscreen_shader] );
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment