tung362 / RoR2PVP

Risk of Rain 2 PVP Mod
https://thunderstore.io/package/60dfb16d5e944afc/RoR2PVP/
5 stars 0 forks source link

Features request - disable seeing players through walls; stop mobs from being allied with host #2

Open Andrej730 opened 4 years ago

Andrej730 commented 4 years ago

Is it possible to add two features to this modification:

  1. Disable ability to see other team players nicknames through walls.
  2. Spawned mobs should not be allied with host team.
tung362 commented 4 years ago

Hi, thanks for the feature requests!

To address the enemy nicknames being seen through walls, I have tried to disable it in the past but I believe it's client sided. When I created this mod I decided to make only server sided modifications the reason being to make it more flexible (IE: only the host needs to have the mod installed so others in the lobby don't also have to go through the hassle of installing the mod which gives you the ability to create semi public lobbies for example recruiting for players in the official RoR2 discord should they have at least the API installed). Adding client sided modification removes that flexibility in some ways, I could remove nicknames should you have the mod installed but everyone in the lobby would also need the mod installed or else those that don't will still be able to see your name (personal handicap). I might be re-adding the feature that allows unmodded players to join the lobby in the near future so that players other than the host don't even need to have the API installed to join.

As for spawned mobs, I'll try see what I can do to have them spawn in both teams in the next release. There might be some problems with it during teleporter transition so no promises.

Andrej730 commented 4 years ago

As for spawned mobs, I'll try see what I can do to have them spawn in both teams in the next release. There might be some problems with it during teleporter transition so no promises.

Are you thinking adding mobs to both teams or make mobs hostile to them?

tung362 commented 4 years ago

As for spawned mobs, I'll try see what I can do to have them spawn in both teams in the next release. There might be some problems with it during teleporter transition so no promises.

Are you thinking adding mobs to both teams or make mobs hostile to them?

It would have to be adding mobs to both teams unfortunately.

RoR2's current team system is Player team | Neutral team | and Enemy team and its set up in a way that makes adding new team types difficult without remaking a lot of it, also there are some parts that relies on the team type but are hard coded such as the mob's targeting AI so the easy solution would to assign mobs to either the Player team and or the Enemy Team (The 2 different teams assigned for pvp). If i were to assign mobs to Neutral team you can hurt/kill them but they won't attack you automatically unless you attack them and drones won't attack them either. For me to fix it i'd probably have to edit or remake a lot of different AIs such as for the drones, the different mobs etc, also not to mention editing a lot of things that relies on the current team system such as the death plane and things I haven't yet discovered. I also could probably intercept the function for targeting AI and modify it before sending but that's for every mob active per frame idk how well that would be for proformance.

Another solution would be to ditch the whole team system for pvp and modify how damage collision filtering works kind of like friendly fire so that I can keep track of teams with my own solution and keep mobs to the default enemy team. The problem is I currently don't know if damage is handled client side or server side atm and if it's client sided this solution won't work. It would also cause drones to no longer attack enemy players since everyone would be on the default player team from the vanilla team system.

Generally RoR2's code is pretty flexible and modular but for some reason the team system is set up in a way where it's hard to add new team types almost enforced to only the 3 types.

The shorter answer is I probably could make it attack everyone but i'd have to look into it more.

tung362 commented 4 years ago

Also anyone who's reading this, your all welcome to download my source btw and make your own pvp mods etc, maybe someone will have a better way of handling this than me! :D

tung362 commented 4 years ago

A new version is now released! Mobs and player team 2 are no long in the same team.

BigBlazer commented 4 years ago

Currently a friend and I have the issue, that when the person who joined the server dies the host isn't able to see the persons location anymore. But on the other side, the host is always visible to the other player no matter if he died already or not. This ends up leaving the host in a disadvantage not being able to see the other player with indicators through the wall, but still being visible by the others.

tung362 commented 4 years ago

Currently a friend and I have the issue, that when the person who joined the server dies the host isn't able to see the persons location anymore. But on the other side, the host is always visible to the other player no matter if he died already or not. This ends up leaving the host in a disadvantage not being able to see the other player with indicators through the wall, but still being visible by the others.

Thanks for your report! I'm not exactly sure I can fix that without requiring every non host player to also download the mod sadly due to indicators usually being Client-side, I believe it's hard coded to show team 1's name no matter the team you're on and would require every client to be modded to fix it. have you tried testing it with 3 or more players? Does it just show the host's name only or does it show the whole team's names?

I have tried removing name indicators in the past but it only affected the client that was modded which made me come to the conclusion that it was client sided. If I did remove name indicators on modded clients it would only serve as a self handicap to those that installed the mod since unmodded players would still see the name tags.

BigBlazer commented 4 years ago

I've noticed that as well, it is client side and I've only experienced it for the client only, no other team members

Am Do., 9. Apr. 2020 um 13:50 Uhr schrieb Tung Nguyen < notifications@github.com>:

Currently a friend and I have the issue, that when the person who joined the server dies the host isn't able to see the persons location anymore. But on the other side, the host is always visible to the other player no matter if he died already or not. This ends up leaving the host in a disadvantage not being able to see the other player with indicators through the wall, but still being visible by the others.

Thanks for your report! I'm not exactly sure I can fix that without requiring every non host player to also download the mod sadly due to indicators usually being Client-side, I believe it's hard coded to show team 1's name no matter the team you're on and would require every client to be modded to fix it. have you tried testing it with 3 or more players? Does it just show the host's name only or does it show the whole team's names?

I have tried removing name indicators in the past but it only affected the client that was modded which made me come to the conclusion that it was client sided.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/tung362/RoR2PVP/issues/2#issuecomment-611486154, or unsubscribe https://github.com/notifications/unsubscribe-auth/APDWXQ4RR3L6X4ZT4CHB33LRLWY7ZANCNFSM4KO2UREA .