OK, I've found out the internal use of suppress_warnings isn't needed if there is a move_modify flag (because warnings about timing errors should be suppressed whenever objects are simply being moved/modified).
So what I've done is replaced the slightly unpredictable PMO_SUPPRESS_WARNINGS and instead there is a new flag PMO_MOVE_MODIFY with the same value.
It is now sent in both of the packets (add/delete) of a move/modify pair and in all cases when an object is conceptually moved or modified, including marshall object changes and when typing a start position index our a route checked index.
It looks simple to add a new flag in these cases, one that is ignored by LFS but should be output to InSim. It's easy for me to locate those cases where a modification or move is taking place (where it sends a delete immediately followed by add).
What exactly is it you would like? Something like PMO_MOVE_MODIFY (value 8) and that same flag would be placed in the delete packet and the add packet when they are being sent as a pair?
Is there any need to distinguish between (1) moving objects and (2) generally changing attributes like colour, size, etc? Or can they be treated all the same? There aren't all that many flags available in that byte so I only want to use up the minimum, but of course it should be as useful as possible.
We are getting very near to the end of this series of test patches now as I must get back to the real stuff I have been working until interrupted by the attacks.
I'll have a look at this, which is almost a bug, and see if I can implement those sub-mode states mentioned in your other post.
In the new graphics system that Eric is using to update the tracks, we have textures that use the alpha channel to control the shine level. So that would seem like a nice thing to consider on skins of the future but definitely not in this version.
You can press CTRL+C if you want to copy the objects.
Outline changed to line drawing which helps with object alignment
Original objects are now shown with grey lines after copy pressed
Drag select now has a minimum size to avoid accidental deselection
FIX : Heading bug after un-copying selection that had been rotated
FIX : CTRL+C un-copy cleared selection if originals were not found
FIX : Chalk objects were sometimes invisible in copied selection
It sets the one nearest to the centre of the rectangle as the last selected object.
Thanks - fixed.
Replying to you and Degats here.
How about if the originals were shown with a grey outline?
This is because LFS thinks you are doing a box select with a zero sized box. Maybe this could be fixed by only doing a box select if the box is a few pixels in size, or at least the size of a selection button.
Alternatively a box select could be ignored if it doesn't include any buttons.
Thanks everyone for the positive comments. Those of you who do follow the forum know why it was worth spending a few of hours getting this little update together. Please you've had some fun with it. That's what LFS is all about, in my opinion. Having fun.
There's so much content that you have never tried. We offer so much more than just Blackwood and 3 cars. But you have never tried it or contributed to our development. I guess you think it's a free game and we can live on nothing.
We're also working on loads of new things and don't need any comments from scroungers who can't be bothered to have a look around to find out what we are working on.
Would it be helpful if the M key was allowed to work after you have pressed CTRL+C?
I haven't tried it yet but it seems possible. As you know, the CTRL+C is reversible because the editor knows which objects were copied. So it seems that in those cases where you have a tricky move as you described, you would then be able to see the originals and the new position at the same time before pressing M.
I am aware there is still a copy of the old 0.5F version of LFS, that was never released but was leaked in 2005, available on the internet and it's not too hard to find.
The only problem: there was no easy way to unlock it.
In fact there are other problems too... the LX8 GTR is way overpowered, underdeveloped and barely driveable! But I know there are people around who want to drive it so why not let them have a go?
So I had a look in some old backups on floppy discs and DVDs, started up an old computer that has a floppy disc drive and managed to get it compiling and made a few changes to make it work with new new master server and recent versions of Windows.
The trouble with allowing both buttons to work is that when a new function is required at a later date, the 'spare' one is no longer available. Or you think it is then discover there are upset people who always used the one that you thought no-one used.
So that's why I'm aiming for least buttons and maximum similarity with other software.
This is often requested and I'm thinking about a really simple version of this as I know it can be tedious to click several buttons.
So I'm thinking of a rectangle select in screen space (X and Y aligned with the monitor) and you would just pull that rectangle and when you let go it would select the buttons visible within the box.
We are currently limited to 30 objects because that's how many can fit in one packet (and I won't be changing that in this version though I do have thoughts for the future about that). So I suppose it could select the 30 objects whose buttons are nearest to the centre of the rectangle when you let go of the mouse button.
Questions remaining in my mind...
I'm sure we need to use a CTRL or SHIFT key in conjunction with a mouse button to pull the rectangle. For some reason CTRL sounds better to me. I'm not certain whether the box select should use the left or right mouse button. What is it like in similar programs? I see in the Windows interface you can use left or right button to draw a box to select icons. No CTRL key makes a fresh selection, CTRL adds / subtracts from selection but that's not available to us as we can't allow 'no key' box select as all such possibilities are used for camera positioning.
It seems to me that "add to selection" would be a dangerous default and is more complicated. So I'm leaning towards the simplest system, with "fresh box selection" as the only function. If your selection isn't quite right after doing the box select, you can select or deselect individual buttons.
I like to keep it simple at this point because there really is a lot of other work to get back to and this editor stuff has been longer than expected. So, assuming CTRL key plus mouse drag is the way to go, we still have the one question: Left or Right mouse button?
The layout editor has changed. It is now more powerful and works more like other editors.
It now uses a CUT / COPY / PASTE system using the standard Windows keys CTRL+X/C/V
This is different from the old editor style which was based on a select / duplicate / move type of logic which had some limitations and caused some problems.
The problem in the old system was that when you selected some objects, they were selected in two ways simultaneously.
1) Visible 'in hand' where your mouse was pointing, ready to be placed in the world
2) The original objects you had selected were still selected
This caused some confusion. For example, if you had some blue tyres and you wanted to place some red ones, you might click the colour and that would change the object in your hand as well as the one on the ground, previously placed or selected.
There are various other examples such as modification of concrete object heights and rotation of objects that could be confusing or annoying because of the old selection method.
The updated editor moves to a different editor logic that should be more familiar because of its similarity with other editors. You can cut, copy and paste.
The real improvement now is that there is a complete separation between the world objects that have been selected, and a selection of objects 'in hand'. Only one of these types of selection is active at any time, so if you make any changes to their colour, dimensions, heading, altitude then it only affects the one active selection.
How to use it:
You create a real world selection, as before, by clicking on object selection buttons. There are two ways to select multiple objects.
1) Hold CTRL and click on object selection buttons
2) Hold CTRL and draw a selection rectangle using the left mouse button
After making your selection you can adjust it in various ways using the on screen buttons or keys.
Maybe you would like to duplicate the selected objects. Press COPY and you will see a live selection in hand. Point to where you would like to place the objects and press PASTE or O to put the new objects there.
Maybe you would like to move your selected objects. There are two ways to do this.
1) Press CUT. The original objects are deleted and you will see them as a live selection in hand located at the mouse cursor. You can now make modifications to the selection as required before pasting or placing it in a new location.
2) Press COPY. You will see a live selection in hand while the original objects remain in the world. Make any changes to the selection then press M to move the original objects to their new position.
You can paste a copied selection in two ways:
1) O key: Place objects and keep a selection in hand to be placed again
2) PASTE: Paste the objects and the new objects will be selected, not leaving a selection in hand
Note: you can switch between the two selection styles by pressing COPY.
1) Real world objects selected -> press COPY -> now you have a selection in hand
2) In hand selection -> press COPY to UN-COPY the selection, i.e. reverts to the world object selection
Note: new PGUP and PGDN keys to adjust height for concrete and other floating objects.
Test patch download: EDIT: This is now in the official version 0.6T