Space Engineers

Space Engineers

30 ratings
KRadar
   
Award
Favorite
Favorited
Unfavorite
Type: Mod
Mod category: Block, Script
File Size
Posted
Updated
6.105 MB
Feb 13 @ 1:22am
Apr 11 @ 1:27pm
12 Change Notes ( view )

Subscribe to download
KRadar

Description
A brand new radar mod developed by myself. Inspired by the "Active Radar" mod.

Large Grid Version Installation:
1, At least one Ship Controller(could be Cockpit, Control Seat or Remote Control Block)
2, One Large Grid KRadar Block
3, At least one LCD Panel
4, Power this grid.
5, Edit Custom Data of KRadar Block. Set the "nameLCD" field.
6, Change the LCD Panel to text mode.
7, (Optional) change the radius of KRadar. (see "Max Target Count" feature below)
8, (Optional) Edit Custom Data of KRadar Block. Set the "isEW" field. (see "Early Warning" feature below)
9, (Optional) Set up a camera, and edit CustomData, set nameCamera field to it. This is used by KRadar ("Lock") Action, detailed in Feature 7 section.

Large Grid Version Function:
Output the size and exactly world position(and velocity if isEW=false) of Enemy grid into LCD Panel. Suppose to be read by a Programmable Block and guide the Missiles or Drones.
Output Format:
1. The 1st line is special, it is a counter that indicate the infomation is updated. if the counter did not change, mean the info is not updated. So you may want to calculate the current position based on the last valid info. For the performance reason, the info will update in every 15 game frames(1/4 second) in FCS mode. (0402 new feature)
2, the 2nd and lines below, each line is a "signal", there are 7 fields: signal size, position x, position y, positionz, velocity x, velocity y, velocity z. if "isEW=true", then it only have the first 4 fields each line.

Large Grid Version Feature:
1. Range, for balance reason, the detectable range is only 0.6 times of the KRadar signal range. So enemy can see the radar before the radar can see them.
2. Early Warning Mode, if set "isEW=true", the Radar can trace more target then "isEW=false", but only update target info every 3 seconds, without velocity info. Otherwise, it will update the target info in every 15 game frames (1/4 second) with velocity info. If you set the radius over 30000m, the radar will forced to be "isEW=true" mode.
3. Max Target Count. In both mode (EW or not), shorter range will lead to more max traceable target count capability. You can check the max target count in Custom Data of the KRadar (maxTrack field). You can't change this field, it is read-only. KRadar will always pick the nearest enemy target. So build multiple radar block in the same place can not extend the capability. But you can deploy them in different places.
4. Planet Horizon(Experimental). The KRadar is affected by horizon. If the Enemy fly lower than the horizon, the radar can not find them. (Based on sea level. no mountain affected).
5. Resolution Limit. KRadar has its own resolution limitation. so if you have multiple enemy in large distance, it may only output one signal.
6. Hidden and Decoy. You may use Asteroid, friendly grid and enemy grid as cover to avoid the detection. You may also use Decoy to mislead the detection(you need to drop the decoy away, no powered decoy works as well, the decoy on your grid will only enlarger the possibility to be detected.
7. Lock a part of a target instead of the mass center. Set up a camera, and edit CustomData "nameCamera" field to match the name of this camera. Open the G menu, drag the KRadar to action bar, select the new "Lock" action. Then aim the camera to a part of an enemy target(like a turret or a thruster or the bridge of the enemy ship). Then use the "Lock" action, it will change the position of KRadar output of this target, use the position of the locked part instead of the mass center. The purpose of this is to guide the missile or turret to point to the particular part.

Small Grid Version Installation:
1, At least one Ship Controller(could be Cockpit, Control Seat or Remote Control Block)
2, One Small Grid KRadar Block
3, One LCD Panel
4, Power
5, Edit Custom Data of KRadar Block. Set the "nameLCD" field.
6, Change the LCD Panel to text mode.
7, (Optional) Set up a camera, and edit CustomData, set nameCamera field to it. This is used by KRadar ("Lock") Action, detailed in Large Grid Version Feature 7 section.
Differences against Large Grid Version:
1. No isEW field, the small grid version is only in FCS mode.
2. The Max detectable range is 5KM. the range above 5km in radius field is meaningless.
3. No MaxTrack field, the small version only provides 1 signal.

Small Grid Version Function:
Output the size and exactly world position of Enemy grid into LCD Panel. Suppose to be read by a Programmable Block and guide the Missiles or Drones.
Differences against Large Grid Version:
1. the output is basically the same with large version, but small one only provides 1 signal.

Small Grid Version Features:
1. there is no coverage, no horizon feature in small grid version.
2. the detectable area is a Cone (the large version is a sphere), you need to point the small KRadar to the enemy to get the signal. (the cos(Dot) limit is > 0.9)
3. the Skeleton ends(the end do not have emition light) is the Forward side, need to be face to enemy. if you get the opposite side towards enemy, you will not get any signal.
4, the performance(sim speed impact) is much better than the large grid version, you may have multiple small grid kradar, each one per fighter or tank.

Change Logs:
v0.9 (2022-02-13) first release.
v0.9.1 (2022-02-14)
- FIXED: crash when entity is null
- FEATURE: grid which has more than 20 terminal blocks will be a cover (no matter it has decoy on it or not)
- FIXED: signalRadius error
- FIXED: use grid.Physics.CenterOfMassWorld instead of grid.GetPosition()
- BALANCE: the grid which has the radar on it will also cover some angle. So better place the KRadar on the edge of the grid. The cover radius is reduced.
v0.9.3 (2022-02-16)
- FEATURE: add velocity x, y, z, in 5th to 7th fields, only available for isEW=false mode.
v0.9.4(2022-02-19)
- BUGFIX: Resolution limit feature use new algorithm to pick the correct signals. (the friendly missiles won't cover the target in large range anymore)
v0.9.5(2022-02-25)
- FEATURE: add Action ("Lock") work with camera block (named by CustomData "nameCamera" field)
v0.9.6(2022-04-02)
- FEATURE: reduce the update frequency to every 15 frames each. by doing this, it will lower the impact to the game perfermance significantly. add a new line in the first of the output. it is a counter that indicate whether the infomation is update or not.
v0.9.7(2022-04-04)
-FEATURE: Small Grid Version.
v0.9.8(2022-04-04)
-BALANCE: update small grid KRadar cone area COS(Dot) limit, from 0.8 to 0.9

Known Issues:
1. Mountains can not be used as cover.
< >
7 Comments
Johnny Apr 19 @ 5:09pm 
Excellent!!
wu.will.china  [author] Mar 21 @ 9:32pm 
could you provide log file like %APPDATA%\SpaceEngineers\SpaceEngineers_20220322_084724278.log ,it may contains the detail of the exception, to help me fix it.
Geronimo Mar 19 @ 12:05am 
crashed as soon as I placed the block
绘岛泠夏_Official Feb 21 @ 9:09am 
Yeah glad to find a radar mod that so easy setting! THX!!!!
wu.will.china  [author] Feb 18 @ 4:58pm 
glad to hear that :)
Scopsins Feb 18 @ 6:18am 
Thanks! This is the radar mod I have been waiting for!
OttoArms Feb 13 @ 7:23am 
Sounds Cool I will try it out Ty for this!