Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Onscreen Hints for more tools #868

Merged
merged 11 commits into from
May 7, 2020
Merged

Conversation

kvakvs
Copy link
Collaborator

@kvakvs kvakvs commented Apr 27, 2020

Fixes: #720

  • Should be fixing the ominous null UIView problem when UI components are deactivated by SetActive(false) and beheaded by DetachChildren in their parent
  • Junction Restrictions tool
    • Strings: JunctionRestrictions.csv: "OnscreenHint.Mode:Select", "OnscreenHint.Reset:Reset to default" (or reuse from LaneRouting.csv "LaneConnector.Label:Reset to default")
  • Manual Traffic Lights tool
    • Strings: TrafficLights.csv: "ManualTL.Mode:Select", "ManualTL.Mode:Edit"
  • Priority Signs tool
    • Strings: PrioritySigns.csv: "OnscreenHint.Mode:Select", "OnscreenHint.Mode:Edit"
    • Strings: "Prio.Click:Quick setup prio road/roundabout", "Prio.Click:Quick setup high prio road/roundabout","Prio.Click:Quick setup prio junction"
    • Remove "Tooltip.Keybinds:Add priority signs"
  • Toggle Traffic Lights tool
    • Strings: TrafficLights.csv: "ToggleTL.Mode:Click to toggle"
  • Timed Traffic Lights tool
  • Speed Limits tool
  • Parking Restrictions tool
    • Strings: ParkingRestrictions.csv "OnscreenHint.Mode:Click to toggle"
  • Vehicle Restrictions tool
    • Strings: VehicleRestrictions.csv "OnscreenHint.Mode:Select segment", "OnscreenHint.Mode:Toggle restrictions"

bild

Review TODO list

  • TimedTL: Remove Ctrl+Click
  • Prio: move Ctrl+Click above Shift+... items
  • Prio: Click priority signs to toggle is confusing when editing a junction with no signs: Might be better as Click circles to change - [ ] signs ?
  • Prio: Remove right click to leave //comment
  • Prio: Click junction to edit will delete signs
  • JR: Default text when junction selected? Click icons to toggle
  • VR: Default Choose a segment to edit hint still visible even after choosing a segment: I know technically it's still valid, as I can choose another segment just by clicking it, but it just seems a little confusing from user perspective as it feels like I've done what it says (choose segment) and it's still asking me to choose segment. Maybe when segment is chosen it could change to Click icons to toggle vehicle bans ?
  • VR: Delete | Bksp Revert to default
  • Parking: Maybe simplify to Click icons to toggle parking ban?
  • Parking: Shift + Click Apply change to whole road
  • Parking: Remove [Shift]: Apply changes
  • LaneConn: Right Click Leave selected node is showing while I have a lane selected: Better as Right Click Leave selected lane ?

@originalfoo originalfoo added JUNCTION RESTRICTIONS Feature: Junction restrictions PARKING Feature: Parking AI / restrictions / etc PRIORITY SIGNS Feature: Stop / Yield / Priority signs SPEED LIMITS Feature: Speed limits Toolbar The main TMPE toolbar TRAFFIC LIGHTS Feature: Traffic lights - toggle, timed, etc UI User interface updates Usability Make mod easier to use VEHICLE RESTRICTIONS Feature: Vehicle restrictions labels Apr 27, 2020
@originalfoo
Copy link
Member

Assuming some default text is wanted for each tool:

Junction restrictions:

Choose a junction to edit

Priority signs:

The interaction model for priority signs is grim; would be good to make it work more like Junction Restrictions if possible.

Choose a junction to edit

Toggle traffic lights:

Click junctions to toggle traffic lights

Timed traffic lights:

Maybe leave this one until we revamp the TTL UI?

Choose a junction to edit

Speed limits:

Maybe leave this one until we revamp the speed limits UI?

Parking restrictions:

Click parking icons to toggle parking

Vehicle restrictions

Choose a segment to edit

@originalfoo originalfoo added this to the 11.5.0 milestone Apr 28, 2020
@kvakvs
Copy link
Collaborator Author

kvakvs commented Apr 28, 2020

Ready for testing
Discovered bug: Speed limits window lost its background (still works)

@originalfoo
Copy link
Member

I think speed limits should be next target for UI overhaul (separate PR obviously).

@originalfoo
Copy link
Member

originalfoo commented Apr 29, 2020

Priority signs

Can the Ctrl+Click be moved above the Shift+... items?

image

Click priority signs to toggle is confusing when editing a junction with no signs:

image

Might be better as Click circles to change signs ?

