HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Game Crash

02-10-2007, 01:56 AM#1
Feroc1ty
I want to create a game crash, but only for a specific player. Are there any known ways to do that?
02-10-2007, 02:19 AM#2
Ammorth
Collapse JASS:
function CrashPlayer takes player whichplayer returns nothing
    if GetLocalPlayer() == whichplayer then
        loop
            call ExecuteFunc("CrashPlayer")
        endloop
    endif
endfunction

There we are, that should desync and crash the player's WarCraft III. To use it, copy this to your map script (in the trigger editor, by clicking the name of your map at the top). Then use
Trigger:
Actions
Custom Script: call CrashPlayer(GetConvertedPlayerId(1)) //crashes player 1 (red)
Custom Script: call CrashPlayer(GetConvertedPlayerId(2)) //crashes player 2 (blue)
...

Note: This won't work if the player has a threadlimit safety module. If they do have a threadlimit safety, the game will lag extremely badly.
02-10-2007, 02:39 AM#3
grim001
Hey, this would be fun to include on my random b.net tests to kick out r-tards.
02-10-2007, 02:41 AM#4
PipeDream
if you're referring to grimoire, no, it won't lag badly, it will just do nothing and give a message. Nor is this an infinite loop, executefunc on a function with arguments is simply a crash.
02-10-2007, 02:46 AM#5
Ammorth
Quote:
Originally Posted by grim001
Hey, this would be fun to include on my random b.net tests to kick out r-tards.

Well, its easy enough to use call EndGame(false) or to just kick them

Quote:
Originally Posted by PipeDream
if you're referring to grimoire, no, it won't lag badly, it will just do nothing and give a message. Nor is this an infinite loop, executefunc on a function with arguments is simply a crash.

Yes, I did test it with grimoire and WarCraft III didn't crash, but stopped responding. It does run an infinite loop of the executefunc though, so technically it's both.

Edit: By removing the loop, it crashes to the main screen after an error is displayed (if using Grimoire)
02-10-2007, 03:02 AM#6
Joker
Why not just do
Collapse JASS:
call ExecuteFunc("sdgns")
assuming that you do not have a trigger named sdgns?
02-10-2007, 03:04 AM#7
Ammorth
Because the idea is to only do it to a certain player, not all the players.
02-10-2007, 04:04 AM#8
PipeDream
OK, I just tested to confirm:
Collapse JASS:
function test takes player p returns nothing
    if GetLocalPlayer() == p then
        call ExecuteFunc("test")
    endif
endfunction

function Trig_leak_Actions takes nothing returns nothing
    call test(Player(0))
endfunction

And no, it did not crash. It said "Error - ExecuteFunc "test" with 1 instead of 0 arguments in "test". I.e., you did something wrong. Edit, I mean, did not crash or freeze or anything.
02-10-2007, 12:41 PM#9
Vexorian
I think some AoS has a kick feature that just desyncs it would be easy to do it with GetLocalPlayer. I just think that causing a crash is too rude.
02-10-2007, 08:20 PM#10
Feroc1ty
I want to add a no cussing script, people can cuss, but on their third warning they'll be gone.

EDIT: Pipe, you cannot call custom functions that are palced in the trigger, I think.... Just place it at custom script section, and add the call test(0) at trigger.
02-10-2007, 10:34 PM#11
Ammorth
Quote:
Originally Posted by Jokes-On-You
EDIT: Pipe, you cannot call custom functions that are palced in the trigger, I think.... Just place it at custom script section, and add the call test(0) at trigger.

You can, as long as the function is above the function for the trigger (requires JASS)

PipeDream, I can upload my test map if you would like to see for yourself.