Code Monkey home page Code Monkey logo

Comments (4)

TGRHavoc avatar TGRHavoc commented on August 16, 2024 1

This would be something you'd have to do on the interface side. Unfortunately there's no way at the moment to force a filter by default.

However, if you or your developers are comfortable editing the code yourself and rebuilding it, then the following should be enough:

On line https://github.com/TGRHavoc/live_map-interface/blob/master/js/src/controls.2.js#L112

window.Filter = { on: "change me" } // This should be a property of the user. E.g. "icon" if you're using that for cars.
$("#filterOn").val("change me"); // same as above. Makes the UI show the filter
$("#onlyShow").val("something"); // What do you only want to show. If above is "icon" then this should be the icon number.

Then running gulp in the main directory should be enough to update the minified scripts. You should then be good to go.

This is obviously a work-around for an actual implementation but, it should work for you.

I might add URL parameters to the interface in the next update. This would allow for you to share a URL such as http://live_map/#filterOn=change me&onlyShow=something to automatically apply the filter instead of modifying the source code.

I do need to refactor the interface's code though. Its a bit spaghetti-fied at the moment.

from live_map.

WolfoTheWolf avatar WolfoTheWolf commented on August 16, 2024

Alrighty sounds good, I spent about 4-5 hours going threw all the code trying to figure out what parameters were being used for what, what I was planning on doing after I couldn’t figure out the UI part I was just going to completely remove the player from the map if they are not in the vehicle (aka fully remove the player data via the event) then when in the vehicle it will re-add the player if the vehicle is some sort of police car. Appreciate the quick response and looking forward to see the new features/updates that get pushed out over time.

from live_map.

TGRHavoc avatar TGRHavoc commented on August 16, 2024

Okay, I've made an issue on the interface for the feature I've mentioned here. If everything has been answered and you're satisfied can I close this issue?

from live_map.

WolfoTheWolf avatar WolfoTheWolf commented on August 16, 2024

Yup everything is fine, thanks for the response

from live_map.

Related Issues (20)

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.