Code Monkey home page Code Monkey logo

infernalrobotics's Introduction

All credit to Damned Robotics goes to: Plugin/lots of stuff : r4m0n 3dmodels/'textures' : DYJ

original source location: http://svn.mumech.com/KSP/trunk/MuMechLib/

All new 3dmodels & textures : sirkut, Devo, ZodiusInfuser

infernalrobotics's People

Contributors

erendrake avatar icedown avatar matthewreiter avatar omgnull avatar pellinor0 avatar pgodd avatar sirkut avatar spannermonkey avatar triggerau avatar viniciuslrangel avatar vosechu avatar vrga avatar ziwkerman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

infernalrobotics's Issues

Consider locking the joint when servo is locked

Something like

                    joint.xMotion = ConfigurableJointMotion.Locked;
                    joint.yMotion = ConfigurableJointMotion.Locked;
                    joint.zMotion = ConfigurableJointMotion.Locked;
                    joint.angularXMotion = ConfigurableJointMotion.Locked;
                    joint.angularYMotion = ConfigurableJointMotion.Locked;
                    joint.angularZMotion = ConfigurableJointMotion.Locked;

and then unlock what is needed.

Make IR UI and API aware of all vessels in physics range.

Right now you can operate IR parts on unfocused vessels via keyboard shortcuts (due to the fact that PartModule MuMechToggle is loaded and accepts commands) but neither UI or API are able to issue commands to unfocused vessels.

If we can find the way to parse the loaded vessels in physics range in the same way we do for ActiveVessel we might want to add tabs or other way of selecting vessel to control to our UI and add the ability to issue commands via API to other vessels.

Problems as I see them:

  1. there should be a way to track vessels entering/leaving physics range
  2. The ServoGroups framework will need a complete overhaul alongside parts of the API so it might be a breaking change. One solution is to keep the structure flat, just add the Vessel reference to each ServoGroup and let the API users/IR UI do the filtering.

AppLauncher binding misbehaving

Not using the ToolBar mod, I'm dependent the AppLauncher.

Right now, InfernalRobotics' icon overlaps with the core icons, shows twice or overlaps with something else.

(KSP 1.0.4, InfernalRobotics 0.21.3)

In KSC:
screenshot1

In VAB:
screenshot0

In Flight:
screenshot2

Update in CKAN

Currently InfernalRobotics is not available for 1.0.5 even though there is a release here.

"Floating" extendatrons when using TweakScale

Scaled extendatrons are drawn misplaced (but work okay) if the parent pivotron is not in the default position. This happens on ship load.

It seems that:

  • it doesn't matter if the parent pivotron is scaled or not;
  • it doesn't matter if the parent is surface-attached or stuck to a radial attachment node.

Screenshots

Before reload:

in orbit
extended

After reload:

reloaded game
retracted

Test craft
IROutOfAlign.craft: gist or raw

Top three "hands" are on a radial mount point, lower three are surface-attached. Some are scaled, some are not. Not all possible combinations are present.

