-
-
Notifications
You must be signed in to change notification settings - Fork 17
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
Disabling lucky balls, devil balls and decoys #38
Comments
I believe some props are breaking themselves, it might be rolling bottles or something else. |
Then why are they spawning balls? The config has them disabled. And what about the decoys? |
Interesting @Vinzuerio take a look at this please when you have time. |
I found a code that checks for "https://github.com/Wolvin-NET/prophuntx/blob/eedee1dee43c450187f45c89b3e4a6b7c7995695/gamemodes/prop_hunt/entities/entities/ph_devilball/init.lua#L59C2-L59C129" isplayer and inround. It may be only disabling them for player actions if the map itself breaks it, it may not count. |
Do they respawn randomly or in place of props? |
Also map description mentions "Prop Hunt: X2Z Settings: Item Spawner: Yes, Decoys on Spawn: Yes" |
They spawn randomly from what I've seen. In other words, the map forces these settings? |
Probably, the description is a little vague about that. Item may be weapons ammo or "balls". I'm not sure. |
It seems like a plausible explanation. The other map that had this issue was ph_underwataaa. |
If that is the case, then perhaps another 2 settings that disable spawning right in ph_decoy_spawner.lua and ph_teamitem_spawner.lua might do the trick? |
For now I just hardcoded makeEntity and CreateBall and it seems to work. Please look into this matter if you have time. I do not have the time to learn the repository, nor to get the hang of LUA. I might try to make a better fix for this in the future if nobody else does. Either way, thanks for the quick responses. I will be here to answer any other questions that might come up. |
For some reason the decoys still spawned on underwataaa. I hardcoded some stuff in ph_fake_prop.lua and it's fine now. |
Nice, I hope it fixed things. |
Sorry just checked the issue today (I have very terrible equipment problem on my end so i have to use my friends pc to check) and should this get fixed within 1 or 2 weeks ahead, including from my maps that has been in workshop too. |
I have made a quick update using on my friend pc as a GitHub Release 18553e3 (workshop version will be catched up later) where lucky bals, devil crystal and decoys will respect their spawn with the following convars: Some PH:X Maps that use a forced decoy spawn will be updated late (because I haven't to get my maps on my pc) so as for your temporary workaround as follow:
hook.Add("PostCleanupMap", "DecoyMapCleaner", function()
timer.Simple(2, function()
-- Clear all map-spawned decoys
if not GetConVar("ph_enable_decoy_reward"):GetBool() then
for _,decoy in ipairs( ents.FindByClass( "ph_fake_prop" ) ) do
decoy:Remove()
end
end
end)
end)
A a reminder, Once the workshop has been updated, delete this file after updating. Let me know if this solved the issue. (Please do not close the issue until workshop version is updated) |
Thx for the response. I did manage to get it "fixed" by commenting out whatever functions I could see in the previously mentioned lua files. I kept the declarations to avoid errors. Please do not judge my less than ideal solution. Please let me know when the maps are updated so I can go back to the normal version. |
The project should have specific functions for map makers to use that check the settings before spawning balls or decoys. |
As far as I can tell there are options to disable lucky balls, devil balls and decoys, however they also seem to appear occasionally on some maps such as ph_restaurant_os. Is this intended? Even if it is, disabling them should be an option.
The text was updated successfully, but these errors were encountered: