Lua ultimate grapher widget [Update/Unlocked]

Cralant - Custom level - from Windows
PlayEdit7 players liked this.Log in to like this level.

Made the grapher use frequencies instead.
Unlocked the script.
Slightly commented code, I didnt comment every line as this script is more suited for the more experienced lua scriptors.

Side note:
Still having issues with the grapher being at angles, only solution for this could be to use the angle and then convert that into x and y differences in co-ordinates. If anyone knows how to do this the best way let me know.

I 'remade' the grapher for easier debugging and better displays.

The grapher uses lines to draw a smooth plot, while also displaying the current numerical value in the bottom right.
The bottom left shows the current input port and output port that is being displayed for the values passing through the lua script object.
Clicking on the 'ultimate grapher' will cycle through the current inputs.
Inputs can be mapped to different outputs. (This was mostly added as a placeholder for wireless frequencies.)

Currently only supports the wired values going in and out although I shall be adding wireless frequency support in the next update.
I also need to make the grapher display the sprites and lines properly when the grapher has been rotated, if anyone has a simple method please let me know as my current method involves a ton of code.

Also it needs some minor optimization so no derivatives until sometime tomorrow when I am happy with the outcome.

Views: 996 Downloads: 197 Unique objects: 12 Total objects: 32



Discuss this level

Log in to comment on this level.
  • Cralant: @zardOz: yeah I guess your right, although even 2 digits will cause issues if two receivers are next to each other as I'm not sure I could have the text small enough but still readable to be able to fit onto a receiver. Running some tests now and I'll have a level posted soon.
  • zardOz2: Well freq would be nice, but it can be 10 digits... signal would be better and can be 2 digits and still be functional.
  • Cralant: @zardOz: you've given me an amazing idea thanks zardOz. Regarding the signal number, just to clarify do you mean its current value, or the frequency.
  • Golden: @Demon666: Thanks, this really helped me out
  • zardOz2: @Cralant: the signal# is the real benefit here I think you should focus on that. It could be put on all sorts of items... the grapher line is amazing but if you could put signal values on say receivers you wouldnt need to worry about angle since the numbers should always orient the same.
  • Cralant: @zardOz: well now I tend to do all my coding in the PC, using an external editor to colour and format my code. Which is much easier when your scripts start becoming a few hundred lines long. Plus the angle thing may have to wait on this project at least. It currently seems way too complicated and for this project not completely needed. I'm running tests with it though and will hopefully be able to use it for future projects :)

    Also if anyone has any requests I would be happy to help, I need some side projects to combat the boredom of fixing my large ones.
  • Demon666: also I'm glad you made this editable..... i want that numeric grapher!!!
  • Demon666: @golden: try using swiftkey keyboard it is awesome.... i can usually type faster with on hand on it then i can with both hands on a physical keyboard lol
  • Golden: Dam* again
  • Golden: Bu=but
    Stupid small anroid keyboard
  • Golden: Ill add it bu got to wait for my laptop fixed, android cant handle Adobe flash player to change or edit picture and video
  • zardOz2: @Cralant: twice the epic then, It would take me a month to sort out that code... good luck with the angle problem lol
  • Cralant: Oops for some reason it didn't revise the previous version.

LEVEL ID: 3795