Reproducing

  1. Start a new sandbox game. For KCT, RT, TACLS and other mods which present dialogs, select "don't use" presets.
  2. Load the provided craft in VAB.
  3. Launch and achieve stable testing orbit (above 160 km, haven't tested on ground).
  4. Extend/pivot all IR parts to the next preset.
  5. Force ship reload (either quicksave-quickload or go to space center, then tracking station, then back to vessel).
  6. Observe: scaled extendatrons are "floating". Default-size are not.
  7. Retract/pivot all IR parts back to default position.
  8. Force ship reload.
  9. Observe: all extendatrons are back to normal.

Using

  • Arch Linux 64-bit
  • KSP 1.1.2
  • CKAN mods
    • InfernalRobotics 2.0.4
    • TweakScale 2.2.12
    • lots of others - hopefully irrelevant
  • manual mods
    • IR Model Rework - v02 Pre-Release Beta.zip
    • IRSequencer-1.0-RC1.zip

Poke: @pellinor0 (TweakScale)

Related bugs: #79

P.S. I actually wanted to file a different bug, with (scaled?) pivotrons drifting away from their surface attachment point, but can't reproduce that yet.

Gantry moving in wrong direction

The gantry seems to move in the wrong direction in flight vs editor! This does not depend on scaling. So I move it to teh maximum (4) and launch. In flight, it starts at the same position, still reports pos=4, but refuses to move back on its rail. Instead it happily slides into the open air at the other side.

So either the editor or the flight code moves gantries in the wrong direction.

When I look at the code, the flight translation code has a gantryCorrection term. I do not find such a term in the editor code (doTranslation). Did this get lost in some recent refactoring?

displaced translation parts move on rescale

From @pellinor0 on March 21, 2015 21:57

TweakScale considers the origin of the moving mesh as the center of the part, so this stays in place when changing scale. And the mesh that we consider fixed moves accordingly.

I'd guess that this bug was already present in the old IR.

Copied from original issue: erendrake/InfernalRobotics#32

CommunityTechTree 2.1 no longer needs nodes to be unhidden

The following can be removed from the cfg in the legacy parts folder:

@TechTree:AFTER[CommunityTechTree]
{
    @RDNode:HAS[#id[experimentalActuators]]
    {
        @hideEmpty = False
    }
    @RDNode:HAS[#id[advActuators]]
    {
        @hideEmpty = False
    }
    @RDNode:HAS[#id[offworldManufacturing]]
    {
        @hideEmpty = False
    }
}

Proposed feature: In-flight visual aid

Similar to IR Build Aid, have an arc pop-up over servo when user hovers movement buttons in the UI

  1. Make it a global toggle in Settings with a customizable delay (like a tooltip)
  2. Visually similar to IBA, but maybe make a much bigger emphasis on direction of movement, depending on which button is being hovered. This can be achieved by showing only partial arc/line in the corresponding direction from current position or by adding some animation in form of arrows, moving lights or something similar.

Add option to make a Preset the Default Position

And make all buttons that revert to 0 revert to this default position if there is one.
Thus people would be able to set up their default starting positions easily without us changing the default behavior we set for Revert buttons.

I see this solvable by adding a method to Mechanism like GetDefaultPosition and making GUI options to set it.

Floating Parts in KSP 1.0.5 with IR 0.21.4

I like to combine Interstellar receivers with robotic arms for targeting. However, these parts tend to "float" away after a while:

screenshot76

They were perfectly fine at launch and still react to movement, but are totally off axis. This happens randomly at loading the vessel. I typically scale them down to Medium, but displacement is not just off scale. When landing a spaceplan like this, the parts get "ripped" of.

There are memory leaks in GUI as reported on forums

Possible solutions are

  • move all GUI Styles to top level or even static variables and initialize them once only
  • Check that all texture loading is only done once
  • Try to set up sarbian's debug kit and see what is going on

Snapping issue from the forums

I have found I'm having a new issue, never seen this one before but I haven't been working on my robotics for a while, been doing geometry. As such this may have come with the latest update.

It seems like my servos are snapping to limits when they get within a couple of degrees of a limit that has been set. A short video demo is included below.

This only occurs when two conditions are true:

  1. The servo speed is set very low, and
  2. The acceleration value is set very high.

The values at which the problem starts becoming visible are around servo speed about 0.2 or less and acceleration greater than 30.

To me it looks a heck of a lot like a rounding issue with acceleration.

https://youtu.be/55-jt7ic1qY

Rotatron's create mysterious internal forces with certain parts when NOT in motion

Summary:
Rotatron's create mysterious internal forces with other parts in the same craft when the Rotatron is stationary. This is causing my crafts to twist and turn in very strangely eventually causing parts to fly off. So far the parts I know of are all Landing Struts.

Steps to Reproduce:
Build a super simple lander attached to something.
http://steamcommunity.com/sharedfiles/filedetails/?id=694327741

  1. Start with some control unit
  2. Add Mk 1 Lander Can to bottom
  3. Add 4x LT-2 landing struts to Lander Can using symmetry mode
  4. Add Docking Port Jr to bottom of Lander Can
  5. Add second Docking Port to docking port
  6. Add Adapter to larger fuel tanks to docking port
  7. Add Fuel tank to Adapter
  8. Add Fuel tank to Fuel Tank
  9. Add Launch Stability enhancer to fuel tank
  10. Add IR Rotatron to either fuel tank
  11. Launch and wait about 10 seconds.

Results: Lander Can will twist and push it's way off the docking port. The Landing struts may pop off as well.
http://steamcommunity.com/sharedfiles/filedetails/?id=694330878
http://steamcommunity.com/sharedfiles/filedetails/?id=694330785

Test 2: remove the Rotatron and Launch.

Results: The vehicle sits still as expected.

Test 3: add the Rotatron back. Remove the Landing Struts and Launch

Results: The vehicle sits still as expected.

In this test only the LT-2 Landing Struts cause an issue. In a larger more complex lander all struts cause the issue and removing the Rotatrons makes the issue go away for all lander struts.

I've had this issue when using docking ports as well as strong connections using Stack Separators with struts. Docking ports make it easier to see the issue.

The issue seems like the Rotatrons are pushing the other parts away from it. However, distance doesn't seem to play a direct part. Some parts effect it more than others.

The effected parts are IR Rotatron and IR Rotatron Mk2. The Mark 2 part has the same behaviour only much less severe.

Editor UI Suggestion: see pic

image

see the circled control:
if position == preset position and you press the X you will delete the preset,
if position != preset position the X turns into O and acts as AddPreset button
< and > buttons switch between different presets (moving part to the preset in editor)

RW key points

RW will be ran on a referee's PC, streamed and shoutcasted for the entertainment of masses tuning to the stream. Main discussion points saved below

  1. publish the config: settings it will run under and ban the use of set config:whatever to something.
  2. we should also introduce the maximum height robots may fly before they are considered out of the fight zone, it is not hard to write a script that will check which vessels are outside of a certain area and attach this script to a referee bot
  3. maybe introduce a fire pit inside the arena and/or a moat around it to help sped up the battle
  4. due to the size of the arena some dimension limits are needed for sure as well as some mass limits
  5. Provide an exact list of mods the arena will be run under so people can test with the same setup, else it's not fair.
  6. I think there should be 3 win conditions: a) opponent is pushed/tricked out of the fight zone b) opponent is destroyed - meaning opponent's CPU stopped working (even if it ran out of power) c) opponents script fails (maybe due to missing parts) and we can allow a referee to call a rematch if a fight stalls for too long

Some additional ideas:

  1. have a pre-show where we mock and explode submissions that fail to comply to the rules
  2. have a pre-show with some obstacle race or make the race a part of the competition for the violence-haters

Placing IR parts with symmentry causes them to not function

Apologies if this is a known issue, I could not find references to this. Using the latest release (2.0.0), did not have a MagicSmokeIndustries directory before installing. Installed both legacy parts and core, tried installing core first and then legacy parts after that, later on tried to reverse the order as there were some files that were present in both packages.

Versions

Other mods

  • MechJeb2
  • Kerbal Engineer Redux

Steps to reproduce

  1. Create vessel in SPH
  2. Activate symmetry (defaulting to mirror)
  3. Place IR Rotatron somewhere on the vessel (since symmetry is activated, two of them will be placed, as expected)
  4. Launch
  5. Try to rotate the parts, the UI (both IR panel and the right click context menu on the parts) indicate that they are rotating but visually nothing is happening

Log

In KSP.log, there is the following error message

[LOG 20:59:27.002] Vessel assembly complete!
[LOG 20:59:27.002] all systems started
[LOG 20:59:27.030] IR: Loading sounds : MagicSmokeIndustries/Sounds/infernalRoboticMotor
[LOG 20:59:27.030] IR: Sound successfully loaded.
[ERR 20:59:27.031] Cannot find module 'ModuleIRServo' (291586916)

[EXC 20:59:27.032] NullReferenceException: Object reference not set to an instance of an object
    InfernalRobotics.Module.ModuleIRServo.<IsSymmMaster>b__131_0 (.Part cp)
    System.Linq.Enumerable.All[Part] (IEnumerable`1 source, System.Func`2 predicate)
    InfernalRobotics.Module.ModuleIRServo.IsSymmMaster ()
    InfernalRobotics.Module.ModuleIRServo.AttachToParent ()
    InfernalRobotics.Module.ModuleIRServo.BuildAttachments ()
    InfernalRobotics.Module.ModuleIRServo.OnStart (StartState state)
    Part.ModulesOnStart ()
    Part+<Start>c__Iterator25.MoveNext ()
[LOG 20:59:27.035] IR: Loading sounds : MagicSmokeIndustries/Sounds/infernalRoboticMotor
[LOG 20:59:27.035] IR: Sound successfully loaded.
[ERR 20:59:27.036] Cannot find module 'ModuleIRServo' (291586916)

[EXC 20:59:27.037] NullReferenceException: Object reference not set to an instance of an object
    InfernalRobotics.Module.ModuleIRServo.<IsSymmMaster>b__131_0 (.Part cp)
    System.Linq.Enumerable.All[Part] (IEnumerable`1 source, System.Func`2 predicate)
    InfernalRobotics.Module.ModuleIRServo.IsSymmMaster ()
    InfernalRobotics.Module.ModuleIRServo.AttachToParent ()
    InfernalRobotics.Module.ModuleIRServo.BuildAttachments ()
    InfernalRobotics.Module.ModuleIRServo.OnStart (StartState state)
    Part.ModulesOnStart ()
    Part+<Start>c__Iterator25.MoveNext ()

IR Surface Sampler Integration

How should the code for the surface sampler be handled?

It can be directly integrated into IR if you want, or just added here as a separate repo in the MagicSmokeIndustries group. Either way, it would make more sense to have it all together.

V2.0 Overhaul planned changes

Tier I - Essential Changes

  • Make ServoGroups persistent and save/load them with the vessel. This will allow to add more control over groups - save group order, assign unique IDs for use in AGX, assign separate keybindings for servos in a group.
  • Implement Servo Motor with configurable torque, max speed, max acceleration and EC consumption (depending on torque most likely).
  • Move non-motor related features of a Servo to Servo Mechanism: all current rotational/translational limits, current position, add/allow springiness, damping (allows pneumatic/hydraulic parts).
  • Any Servo could be made uncontrolled by removing Servo Motor from it. Maybe even add the UI button to do just that. This should reduce the number of necessary parts.
  • Rename MuMechToggle to something more meaningful. Try to have at least some backwards compatibility or a way to convert old crafts.
  • UI overhaul to Unity 5

Tier II - High Priority changes

  • Try to overhaul vessel parsing for servos, may help with docking problems.
  • Global/group controls over servo parameters (I'm not sure how to do it yet).
  • IR Build Aid: visualize movement of selected/all servos with arrows or even with semi transparent part outlines. Consider animation to preview speed.
    • Make an option to use Interpolator and speed/acceleration settings in Editor (Alt-Click or somehting like that).

Tier III - Good to have things

  • Allow servo dragging in Editor (grab the end of the servo and move it with mouse).
  • Consider adding sensor parts (distance sensor, pressure sensor, light sensor).
  • Explore ConfigurableJoint.swapBodies parameter, may help reduce the number of parts.

Uncontrolled parts lock up when wheels are attached

This is a mouthful to say so here goes.

  1. Attaching any wheel to an uncontrolled IR part, directly or via other parts, locks that part and orientation to whatever was configured in the SPH/VAB.
  2. Nested uncontrolled parts, connected directly or via other parts, continue to work but do not affect the 'locked' parts orientation.
  3. Uncontrolled parts that rotate in a different plane/orientation do not seem to be affected.

Example CRAFT file (hopefully) attached.
IR Test 01.zip

Edit: Using stock KSP 1.1.2.1260 x64 & IR 2.0.4

Remove unnecessary log spam.

  1. We don't need to run LoadConfigXML for each ModuleIRServo in Awake - move it to ServoController (only field we need is UseEC)
  2. We dont need log messages from UpdateTweaks anymore
  3. other minor messages

Proposed feature (separated from v2.0 list): toggleable motors.

Allow servo motors to be turned off, thus turning them to uncontrollable servos temporarily.
It should be possible with reasonable amount changes to the code:

  1. on motor disable just relax the joint the same way we do it for uncontrollable parts
  2. on motor enable, destroy the old joint and build a new one (?) or alternatively set the old joint's targetRotatiom/position to a current rotation/position as per GetRealRotation()/GetRealTranslation()
  3. Consider adding back maxTorque parameters to allow external forces override motor force (better separate it to another issue)

0.21.2 Change Log

v 0.21.2 Changes

  • Made our AppLauncher icon follow the same behaviour as when blizzy's toolbar installed and only show when there are robotic parts on the craft in flight. Editor button is still always visible.
  • Fixed .version file
  • Updated KSPAPIExtensions.dll dependency
  • Converted Legacy parts textures to DDS
  • Rearranged Legacy parts position in tech tree.
  • Added support for CTT for Legacy parts.

Part idea from @pgodd

A proximity sensor part, akin to SmartParts one, but better integrated to IR, optionally with the possibility to measure distance/pressure (see dunbaratu's lazerdist)

Default units

From @pellinor0 on March 18, 2015 20:22

I was thinking about those default units. As I remember zodius put all sorts of odd speed numbers in the part configs so that the parts would take the same time to move their whole range. This is redundant information, and we should not require it.

So, at least for translation, this sounds like it would be nice to display the range as 0-100% per default. Then we can set the default speed in (% of range)/s, and it would be the same for all parts. For the future, we could set the value from zodius' parts as default and you would only need a line in the part.cfg if you want something different.

What do you think, does this make sense? In this case, would 'range' be the min/max from the part config or the tweaked range from the editor?

Copied from original issue: erendrake/InfernalRobotics#17

ChangeLog from 0.19.3 to 0.20

Changes in v0.20 from 0.19.3

  • BREAKING: Field "Coarse Speed" has been renamed in the UI to just "Speed". Will affect all KOS scripts that read or change that field. Field name in part.cfg has not changed, so all existing crafts should load successfully.
  • BREAKING: Some Events and Actions has been renamed in the UI, check your IR related kOS scripts.
  • BREAKING: Part config fields "maxRange" and "minRange" are now obsolete. There are no reworked or legacy parts that use those two fields.
  • NEW: All controllable servos now have Acceleration parameter. As the name suggest it is the rate at which servos speed up or slow down. Default value for legacy parts is 4x.
    • Acceleration and Speed are only applied in-flight, in editor parts move at their default speed.
    • Tip: Lower acceleration allows for smoother movements leading to less wobble, but at the cost of lower speed.
  • NEW: You can create preset positions for all controllable servos and switch between them in flight and in editor.
    • Presets are automatically sorted from lowest to highest
    • In editor you can switch between presets either on main Servo Configurator GUI or via Preset Editor
    • In flight you can move servo from current position to next or previous preset position via main Servo Controller GUI or using ActionGroups
    • You can move servo to arbitrary preset position via Preset Editor window both in flight and in editor.
    • For examples on using presets refer to the video overview linked below.
  • NEW: Integration into other mods through API
  • GUI Redesign
    • Redesigned Editor UI to fit most of the relevant fields and actions in one window.
    • You can now move individual servos and change their main parameters from single IR window without the need to right-click every servo.
    • Redesigned in-flight controls to accommodate all new changes and for better readability.
    • All IR in-flight windows now obey F2 command (hide/show UI) and should not get in the way of your awesome screenshots.
    • Custom category in editor listing all robotic parts.
    • Editor and Flight window width is scaled dynamically.
    • Editor window now has an option to revert servo to default position (usually 0).
    • You can move servos to precise positions in editor by creating presets and snapping servos to them.
    • Position and ranges for inverted axis parts are now shown in different style.
    • All buttons now have basic tooltips.
    • Whole set of new icons for a polished looks.
  • TweakScale configs on Legacy parts have been fixed to work with the latest version of TweakScale.
  • Servo sound's pitch now scales with servo's movement speed

Check MoveCenter behaviour

From @ZiwKerman on March 30, 2015 9:48

Some users report that rotational parts return to As-Launched position and translational parts return to 0 position.

Copied from original issue: erendrake/InfernalRobotics#67

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.