Possible? Make MP-Map_Change without item and Money revamp

Users who are viewing this thread

Meneldur

Sergeant Knight
The title says it all
in current Mp system every map change causes round end.
I´d like to have it that way the player can take his equip/ money through next map.
Can this be done? hopefuly by use of Module_system-
Andif how
 
It could be done, but it would be a lot of work: when a new scene is loaded the players all rejoin to the server, so player slots are cleared; this means that you would need to save the gold and items (with the 1.134 agent_get_item_slot, the previous player_save_picked_up_items_for_next_spawn probably wouldn't work) to a dummy troop's slots - or something else that stays between scene changes - and then adjust lots of the native multiplayer equipment scripts and triggers to work with it. Not a project I'd advise for anyone fairly new to the module system; I would guess it would require a lot of changes and added scripts.
 
Thanks for reply Vornne
when a new scene is loaded the players all rejoin to the server
ah and this is nessecary? Dont happen because the a script say so?
Because it was my idea that their could be such an operation be found who simply needs to get diactivated/commentet!

Propably not ****; but the most critcal point i see in your description is:
to a dummy troop's slots - or something else that stays between scene changes
 
Your proposals about the get_item_slot jazz i found in header operations but how can i save /load any stuff that lasts over a player rejoin server?
This is possible I know "Crpg" deos it but i fear other programms then module system are in use here. :sad:

Not a project I'd advise for anyone fairly new to the module system;
Im not exactly new im simply not that good lol.
 
Meneldur said:
when a new scene is loaded the players all rejoin to the server
ah and this is nessecary? Dont happen because the a script say so?
Because it was my idea that their could be such an operation be found who simply needs to get diactivated/commentet!
I'm almost certain it's hard coded, not a script, since I have removed basically all native mission templates and scripts, reimplementing at least all relevant ones without copy / paste: using the same operations to start a new scene as in native, the players show as reconnected by the ti_server_player_joined trigger.

Meneldur said:
Propably not ****; but the most critcal point i see in your description is:
to a dummy troop's slots - or something else that stays between scene changes
Your proposals about the get_item_slot jazz i found in header operations but how can i save /load any stuff that lasts over a player rejoin server?
This is possible I know "Crpg" deos it but i fear other programms then module system are in use here. :sad:
From my testing: faction slots, troop slots, item slots, and globals remain through scene (mission) changes / restarts, but agent slots, player slots, and scene prop slots do not. The cRPG type mods use the send_message_to_url operation and script_game_receive_url_response to communicate with an external webserver.
 
To elaborate a bit on what Vornne said, you'll want to do something like this:

At the end of each round (assume you're not 100% sure after which round the map will change) loop through the players. Get their id, gold count, each item, and whatever else you want. Store this data in a consistent format in the slots of a dummy troop (any troop not used in multiplayer should work, although I advise making a new troop). For example, you could store the data like this:

Slot#: 0                |  1                      | 2-9                    | 10              | 11                    |
Data: Player 1 ID|  Player 1 gold|  player  1 items| Player 2 ID| Player 2 gold| ...

Then, when each player "rejoins" (the join trigger) iterate through that and set the appropriate data to the appropriate players (get the player's id, iterate through the slots, if the id matches, set that player's data with the following data).
 
Exactly, only one thing: you'd need to test to see if the players always rejoin with the same id - I'm not sure - and if not, store them indexed by the player's unique id, with player_get_unique_id.
 
Actually, I am pretty sure you don't get a new player ID on map change. It really just changes when joining/leaving.

So all you'd have to do is to stop the gear from resetting, or whatever you have in mind.

But it's as Vornne said, you will still need quite some knowledge of the module system to pull it off.
 
chadz said:
Actually, I am pretty sure you don't get a new player ID on map change. It really just changes when joining/leaving.

So all you'd have to do is to stop the gear from resetting, or whatever you have in mind.

But it's as Vornne said, you will still need quite some knowledge of the module system to pull it off.
I'd be wary of people joining/dropping between round changes. It might not happen under very often, but it will happen. That's why I said player id instead of player number.
 
I have to admit that this is not in my skills range so far. So your genrous advisory might lead to anything only in the long run.

What i have in mind @chadz is this:

1st:
Of all it is a bit wierd that in open battle 2 teams hack each other about 10-20 rounds at the same field without any environmental changes.  :grin:  I think it would simply make a better game feeling and more tactical challenge to shuffle the maps much more.

2nd :
I hate it that we suffer so much weapon-class spam  being the superior tactic at the most maps.  Generated plains >Cav. Villages > Arch. on roof etc.
So id like to change maps / scenes after every or at least every 2nd round to enforce a team to succed at many different maps /scenes.
This at least will shuffle the weapon-class who is spamed much more and if possible with the save item/ money thing make the player more dependent on earlier decisions.

3rd: There are two persistant World modes out there far  i know. The Fantasy one "FPW" and the "PW" both in my view suffer the fact that  the world persists but the player not at all. While  "CRPG" does it the other way arround.

So have a mode with persistant world/s and raiseable chars. might be the one whos missing.
 
Back
Top Bottom