Page 1 of 2 12 LastLast
Results 1 to 10 of 15

Thread: Flyable Planes Mod

  1. #1

    Default Flyable Planes Mod

    I have been trying to test out the flyable planes mod by Elgan and can't seem to get it to work. I am able to spawn the plane trigger onto the map, but when I try to start flying I get the message "NIL" in white under the compass and I fall to the ground and die. Any ideas on what setting I may have wrong? If it makes any difference I am trying to run this on Spearhead.

    I also made sure to make a miketorso.st that ends with the additional plane requirements which came in Elgan's readme file

    Thanks,
    <T|F|B>The Shadow
    Last edited by The Shadow; February 22nd, 2019 at 02:26 PM.

  2. #2
    Developer RyBack's Avatar
    Join Date
    Apr 2014
    Location
    In Front of the screen
    Posts
    1,603

    Default

    I've stripped the flyable planes mod and removed all credits before. Just like I did for guided missiles. I'll check if I can find it here or there.

  3. #3

    Default

    Here is the pk3 I've been using to test the planes:
    https://1drv.ms/f/s!AkRez-Qci5HZi0w3malCv0fub5Ym

    and this is where I originally got the mod (Elgan's standalone planes)
    http://www.mohaaaa.co.uk/AAAAMOHAA/c...flyable-planes

  4. #4

    Default

    do you have the "global/strings.scr" file in your server?
    that file is needed to run the mod and it's not included in elgan's pk3

  5. #5
    Developer RyBack's Avatar
    Join Date
    Apr 2014
    Location
    In Front of the screen
    Posts
    1,603

    Default

    here, http://www.mediafire.com/file/50o7z7...yBack.pk3/file
    SS can be found on this thread http://kingmohaa.alafdal.net/t1945-topic , it's in arabic tho
    it's not mine tho, I used to steal and claim a lot of mods in the past.
    CMON WE ALL DID DON'T ACT INNOCENT

  6. #6

    Default

    I didn't know it needed that, I added it from another file I had and it seems the planes fly now. I do have one other question regarding this script.

    I notice that if you have you gun holstered when entering the plane you cant drop bombs with your secondary fire. How can I change the torso or script so that when I enter the plane it forces you to take out a pistol?

    Here is the plane states that go at the end of the mike torso file:
    https://1drv.ms/f/s!AkRez-Qci5HZi06Ecmb9gE0Tr12k

  7. #7

    Default

    Quote Originally Posted by The Shadow View Post
    How can I change the torso or script so that when I enter the plane it forces you to take out a pistol?

    in the PLANE_TORSO state, comment or remove the "safeholster 1" line

    Code:
    state PLANE_TORSO
    {
    
        movetype anim
    
        camera behind
    
        entrycommands
        {
            //deactivateweapon righthand
            //safeholster 1
            modheight "stand" 
            movementstealth "1.0"
            moveposflags "running" "running"
            viewmodelanim idle
        }
        
        action
        {
            unarmed_stand_idle            : default
        }
    
        states
        {
            IN_PLANE             : default
            STAND                : KILLED
            
        }
    }
    and in the server_planes/trigger.scr "fly:" thread, add this green code

    Code:
    fly:
        local.player = parm.other
        
        if(local.player.flying != 1 ||  local.player.OWNS == 1)
        {
            local.team = parm.other.dmteam
    
            local.use_teams = waitexec server_planes/settings.scr::getcmd "use-teams"
    
            if (local.use_teams  == "1" || local.use_teams == 1)
            {    
                if(self.team != local.player.dmteam)
                {
                    local.player iprint "You don't have the training for this aircraft"
                    self.plane light 0 0 1 100
                    waitframe
                    
                    self.plane light 1 0 0 50
                    end
                }
            }
    
            local.player weaponcommand dual targetname ("weapon" + local.player.entnum)
            local.weapon = $("weapon" + local.player.entnum )
            if (!local.weapon) {
                local.player holster
            } else {
                local.weapon targetname ""
            }
            wait 0.5;
            if (!local.player)
                end
    
            local.player.plane_start = self.start_pos    
            local.player scale self.plane_scale 
            local.player exec server_planes/server_fly.scr
    
            local.trigdelay = waitexec server_planes/settings.scr::getcmd "trig-delay"
            local.trigdelay = int local.trigdelay
    
            self nottriggerable
            self.plane hide
    
            wait local.trigdelay
    
            self.plane show
            self triggerable
        }
    end

  8. #8

    Default

    This mod have a bug because on a script dont have set a speed to take off.

  9. #9

    Default

    Zappa I added your code and it seems to have caused me to die instantly again lol
    I'll attach what my trigger.scr looks like since I have found some versions of this mod differ slightly

    Code:
    main local.origin local.team local.scale local.start_pos:
    
    	if(level.planes == NIL)
    	{
    		exec server_planes/setup.scr
    	}
    
    	if(local.origin==NIL)
    	{
    		println "no origin"
    		end
    	}
    
    	if(local.scale==NIL)
    	{
    		local.scale = .2
    	}
    
    	if(local.start_pos==NIL)
    	{
    		local.start_pos = local.origin + ( 0 0 500 )
    	}
    
    	if(local.team == NIL)
    	{
    		println  "no team"
    		local.team = randomint (1) + 1
    		
    		if(local.team == 0)
    		{
    			local.team = "axis"
    		}
    		else
    		{
    			local.team = "allies"
    		}
    	}
    
    	local.plane = spawn script_model "targetname" ("plane_trigger" + local.team)
    	
    	if(local.team =="axis")	
    	{
    		local.plane model "vehicles/fockwulffly.tik"
    	}
    	else
    	{
    		local.plane model "vehicles/p47fly.tik"
    	}
    
    
    	local.plane.origin = local.origin 
    	local.plane.scale = .1
    	local.plane light 1 0 0 50
    	//local.plane notsolid
    	local.plane ghost
    
    	local.plane.shot = 0
    
    	local.plane_trig = spawn trigger_multiple "targetname" ("plane_trigger_fly" + local.team)
    	local.plane_trig.origin = local.origin 
    	local.plane_trig setthread fly
    	local.plane_trig setsize ( -40 -40 -40 ) ( 40 40 40 ) 
    	local.plane_trig.plane_scale = local.scale
    	local.plane_trig.start_pos = local.start_pos
    	local.plane_trig.team = local.team
    	
    	local.plane_trig_shot = spawn trigger_multiple "spawnflags" "128"  "targetname" ("plane_shottrigger" + local.team)
    	local.plane_trig_shot.origin = local.origin 
    	local.plane_trig_shot setthread shot
    	local.plane_trig_shot setsize ( -40 -40 -40 ) ( 40 40 40 ) 
    	local.plane_trig_shot.team = local.team
    	
    	level waittill spawn 
    
    	local.i[0] = 0
    	local.i[1] = 0
    	local.i[2] = 0
    
    	local.v[0] = 3
    	local.v[1] = 4
    	local.v[2] = 5
    
    	while(1)
    	{
    		if(local.minues!=1)
    		{
    			local.v[0] ++ 
    			local.v[1] ++
    			local.v[2] ++
    		}
    
    		if(local.v[2]==10)
    		{
    			local.minues=1
    		}
    
    		if(local.v[2]==3)
    		{
    			local.minues=0
    		}
    
    		if(local.minues==1)
    		{
    			local.v[0] -- 
    			local.v[1] --
    			local.v[2] --
    		}
    
    
    		for(local.p=0;local.p<=10;local.p++)
    		{
    
    		waitframe
    
    			local.i[0] += local.v[0]
    			local.i[1] += local.v[1]
    			local.i[2] += local.v[2]
    
    			if(local.plane.shot==1)
    			{
    				local.i[0] += local.v[0]
    				local.i[1] += local.v[1]
    				local.i[2] += local.v[2]
    				local.i[0] += local.v[0]
    				local.i[1] += local.v[1]
    				local.i[2] += local.v[2]
    				local.plane light 1 0 1 50
    			}
    
    			local.plane.angles = ( local.i[0] local.i[1] local.i[2] )
    		}
    	}
    
    
    
    
    end
    
    end
    
    fly:
    	local.player = parm.other
    	
    	if(local.player.flying!=1 ||  local.player.OWNS == 1)
    	{
    		local.team = parm.other.dmteam
    
    		local.use_teams = waitexec global/settings.scr::getcmd "use-teams"
    
    		if (local.use_teams  == "1")
    		{	
    			if(self.team != local.player.dmteam)
    			{
    				local.player iprint "You don't have the training for this aircraft"
    				local.plane = waitthread find_trig self.team self
    
    				local.plane light 0 0 1 100
    				waitframe
    				
    				local.plane light 1 0 0 50
    				end
    			}
    		}
    
    		local.player weaponcommand dual targetname ("weapon" + local.player.entnum)
            		local.weapon = $("weapon" + local.player.entnum )
          		if (!local.weapon) {
       		         local.player holster
      		} else {
         		local.weapon targetname ""
         		   }
         		   wait 0.5;
           		 if (!local.player)
          		      end
    
    		local.player.plane_start = self.start_pos
    	
    		local.player scale self.plane_scale 
    		local.player exec server_planes/server_fly.scr
    		local.player.flying=1
    
    		local.trigdelay = waitexec global/settings.scr::getcmd "trig-delay"
    		local.trigdelay = int local.trigdelay
    
    		self nottriggerable
    		local.trig = waitthread find_trig self.team self
    		local.trig hide
    
    		wait local.trigdelay
    
    		local.trig show
    		self triggerable
    	}
    end
    
    shot:
    	local.trig = waitthread find_trig self.team self
    	local.trig.shot=1
    	wait 1 
    	local.trig.shot=0
    	local.trig light 1 0 0 50
    	end
    end
    
    find_trig local.team local.trig:
    
    	for(local.i=1;local.i <=  $("plane_trigger" + local.team).size;local.i++)
    	{
    		if(local.trig.origin ==  $("plane_trigger" + local.team)[local.i].origin)
    		{		
    			end  $("plane_trigger" + local.team)[local.i]
    		}
    	}
    
    end
    
    switch__all local.team local.dissable:
    	
    
    	for(local.i=1;local.i <=  $("plane_trigger_fly" + local.team).size;local.i++)
    	{
    		if(local.dissable == 1)
    		{
    			$("plane_trigger_fly" + local.team)[local.i] nottriggerable
    			$("plane_shottrigger" + local.team)[local.i] nottriggerable
    			$("plane_trigger" + local.team)[local.i] hide
    		}
    		else
    		{
    			$("plane_trigger_fly" + local.team)[local.i] triggerable
    			$("plane_shottrigger" + local.team)[local.i] triggerable
    			$("plane_trigger" + local.team)[local.i] show
    		}
    	}
    end
    
    from_fly local.team:
    
    	thread switch__all local.team 1
    
    	while(level.planes[local.team] == level.planes_max[local.team])
    	{
    		wait 1
    	}
    			
    	thread switch__all local.team
    
    end
    Last edited by The Shadow; February 24th, 2019 at 12:35 PM.

  10. #10

    Default

    are you sure you didn't edited anything else?
    it shouldn't be killing you, since it's executed before calling the script to turn the player to a plane

    tested on AA, and it works fine. it shouldn't be conflicting with SH
    is it showing any error in the log?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •