@FOXLOVER It has some logic there.
1. If it is too far, go to the target location.
2. If it is not well aligned, go to a rally point.
3. Go to final approach from rally point.
4. Adjust you relative position with your Roll and altitude with Pitch.
5. And when close enough, just apply air brakes.
Then I found airport position/heading, and also for carrier.
@Chancey21 So, get yourself a series of variables
As example, k1 is the air density at 1000m altitude
then you set <voffset={k1}>.</voffset> using your label
You get a point
Then you just make a serie of points that way
@edensk My goal is to find out the number/size of inlet I need at high Altitude, so IAS doesn’t help much, read the motivation section to know more about it
You can either use smooth or PID.
Both makes your plane less responsive though.
Example would be
smooth(expression,number)
PID(Pitch,-VerticalG+1,1,0,0.5)
but PID requires some tuning
In your case, don’t do anything with the 2nd number corresponding to I, just play around with the 3rd value corresponding to D to make it easier
So, I tried the codes.
The 1st thing to say is that those signs are weird.
Then it’s /9
Also there is -1 so your planes doesn’t go crazy at level flight.
The price is it could go 10G at the bottom of a loop, if you don’t want this, set it to /8
So it ends up to be
clamp(Pitch+(VerticalG-1)/9,-1,1)
Also, I have a build with advanced targeting which is
All About your Target
You can check it out as it includes target maximal acceleration/g, maximal altitude/velocity, current velocity/altitude, current heading/pitch angle.
I don’t understand why your codes are like that but anyways.
So the relative Alt/Lat/Longitude to you is
Lat: cos(TargetHeading)cos(TargetElevation)TargetDistance
Long: same as Lat except it is sin(TargetHeading) instead of cos
Alt: sin(TargetElevation)*TargetDistance
However, you are moving aren’t you?
So we need to add your own displacement there
Target’s absolute position is
well, basically the relative ones add to Lat/Long/Altitude
Then you square root the sum of their square.
You final equation will be
Wait, you must set your prop pitch to manual with neutral setting with #%
Where # is what you have as your fixed value, so you can modifie in course of your flight.
Coz prop pitch can’t be modified if it is fixed
So there is no input such as Speed
A fews are available:
IAS, TAS, GS all in units of m/s.
I believe you want IAS for your input
40mph is kinda 40*1.6≈64km/h, therefore 64/3.6≈18m/s
@WereOutOfNames Just take all codes and the Gyro away, then use SC as input for Engine and AirBrakes. But note that game crashes when you activate everything at once. And don’t forget to add a probe.
Latitude+cos(TargetHeading)TargetDistancecos(TargetElevation)
Longitude+sin(TargetHeading)TargetDistancecos(TargetElevation)
you have target real position (in contrast to relative position)
by applying rate to it, you find target speed
then you use tan function to find target’s direction of movement
and you just make sure this direction must be close to your heading
It is done since the game omits some frames to save energy and time. The ignition delay moves the trail generating frame to an omitted frame so the trail is omitted.
For instant, the best solution I found is ignitionDelay = 0.02, it works in high/medium physics but not low at slow motion
The plane’s stability is provided by the wing aerodynamics. It is determined by your wing load, position of CoL in relation to CoM, wing profile and especially IAS.
As your speed is low, your plane’s stability decreases with IAS. It is generally ok since the force you can employ by control surface is also reduced, which is not the case with TVC.
As your plane is less stable, but the TVC provides the same force, your plane can’t stabilize itself and starts to do this.
In order to stop this, you must introduce a force to counterbalance it. In your case it must be TVC, since your aerodynamism is failed at low speed and you don’t have other forces under control.
Use
Pitch*90(+-)PitchRate
as your rotator input, that would make it stop pitching automatically
if things are going weird you can apply invert on the rotator
@ThatOneThiccPlaneStealer just sloved the problem on my end. You must download a files app that allows you to modify Android/data, then you drag and move the mod document into it and put it in the right spot
For the stabilizing part, put buoyant parts along the waterline and not inside your ship. In this way, if it bends, it loses half of buoyancy and fall back on the other side. If it doesn’t work, you are having too much buoyancy.
Hi, you should install your cockpit on a piston, that allows you to move your cockpit kms away from your plane, creating a pseudo aews.
Note that prevent breaking must be true, mass must be 0, collision must be disabled and you shouldn’t do any manoeuver nor rotate the rotators when your cockpit is away to avoid glitches.
https://www.simpleplanes.com/a/Yr3085/Concept-Cruise-Missile
+1That sounds quite similar, except this one targets surface units
@ZWLenning I just learned yesterday there is interactionType Once. That should be more decent in most cases
Project name:
Warhead
Motivation:
MTRV missile against immobile units
ASBM
Long Range Guided Bombs
Drone autopilot
@FOXLOVER It has some logic there.
1. If it is too far, go to the target location.
2. If it is not well aligned, go to a rally point.
3. Go to final approach from rally point.
4. Adjust you relative position with your Roll and altitude with Pitch.
5. And when close enough, just apply air brakes.
Then I found airport position/heading, and also for carrier.
@edensk I know, but I must theorize it
@F1849 Idk but maximal, coz the refuel tanker is so slow...
@Chancey21 So, get yourself a series of variables
As example, k1 is the air density at 1000m altitude
then you set <voffset={k1}>.</voffset> using your label
You get a point
Then you just make a serie of points that way
@edensk My goal is to find out the number/size of inlet I need at high Altitude, so IAS doesn’t help much, read the motivation section to know more about it
You can either use smooth or PID.
Both makes your plane less responsive though.
Example would be
smooth(expression,number)
PID(Pitch,-VerticalG+1,1,0,0.5)
but PID requires some tuning
In your case, don’t do anything with the 2nd number corresponding to I, just play around with the 3rd value corresponding to D to make it easier
So, I tried the codes.
+1The 1st thing to say is that those signs are weird.
Then it’s /9
Also there is -1 so your planes doesn’t go crazy at level flight.
The price is it could go 10G at the bottom of a loop, if you don’t want this, set it to /8
So it ends up to be
clamp(Pitch+(VerticalG-1)/9,-1,1)
Pitch-VerticalG/18
should work for 9G as at 9G Full Pitch, the output is 0, so it will not go beyond that point
Change 18 for 15 if you want 7.5G
But why would you make your life that complicated? Keep it simple
{Activate1?sqrt(pow(Latitude+TargetDistancecos(TargetElevation)cos(TargetHeading),2)+pow(Longitude+TargetDistancecos(TargetElevation)sin(TargetHeading),2)+pow(Altitude+TargetDistance*sin(TargetElevation),2))
:Altitude}
I guess you can take several pictures and combine them using photoshop or stuff?
萌新加油!↖(^ω^)↗
+1@linxiaofeng2339
https://www.simpleplanes.com/a/U2IwNc/MultiTargeting-v-2
这个链接,代码有些多。。。你估计看不懂。
问题是回到第一个目标时判定可能失效,而且两个目标过于接近时可能失效
加油啊。
我最近也在做雷达,但是代码出了不少bug。操作也很麻烦。
Next steps include
+11.Numerisation of radar system through Label
2.Manual/semi automatical IFF
3.Target altitude and Velocity display? Maybe?
Activating/Deactivating multiple functions from variable system at once
Can you go check the post, since a long expression will almost always contain spelling problem. Variable system is awesome for this reason.
add a line in overload
interactionType toggle
set it to
+1{132.2+round(VTOL*50)/5;000.0}
clamp(PID(target speed in m/s,GS,1,0,2),-1,1)
set this as the input of your engine and air brakes
or you can lerp as default refuel tanker does
Also, I have a build with advanced targeting which is
All About your Target
You can check it out as it includes target maximal acceleration/g, maximal altitude/velocity, current velocity/altitude, current heading/pitch angle.
I don’t understand why your codes are like that but anyways.
So the relative Alt/Lat/Longitude to you is
Lat: cos(TargetHeading)cos(TargetElevation)TargetDistance
Long: same as Lat except it is sin(TargetHeading) instead of cos
Alt: sin(TargetElevation)*TargetDistance
However, you are moving aren’t you?
So we need to add your own displacement there
Target’s absolute position is
well, basically the relative ones add to Lat/Long/Altitude
Then you square root the sum of their square.
You final equation will be
TargetVelocity=
pow(
pow(rate(Latitude+cos(TargetHeading)cos(TargetElevation)TargetDistance),2)
+pow(rate(Longitude+sin(TargetHeading)cos(TargetElevation)TargetDistance),2)
+pow(rate(Altitude+sin(TargetElevation)*TargetDistance),2)
,1/2)
Wait, you must set your prop pitch to manual with neutral setting with #%
Where # is what you have as your fixed value, so you can modifie in course of your flight.
Coz prop pitch can’t be modified if it is fixed
So there is no input such as Speed
+1A fews are available:
IAS, TAS, GS all in units of m/s.
I believe you want IAS for your input
40mph is kinda 40*1.6≈64km/h, therefore 64/3.6≈18m/s
With which control do you control propeller pitch? Or is it fixed? If fixed, just -Activate#
+1Input*(-Activate#)
+1Let your input be your current input and # be the ag number you want
@WereOutOfNames Just take all codes and the Gyro away, then use SC as input for Engine and AirBrakes. But note that game crashes when you activate everything at once. And don’t forget to add a probe.
+1can you also make a block that allow creating variable with funkytree?
Latitude+cos(TargetHeading)TargetDistancecos(TargetElevation)
Longitude+sin(TargetHeading)TargetDistancecos(TargetElevation)
you have target real position (in contrast to relative position)
by applying rate to it, you find target speed
+2then you use tan function to find target’s direction of movement
and you just make sure this direction must be close to your heading
@R3N13L No worry, only a gyro participate in drag calculation, then I multiplied it so the carrier is more maneuvrable
+2@Guangle
自制车轮的话,带个无碰撞空心圆筒做内外圆。但是中间的装饰要去找外观大神,我外观是渣。最后直接改链接到转轴上,并且位置改好就完事了。
系统车轮。。。直接做个无碰撞装饰让他转速略高于真车轮就完了。
@Guangle 用
sum(你的控制键)*速度倍数
@Jachal68 Since your wing turned 90 degree to become your sail, maybe you should try AoA instead of AoS
+1It is done since the game omits some frames to save energy and time. The ignition delay moves the trail generating frame to an omitted frame so the trail is omitted.
For instant, the best solution I found is ignitionDelay = 0.02, it works in high/medium physics but not low at slow motion
Maybe your engine output is simply bigger than your mass, and propulsed your aircraft straight up
The full explanation is here.
The plane’s stability is provided by the wing aerodynamics. It is determined by your wing load, position of CoL in relation to CoM, wing profile and especially IAS.
As your speed is low, your plane’s stability decreases with IAS. It is generally ok since the force you can employ by control surface is also reduced, which is not the case with TVC.
As your plane is less stable, but the TVC provides the same force, your plane can’t stabilize itself and starts to do this.
In order to stop this, you must introduce a force to counterbalance it. In your case it must be TVC, since your aerodynamism is failed at low speed and you don’t have other forces under control.
Use
Pitch*90(+-)PitchRate
as your rotator input, that would make it stop pitching automatically
if things are going weird you can apply invert on the rotator
@Formula350 Use input=
1-LandingGear for you beacon, the code is simple, when enabled it’s 1, disabled is -1
The only reasonI asked this simple question is because my code is getting 100 lines long
+1How can I make a list of element such that when the result is part of the list, the output is x and otherwise output is y?
+2@AtlasSP clamp01(tan(sum(desiredInput))) may work
In the 1st period, tanx<0 thus 0
In the 2nd, tanx>1 thus 1 and rest a bit
2.write code (20+GS/x)/y as your input
But to be honest, initial position should be done with fine turner.
@ThatOneThiccPlaneStealer just sloved the problem on my end. You must download a files app that allows you to modify Android/data, then you drag and move the mod document into it and put it in the right spot
For the stabilizing part, put buoyant parts along the waterline and not inside your ship. In this way, if it bends, it loses half of buoyancy and fall back on the other side. If it doesn’t work, you are having too much buoyancy.
Just diminish the scale of your prop if your chord makes it awful, I made some submarine with the chords, so you should be able to make a ship
Hi, you should install your cockpit on a piston, that allows you to move your cockpit kms away from your plane, creating a pseudo aews.
Note that prevent breaking must be true, mass must be 0, collision must be disabled and you shouldn’t do any manoeuver nor rotate the rotators when your cockpit is away to avoid glitches.
You know Android is not longer supporting mods with 64bits update?