Also, right-clicking does not exit the selected node - issue with fsm?

Another issue (this is just due to bad interaction model of priority signs) - if I "click this junction to edit" I'll acutally delete the priority signs that are already there.

image

How much work would it be to make priority signs interaction model work more like junction restrictions?

@kvakvs
Copy link
Collaborator Author

kvakvs commented Apr 29, 2020

I can modify the strings.
There is no finite state machine added to those other tools, that'd require full rewrite of the tool (namely i done that for Lane Arrows and currently doing that for Speed Limits).
The default old behaviour was that right click cannot exit. I can comment that text out.

@originalfoo
Copy link
Member

Junction restrictions

Default text when junction selected? Click icons to toggle

image

@originalfoo
Copy link
Member

Vehicle restricitons

Default Choose a segment to edit hint still visible even after choosing a segment:

image

I know technically it's still valid, as I can choose another segment just by clicking it, but it just seems a little confusing from user perspective as it feels like I've done what it says (choose segment) and it's still asking me to choose segment.

Maybe when segment is chosen it could change to Click icons to toggle vehicle bans ?

@originalfoo
Copy link
Member

Parking restrictions

Maybe simplify to Click icons to toggle parking ban?

image

@originalfoo
Copy link
Member

Lane connectors

Right Click Leave selected node is showing while I have a lane selected:

image

Better as Right Click Leave selected lane ?

@originalfoo
Copy link
Member

Some missing shortcuts

For Parking Restrictions and Vehicle Restrictions:

  • Shift + Click Apply change to whole road

For Vehicle Restrictions only:

  • Delete | Backspace Revert to default

@originalfoo
Copy link
Member

originalfoo commented Apr 29, 2020

Tooltips

There's still old shortcut text in some tool buttons:

image

image

EDIT: Just realised the TTL hints is for later PR, so it's tool button tooltip can remain for now.

Copy link
Member

@originalfoo originalfoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See comments above

@kvakvs
Copy link
Collaborator Author

kvakvs commented Apr 29, 2020

Created checklist (first post) from your comments.

@originalfoo originalfoo linked an issue May 2, 2020 that may be closed by this pull request
@kvakvs
Copy link
Collaborator Author

kvakvs commented May 2, 2020

Found the same: missing background in Vehicle Restrictions in IMGUI window
Same as the missing background in Speed limits IMGUI
Not sure what could it be

@aubergine10 otherwise the notes above were addressed
i will need to give it a round of logging & debugging & testing to figure out missing backgrounds.

@originalfoo
Copy link
Member

Right Click ....?

image

Missing locale string:

image

Speed limits bg is working for me:

image

As is vehicle restrictions:

image

Maybe something to do with opacity setting?

@kianzarrin
Copy link
Collaborator

@kvakvs can you please refresh tooltip for despawning toggle. it does not get updated when I click the button. I have to move the mouse out and back in again.
Screenshot (966)

@kvakvs
Copy link
Collaborator Author

kvakvs commented May 2, 2020

ready for another round of review
also: inverted button highlight on despawning, active is easy mode, off is hard mode.

@originalfoo
Copy link
Member

I don't have a lane selected yet, but the Right Click hint is saying it will leave selected lane...

image

Other than that, looks good. Does it include the fix for tooltips updating before UI is ready (that were causing you crashes as discussed in Discord chat)?

@kvakvs
Copy link
Collaborator Author

kvakvs commented May 5, 2020

The fix for crash was done immediately and merged with the previous ticket (for priority signs positioning), it was a severe bug.

@originalfoo
Copy link
Member

originalfoo commented May 7, 2020

There is still the issue with Right Click hint mentioned in #868 (comment) :

image

I do not have a lane selected; I only have the node selected. In this state it should be saying:

Right Click Leave selected node

Copy link
Member

@originalfoo originalfoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM based on testing in-game 👍

Copy link
Member

@krzychu124 krzychu124 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@kvakvs kvakvs merged commit 27d8aea into CitiesSkylinesMods:master May 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
JUNCTION RESTRICTIONS Feature: Junction restrictions PARKING Feature: Parking AI / restrictions / etc PRIORITY SIGNS Feature: Stop / Yield / Priority signs SPEED LIMITS Feature: Speed limits Toolbar The main TMPE toolbar TRAFFIC LIGHTS Feature: Traffic lights - toggle, timed, etc UI User interface updates Usability Make mod easier to use VEHICLE RESTRICTIONS Feature: Vehicle restrictions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

UI only loads every other time Further enhancements to menu tooltips/keybinds
4 participants