Get Player Tint
Get Player Tint
I'm trying to find information on how to get the players tint, like how when a player enters a car it switches to that color. I've tried looking at the code in the base mod, but it hasn't been very helpful.
- ickputzdirwech
- Filter Inserter
- Posts: 794
- Joined: Sun May 07, 2017 10:16 am
- Contact:
Re: Get Player Tint
Have a look at the lua api: https://lua-api.factorio.com/latest.
To change the color of all vehicles the player enters you would have to do the following:
Hook into the event on_player_driving_state_changed
Check if the player is driving
Set the vehicle color equal to the player color
Hope you can figure out the details on your own. You might have to be careful wether the player has a character or not. If you have trouble with it don’t hesitate to ask.
To change the color of all vehicles the player enters you would have to do the following:
Hook into the event on_player_driving_state_changed
Check if the player is driving
Set the vehicle color equal to the player color
Hope you can figure out the details on your own. You might have to be careful wether the player has a character or not. If you have trouble with it don’t hesitate to ask.
Mods: Shortcuts for 1.1, ick's Sea Block, ick's vanilla tweaks
Tools: Atom language pack
Text quickly seems cold and unfriendly. Be careful how you write and interpret what others have written.
- A reminder for me and all who read what I write
Tools: Atom language pack
Text quickly seems cold and unfriendly. Be careful how you write and interpret what others have written.
- A reminder for me and all who read what I write