Ahmedos Posted March 31, 2023 Share Posted March 31, 2023 How i can add 2 gamemods working in the same time inside one single server like : FFS Gaming server there are derby , FDD, DD , PTP...etc game mods working in the same time how i can make something like that i have no idea. Link to comment
AngelAlpha Posted March 31, 2023 Share Posted March 31, 2023 check it [lobby] | Multi Theft Auto | Community Link to comment
Ahmedos Posted March 31, 2023 Author Share Posted March 31, 2023 1 hour ago, AngelAlpha said: check it [lobby] | Multi Theft Auto | Community I don't mean the main menu, I mean Multi Game Mode Link to comment
Moderators IIYAMA Posted April 1, 2023 Moderators Share Posted April 1, 2023 16 hours ago, Ahmedos said: I mean Multi Game Mode The generic answer is, you need to create a resource that serves as manager > and rewrite each gamemode, so that their usage can be scoped(data/elements/events) for specific players. Best is to get inspiration from an already existing Multi Game Mode resource. Since this is really a lot of work and complexity. Explaining the process from A to B would take too much of my time (sorry). 1 Link to comment
Ahmedos Posted April 1, 2023 Author Share Posted April 1, 2023 5 hours ago, IIYAMA said: The generic answer is, you need to create a resource that serves as manager > and rewrite each gamemode, so that their usage can be scoped(data/elements/events) for specific players. Best is to get inspiration from an already existing Multi Game Mode resource. Since this is really a lot of work and complexity. Explaining the process from A to B would take too much of my time (sorry). yeah, i got it, but the problem is if i want to load some resources for specific players -as a gamemod- everytime when the player join the gamemod the resources restarting and even the server side resources. Link to comment
DiSaMe Posted April 2, 2023 Share Posted April 2, 2023 Resources do not run "for specific players". Each resource runs for all players and on both server and the client. Nothing to start/stop/restart on player join - you do it when starting up the server, just like with ordinary gamemodes. It's just that the gamemodes have to be modified so that instead of doing stuff on the global level, they would do it in their own scopes. For example, if the gamemode executes some code in onPlayerJoin event, you have to modify it to execute that code when the player enters that gamemode instead. Likewise, if the gamemode does something in onPlayerQuit, it has to be done when the player leaves the gamemode - which could be when the player quits, or when they switch to a different gamemode. If the gamemode calls getElementsByType to retrieve all elements of a particular type in the server, it has to pick out its own elements only, to avoid acting on another gamemode's elements. Link to comment
FlorinSzasz Posted April 2, 2023 Share Posted April 2, 2023 u can make a big gamemode with more minigames or split the gamemodes in dimensions one gamemode is in dimension 0 and another one is in 1 or 2 or etc u got my point i think. Link to comment
Ahmedos Posted April 3, 2023 Author Share Posted April 3, 2023 9 hours ago, FlorinSzasz said: u can make a big gamemode with more minigames or split the gamemodes in dimensions one gamemode is in dimension 0 and another one is in 1 or 2 or etc u got my point i think. 18 hours ago, DiSaMe said: Resources do not run "for specific players". Each resource runs for all players and on both server and the client. Nothing to start/stop/restart on player join - you do it when starting up the server, just like with ordinary gamemodes. It's just that the gamemodes have to be modified so that instead of doing stuff on the global level, they would do it in their own scopes. For example, if the gamemode executes some code in onPlayerJoin event, you have to modify it to execute that code when the player enters that gamemode instead. Likewise, if the gamemode does something in onPlayerQuit, it has to be done when the player leaves the gamemode - which could be when the player quits, or when they switch to a different gamemode. If the gamemode calls getElementsByType to retrieve all elements of a particular type in the server, it has to pick out its own elements only, to avoid acting on another gamemode's elements. thanks both of you gave me good ideas Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now