Well, I am having an issue which I have no idea of how to solve, because it actually works, but not on multiplayer! and I think it might be some glitch, but before I make a post saying it is a glitch or contact Eric, I am seeking help from the community.
I have been working on a PB2 map that has a flash mechanic, where you press the key F and you flash a short distance, but you can also hold it to flash for a longer one, this was easy to think about and execute, and it did work perfectly fine in singleplayer, however when I tested it on multiplayer, when I release F (currently G because of test purposes) the game crashes, holding F and activating the trigger that releasing F activates also crashes, and there is a timer that activates it, however, I've done some testing and pressing an USE button to activate such trigger, called #release, the game does not crash in multiplayer.
I have asked many map makers help (Ditzy, who I think did not see my message) and Mrnat, who did provide me with a possible cause for things not working properly, that did not solve the issue, I also found a ton of possible mistakes, such as a division by zero and some other weird values, because of the variable declaration order, but such issues seem to have been all fixed, I am quite sleepy at the moment and might not be thinking that right tho.
The map is phsc-flash, https://www.plazmaburst2.com/?s=9&a=&m= ... id=1001686
it is open-source for now, https://www.plazmaburst2.com/level_edit ... -flash&a=#
I made an explanation of how the triggering works on discord so fellow map makers could get a better understanding of the system:
what happens is pretty simple, #start*timer activates #declaration (sets var_load, activates #constantupdate and runs #setbind trigger), #setbind sets trigger #press under hold of key F and sets trigger #release under release of key G (originally F)
#contantupdate*trigger*1 moves the region #cursor to #player*1 cursor and region #player to #player*1 position, and creates the variables var_cursor_x and _y, and var_player_x and _y, for each of their positions, and sets var_distance_x and _y to the same value of var_cursor_x and _y, and calls #constantupdate*trigger*2
#constantupdate*trigger2 sets var_distance_negx and _negy to var_player_x and var_player_Y values, and then the negative of it, so -var_distance_negx and negy, to allow me to add (in this case it would be a subtraction but there is no action so you have to do this) their values to var_distance_x and distance_y, to get the distance betwen the player and the cursor under var_distance_x and _y, i divide both values by 40 so i can work with multiplicating them to the intensity the player wants, this trigger activates #constantupdate*trigger*3
#constantupdate*trigger*3 multiplies var_distance_x and _y by var_load, the amount of time the button has been pressed, to a max of 40 (100% of the original value, teleporting to the cursor, and a minimum of 10), it also adds the distance to var_player_x and _y so it can teleport betwen the player and the cursor, since it is only the distance, and after all of that, the region #cursor*goal has its X and Y positions sets to var_player_x and var_player_y
if the player holds F #press is activated, which sets the value of var_load to 10, activates #constant_hold timer and deactivates itself, #constanthold calls with a delay of 1 #hold, which shows a hint with the value of var_load, adds one to it, and checks if it is over 40, if it is over 40, the timer #constanthold that activated such trigger is deactivate and the trigger #release is activate
#release is what happens when you release F (in this case G so you guys understand the issue, #release deactivates #constanthold and activates the timer #reactivation, updates the hint to reloading... teleports the player to #cursor*goal and deactivates itself, the timer #reactivation has a delay of 30 and activates #reactivate, which activates trigger #press, deactivates itself, shows the hint reloaded, and activates #release again so it all can start again
HELP