• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[JASS] weird behavior of script

Status
Not open for further replies.
Level 19
Joined
Dec 12, 2010
Messages
2,069
In my map red player disabled.
And idk how, but: scripts and messages doesnt work until my hero kill another, OR if i will share control of player(0) to my existing player(1) via jass, since there are no any units or whatever belong to the red player

Also, no messages will show up unless that controlshare or kill. not even BJDebugMsg.

map attached.
uncomment this line
Code:
//call SetPlayerAlliance(Player(0),Player(1),ALLIANCE_SHARED_CONTROL,true)
to make "it" happy.
i do not want msg "... shared ..." in map at all =\

Could someone explain where is coding fail? cause i lost so much time with itt,cant find out by myself
 
Last edited:
Level 26
Joined
Aug 18, 2009
Messages
4,097
The code does trigger. The messages do not show up because in this line

JASS:
call DisplayTimedTextToPlayer(playerModeTyper,60,0,0,"Enter Game mode. Use \"|c00ff0000-t|r\" for Team Deathmatch and \"|c00ff0000-f|r\" for Free for all match. Type |c00ff0000number|r after letter to decide kills limit to win.\nExample: |c00ff0000-t 60|r\n or |c0000ff00-f 45|r or |c000000ff-t120|r")

you have set a very high x position (out of visible area), probably exchanged x coordinate and duration. This affects all prior messages as well, which is why you would not see any debug messages before this (since it runs without wait). Once a unit dies, you reset the text positions. Also, you should pay attention to instances of
JASS:
ClearTextMessages
.
 
Status
Not open for further replies.
Top