 |
|  |
 |
|
Catfish
|
|
Wollongong, Australia
Aug 2000 time: 14:16
|
|
I just gave the file a quick scan and the flag events seemed to be structured OK. One thing I noticed, unrelated to flags, is that all of your JustOnce modifiers are placed at the end of each event. Here's a quote from macro.txt:
quote: The JustOnce statement should be included immediately after the @THEN statement. |
Whilst I've never detected any problems related to this, I follow this rule as a precaution.
How are you testing the events, Curt? The flags must be initialised before they will work. If you are running delevent.exe on a .sav file and reloading then the flags will not be initialised until the following turn.
|
|
|  |
 |
|  |
 |
|  |
 |
|
Catfish
|
|
Wollongong, Australia
Aug 2000 time: 14:16
|
|
quote: Originally posted by curtsibling
Cheers for scanning the events, at least I know the flags are not screwed up... |
I only checked the basic structure. You seemed to have a handle on that.
quote: Originally posted by techumseh
If you did debug the file, the errors Merc found would have come up first time. |
Not necessarily. If so he would probably have also received the "There was an error encountered in the 'events.txt' file. Please read the manual to find out how to debug this file." message.
quote: Originally posted by curtsibling
@IF
Checkflag
Who=Third Reich
Mask=0b0000000000000000000000010000001
Count=2
State=on
@THEN
JUSTONCE
TEXT
^
^^ Total victory over England!
^
^^ Great Britain has been smashed, the once-proud British armed forces are
^^ scattered and destroyed. The Führer can now order his forces to fortify
^^ the UK as a massive bulwark against the Americans.
^
^^ "Der sieg wird unser sein!"
^
ENDTEXT
PlayWaveFile
GERVICTOR.wav
@ENDIF |
Count the number of zeros in that binary mask. You should have 32 (0-31) digits; you've got 31. Edit: Just testing. Actually, it shouldn't make a difference in this case as:
Mask=0b00000000000000000000000010000001
is the same as:
Mask=0b10000001
Remember, when you test, capture the cities in the second turn after reloading otherwise nothing will happen. The CheckFlag event won't occur until the turn after that.
Last edited by Catfish on 12-11-2004 at 08:45
|
|
|  |
 |
|  |
 |
|
Thoddy
|
|
Hannover, Germany
Jan 2001 time: 06:16
|
|
quote:
@IF
CITYTAKEN
city=LONDON
attacker=Third Reich
defender=British Allies
@THEN
Flag
Continuous
Who=Third Reich
State=on
Flag=0
@ENDIF
|
you should include some text into the flagchanging events.
like this
Text
Flag London on
endtext
just for testing
-------------------------------------------------------
from the events I see events simulating an naval warfare
@IF
Randomturn
denominator=2
@THEN
CREATEUNIT
unit=Convoy
owner=further Neutrals (Barbarian)
veteran=yes
homecity=none
locations
70,84
......
endlocations
randomize
Text
Convoy deployed
Endtext
@ENDIF
@unit
Convoy,no, 2, 14.,0, 4a, 9d,3h,2f,100,0,2, Aut, 110000010000001
@IF
UNITKILLED
unit=Convoy
attacker=Allies
defender=anybody
@THEN
CREATEUNIT
unit=Convoy
owner=further Neutrals
veteran=no
homecity=none
locations
65,91
...
endlocations
randomize
Text
Convoy deployed
Endtext
Changemoney
receiver=Allies
amount=-250
@ENDIF
@IF
UNITKILLED
unit=Convoy
attacker=Germans
defender=further Neutrals
@THEN
CREATEUNIT
unit=Convoy
owner=further Neutrals
veteran=yes
homecity=none
locations
67,87
...
endlocations
rondomize
Text
Convoy deployed
Endtext
Changemoney
receiver=Allies
amount=-250
@ENDIF
you are able to create a convoy hunt, the barbarian convois wandering around the Water much better than
other AI-ships with 2 human player this hunt may be interesting.
Last edited by Thoddy on 17-11-2004 at 14:42
|
|
|  |
All times are GMT. The time now is 05:16. Apolyton Time is 00:16. |
top of page
|
|
|
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
|
|
|
|
|
|