-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathchangelog.txt
1482 lines (1350 loc) · 87.3 KB
/
changelog.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
(Note: file not intended for word wrapping)
*PyWright 0.986
- Fixed setting blipsound from character animation files. You can't set the blipsound this
way for "hide" characters. Prefered method is to 'set char_[folder name]_defsound blipfemale.ogg',
as you only have to set this once and it works for all animation files in the folder, and lasts
for the entire game. If your character goes through a sex change you can also change it easier :)
- Back button blocks script again so it will work properly from check scripts
- fixed some debugging info that broke unicode, multi character sets work again
- slightly better gui scrollbars, was cutting off lower pixels
- changed method of running the court_record button macros to fix some order of operation bugs
- bugs fixed in wide examine scenes related to court record button, and correct scroll position
- in rare cases save could crash
- some timing issues with text reverted to old code, still need to work harder to make things
framerate independant
- press F3 while a game is running in debug mode ('set _debug true') to see a dialog showing
the currently running script code with the current line highlighted in red
*PyWright 0.985
Wrightscript
- Fixed letter spacing when using pwinternational font (which changed to be the default)
- "noback" option added for 'list' and 'present', USE THIS instead of setting _list_back_button
and _cr_back_button variables.
The hidden back button on the interface will only be hidden during this specific present
screen. You can cause a dangerous bug in your games if you disable the back button with
the variable and forget to restore it.
- 'is variable' now properly checks if the variable is true/false, instead of only checking
if the variable existed. Use 'isempty' or 'isnotempty' to check if a variable exists
- loading a game saved during a localmenu command would go to the next line after the menu
- game pauses when minimized (a few animations continue)
- Text macro {linked} when at the start of a textbox will join the current textbox to the previous
one. Example:
"This is weird."
pause 60
"{linked} What is going on?"
Will print "This is weird. What is going on?" with a pause in between the two sentances.
- changed emotions on characters dont erase certain settings, such as their z value
- characters with greyscale effect animate in greyscale
- Fix for fail= argument with 'examine' command
- set a character's default "voice", otherwise known as blipsound, to avoid having to use
{sound blipfemale.ogg} on every female character's line:
set char_defsound blipmale.ogg - set default blipsound for ALL characters
set char_[folder name]_defsound blipfemale.ogg - set default sound for that port folder
- also set a characters permanent default nametag:
set char_[folder name]_name Bob
- If character's nametag is not manually set, it will default to capitalized
- can force a character animation to play a certain way with text macros:
{blink} {talk} {loop} and {lipsync}
Characters default to lipsync, which means they will talk when text is printing,
and blink when it is not. {blink} and {talk} will force either of those modes.
{loop} will just cause the animation to cycle forever. Example:
"{talk}(Even though text is in parenthesis, I'm still talking.){blink}"
Only affects currently _speaking character
- arguments can be passed to a called macro:
macro testmacro
"You have passed this argument {$1}"
endmacro
testmacro some_argument
Above script will print "You have passed this argument some_argument"
- can pass named values into a macro:
macro something
"{$passed_value}"
endmacro
something passed_value=hello
Will print "hello"
- sometimes would crash if you click before text in a textbox starts displaying
- games slow down less if framerate drops, will become more jerky but not slow
- force an animation to pause:
controlanim name=someanim pause
controlanim name=someanim resume
- can specifically set the frame of an animation with:
setprop name=someanim frame=5
- gui button's were not able to be deleted
- try_bottom option added for gui button command. If PyWright is running in dual screen
mode, the button will appear on the bottom screen. If PyWright is running in single
screen mode, the button will appear on the top screen. For x and y values, use values
which would place the button on the bottom screen. When the engine forces the button
to the top screen, it will subtract 192 from whatever the y value is.
- music_fade_in nowait, music_fade_out nowait available, if you want to fade the music
while doing other things
- fix bug where fg objects with wait would execute the next line of code before pausing
- the _num_screens variable will be set to 1 if there is only 1 screen, and 2 if there are 2
Engine/Updater
- What used to be called "display.ini" is now called "settings.ini" because it stores
more settings than just the display ones.
- downloader creates missing folders
- less downloader crashes, such as when it tries to resume a failed download
- minor pywright gui tweaks to mouse click detection
- changed pywright gui colors to better represent phoenix stylings
- display games on game list in alphabetical, or most recently played order
- game titles on menu have word wrapping
- some settings screen adjustments
- fps display moved to lower left corner, toggle it in settings
- changed autosave to work based on time rather than scripts, saving evey 20 minutes
by default, interval can be changed from settings
- Command line arguments, could be built into a shortcut:
Run a game directly with:
PyWright.exe -run "games/MyGame"
text mode, useful to debug quickly, will get more useful as it gets updated
PyWright.exe -run "games/MyGame" -text
Customizability
- some helpers to show evidence added graphic:
core/macros/evidence.mcro
set _ev [evidence_tag]
set _description description to display
set _name name to display
and then
addevanim - show scrolling info box about evidence, while also adding evidence to the court record
showevl - popup evidence in left corner
hideevl - pop away evidence in left corner
showevr - popup evidence in right corner
hideevr - pop away evidence in right corner
If you want the description to match previously set description:
set _ev [tag]
set _description [tag]_desc
set _name [tag]_name
- couldnt override press/present buttons with different sized images, replaced custom press/present
with ripped versions
- hardcoded court_record button replaced with macro in core/macros/gui.mcro
You can still change how it looks by overriding the graphic, but if you override
the macros you can control how it works too, such as where it is positioned
on the screen.
- More built-in options for second screen interface:
'theme_screen2 {theme}' is a macro to set how the interface on the second screen looks
replace {theme} with one of:
phoenix - from pheonix wright, or GS1-3
mia - mia shadow from phoenix wright series
edgeworth - edgeworth shadow from phoenix wright series
apollo - for apollo justice
gk - for pink button from Ace Attorney Investigations/GK
You can also configure scanlines, the button images, and the background with
more precision by setting _bigbutton_bg, _bigbutton_img, _bigbutton_cross to the
respective image path for those elements, and setting _screen2_scanlines on or off.
Default is to use the old button and backgroundwith scanlines off, since those images
have scanlines in the image already.
You can turn the 2nd screen letterbox (white lines on top and bottom) on and off
with _screen2_letterbox (this one defaults to "on")
macro found in core/macros/gui.mcro/theme_bigbutton
Check examples/bigbutton_changes for example
*PyWright 0.980/0.981: September 21, 2010*
(0.981 fixed some last minute bugs with mac, the updater, and cross examination arrows)
-large collection of random examples included with update, demonstrating (badly) features from the
last few versions
-{spd5} in a textbox determines how many letters are added per update, {delay5} is how many frames
between updates. ({spd} was disabled in previous versions due to bugs)
{spd0} is a special case that will print every available character up to either a speed change
or the end of the text.
"{spd0}This is all printed in one go{spd1}Back to letter by letter"
-For every textbox, the text that is displayed is set to the variable $_last_written_text
-textboxes can be "linked" a la aao like so:
"Some text to start with, {next}"
#change background or character or what have you
"{spd0}{$_last_written_text}{spd1}and some more text"
-Fixed a bug with vairable substitution in textboxes that didn't keep formatting intact:
set james_name {c009}James{c}
"Oh look, it's {$james_name}!"
Will now print James in blue text
-changes to options screen
-users can limit how many autosaves are kept
-resolution sets the actual resolution, double or single screen is stretched to fit. Before, the
resolution option was setting the resolution for a single screen, so doubling it might have
gone into an invalid resolution
-resolution also lists actual resolutions your monitor will support
-software 3d rendering support
example in "examples/3d_real"
file format supported is wavefront OBJ files. Free software blender (blender.org) can export
into that format.
use the "surf3d" command to create a display area for the 3d object
syntax: surf3d x y render_width render_height display_width display_height
If you set a smaller render_width than display_width, you will get lower quality rendering that is
then scaled up to fit.
the surf3d automatically gets the id_name (used with delete name=) of "surf3d"
use the "mesh" command to load a .OBJ/.MTL file. The files should contain a single object, a single
material, and a single texture.
syntax: mesh obj_name
the obj name should be something like "some_object.obj" and the files "some_object.obj" and
associated .mtl and texture image files should be located in art/models
the mesh automatically gets the id_name (used with delete name=) of "mesh"
You should only load one object at a time
to rotate the object, you can use the normal "rotate" command. "rotate name=mesh axis=y" will
rotate left and right, axis=x will rotate up and down, and axis=z will rotate it in a flat 2d way
to zoom in and out on an object, use the normal scroll command, to change the z value
there is a hardcoded limit of maximum and minimum zoom
to set up examine points on an object, first use a set of "region3d" commands to define clickable
regions. These regions are actually a rectangular region referencing the image texture mapped
onto the mesh. For instance, if you have a blood splatter you want to be able to click in 3d,
you would find a rectangular region on the texture which has the splatter, and call
"region3d x y width height blood_splatter" for that hotspot.
syntax: region3d x y width height label
to activate those 3d regions, call "examine3d"
mesh/surf3d are saved in save files, but their rotation and zoom are not saved
-some special effects added
check examples/tint_effects
-can tint graphics: tint name=id_name start=color_to_start_on end=color_to_end_on speed=fade_speed
-can invert graphics: invert name=id_name
-can greyscale graphics: grey name=id_name
-If you add "hold" to the arguments for a gui Button, the action will repeat each frame as long as
the button is held down with the mouse
-can fade music in and out
check core/macros/music.mcro for the code
basically:
mus blah
music_fade_in
and:
music_fade_out
but for more control, you can "set _music_fade" a value from 0 (no volume) to 100 (maximum
volume according to users volume settings)
-getprop, setprop commands added to explicitly get and set properties of objects
example:
#get the x value of the phoenix wright portrait
getprop phx name=phoenix prop=x
#Add 5 to the value
addvar phx 5
#Set the x property of the portrait again
setprop name=phoenix prop=x $phx
Currently the only interesting properties you can manipulate are x, y, and z; but it may be more clear to do it this way
than using scroll in some cases. Also if you want to do your own scroll effect, this is a better way to do it.
-debug mode changes:
when in debug mode (set _debug true at the start of a script) "debug" is displayed in the corner of the screen
More errors are shown:
*anytime you interact with an object (scroll, delete, etc) by name= and the object doesn't
exist you will get a warning
*non matching brackets in text: "{command{ hello there" or "this is a statement {f"
*text that goes offscreen
*invalid commands
-production mode: "set _production true" will turn on production mode.
in production mode, errors will be logged but not displayed to the user (and
no clicking will be needed by them to bypass the error)
-other bugs fixed
_textbox_show_button works correctly, _cr_button no longer hides the bottom screen
-left/right tiny arrow for cross examination
-made sure to include cross examination arrows with rounded edge
-small changes to error display, displays a bit more text
-unicode and multiple font support:
set _punctuation - Sets which characters are considered punctuation for lipsyncing
set _font_tb - the name of the font file (relative to fonts/) to use for textboxes
set _font_tb_size - the point size of the font for textboxes
check core/macros/defaults.mcro:init_defaults for all of the other fonts that can be set
-set _textbox_lines is back:
if this is 3 -> The number of displayed lines of a textbox will be 3
if this is 2 -> the number displayed will be 2
if this is auto -> the number of lines displayed will depend on the length of the text
the default is 3
- penalty bar options:
"penalty threaten=10" will show a flashing reminder of how much health they will lose (and it stays
by default)
"penalty" by itself will just show the penalty bar (and it stays)
"penalty delay=100" shows the penalty bar for 100 frames before it goes away
"penalty -10 delay=0" Will show a normal bar deleting 10 points of health, but it will
stay and let the script continue. Do other animations while losing health!
delete name=penalty will delete a penalty bar that stays
- notguilty command moved to core/macros/guilty.mcro, copy the macro and edit if you want to customize notguilty
- guilty command moved to core/macros/guilty.mcro copy the macro and edit if you want to customize guilty
"guilty" for standard guilty text and doors
"guilty_words" for just the words
"guilty_doors" for just the doors (which clear the scene when they finish)
-fixed scroll animations that went further than you told it due to the speed
-new command "gamemenu" to list games in a folder. Use it if your game has a large number
of cases (10 or more) where the normal case selection screen is a bit hard to navigate. Good
for demos.
Syntax: "gamemenu folder" - allows player to choose from games located in the folder. The folder
is relative to the current game directory.
Mostly this command will be used by me to organize the examples better
*PyWright 0.976: July 31, 2010*
- Fixed a memory leak that would slow a game down over time until a "clear"
*PyWright 0.975: July 30, 2010*
- Standardized resource loading routings - anytime you load a resource, or set a resource to be
loaded, you may leave the extension off, or include the extension - your choice. Before, some commands
needed a file extension, some commands needed them off, and some commands worked either way.
Now it is consistent.
For music: you can leave off the extension for .wav*, .mid, .mod, .xm, .s3m, .it, .ogg
For sound effects: you can leave off the extension for .wav*, .ogg
*Only uncompressed wave is supported
For graphics: you can leave the extension off for .png or .jpg
For scripts: you can leave the extension off for .txt
For movies: you can leave the extension off for .mpg or .mpeg
For all types: if you include the extension it should work
Exception: char - you never include an extension for char as they are a bit special
- cleanup of the big arrow code, should be less buggy in general
- fix left and right arrows remaining when not in a cross examine
- The variable _version will be set to the PyWright version. You can use this to version
lock your games if you like:
is _version < 0.974 bad_ver
script scene1
label bad_ver
"I'm sorry, you will need to update PyWright to at least version 0.974 to play"
Rather than locking, I suggest displaying a message that updating would be a good idea
- Some issues with object priorities were fixed, specificlally timers now run at all times
- interface for loading a saved game
(The sorting and dates may not be completely accurate with older saves, but
newer saves should always be at the top of the list from now on)
- more clear when there is an update
- more clear to restart the game after update
- user can turn autosaving off
- configure the hit regions of the court record button
set _cr_button_loadsave off
will make it so the court record button ONLY handles the court record (no save or load)
- added a new defaults macro, load_defaults. These are values that should be set after
a game is loaded, in order to force certain settings even if a save is "corrupted". Not that
useful for the first version, but can be useful to include things here for game updates. All you
have to do is define a load_defaults macro, and set variables in there:
Example:
games/mygame/mydefaults.mcro:
macro load_defaults
set _cr_button_loadsave off
endmacro
This will force the court record to not have the save and load click regions, even
if someone has previously saved without that variable set
- autosave respects _allow_saveload variable
- the _allow_autosave variable can be set to off, to allow the user to save but prevent
autosaves. Not really recommended, users can turn off autosave or not if they
like, and if you want to control whether they save or not you should use
_allow_saveload. However if you have a lot of very short scenes, the autosaving
can be pretty bad, and you should probably turn it off for that. You could also
handle your own autosaves by doing a "save autosave" at set points, rather
than having autosaves happen with scene changes. In this case it makes sense
to turn this off. Note that the players autosave setting will not affect your
own autosaves.
- savegame and loadgame command dont alter the _allow_saveload variable
(You can turn off saves, call savegame at checkpoints or when prompted by
a custom save interface, and not have to worry about the player trying to
save in other ways, or autosave)
- save games from very old versions of PyWright are not supported (the first released
version of Turnabout Substitution for instance) If you have used PyWright
in the last year or so you shouldn't have any old saves anyway.
- Script loading errors don't crash
- Game folders with spaces are supported by the downloader
*PyWright 0.974: June 11, 2010*
- preliminary gamepad/joystick support
- court macro fix for scrolling from helper
- examine screens with 2 sides remember which side the player was looking at last
(can do:
set _xscroll_scriptname:linenumber 0
to reset, where scriptname is the name of the script the examine was from,
and linenumber is the line number the examine command was on)
- the keyword "noauto" on a "char" line will force it to just play the animation straight
without using lipsyncing or blink automation
- download progress sometimes too fast, interfering with the download
- Every time a save file is overwritten the old one is backed up into
"case/save_backup". No interface for restoring saves is implemented,
but the files can manually be copied
- Automatic saves are created every time a new script is run with the "script" or
"menu" commands
- less intrusive save/load messages
- More powerful expressions
Commands using expressions:
setvar_ex [variable name] [expression]
is_ex [expression] [label]
They follow the format of the regular command, except the expression format is a bit more
powerful.
Expression format:
[number or variable] [operator] [number or variable] ...
Operators:
+
-
*
/
==
>
>=
<
<=
AND
OR
Terms can be grouped by parenthesis to alter the order of operations.
The order of operations is: * / + - == < <= > >= AND OR
Examples
setvar_ex hours_played hours_played + 1
(This is the same as 'addvar hours_played 1' but you can do more complex things with
it of course)
is_ex age > 10 AND height >= 5 good
"You are too young or too small, please try another ride."
exit
label good
"You are old enough and tall enough for this ride."
NOTE: the label name cannot have spaces
- fg/detention and fg/detention_apollo included for detention center scenes
- slightly updated interface buttons and cross examination from bigfish
- "check" on examine screen not as finicky
- looping music after save/load bugfix
- press/present on lower screen
- can resize the window with the mouse, slightly better drawing routine for scaled views
- bars on main arrow
set _bigbutton_bg main2
- bigfish shake smoothing, also use {s nowait} if you want text
to continue during the shake
- Added command "shake" to cause a shaking outside of text
shake [time] [distance] {nowait}
- change text of evidence/profiles
dollar sign ($) not required for profile ids
when using addev, second argument is the name of the court record page
to place the item on
addev maya profiles
addev card evidence
When renaming the pages, make sure to addev to the right one.
addev with no second argument (addev document) will go to the "first"
page, whatever the name.
addev with dollar sign ids will go to the "second" page whatever the name
rename pages with "set _ev_pages [firstpagename] [secondpagename] [thirdpagename]"
unlimited # of pages allowed
- discontinued "_allow_present_evidence" and "_allow_present_profiles"
use "_evidence_present" and "_profiles_present" instead
(or "_pagename_present" for renamed pages)
- discontinued "_textbox_show_recordbutton"
use "_cr_button" instead
- skinnable examine cursor:
set _examine_cursor_col FFFFFF
changes the color (html color string)
set _examine_cursor_img path_from_art
use an image instead. Center of image is placed at cursor
ex: set _examine_cursor_img general/evcursor
- defaults:
workaround for making some control variables more obvious and a bit safer
should make the "no back button" type of bug less deadly
new "defaults" macro (in core/macros). This macro resets most customization
variables to their default value. Just use the "defaults" command that
this file supplies.
What this means in practice: If you forget to reset a control variable, it will
automatically reset when a new script is run
*PyWright 0.971/0.973: March 22, 2010*
- Major bug in updater, downloads only worked on resumable files
*PyWright 0.970: March 19, 2010*
- characters can choose different blink animations than the default:
Try with the updated apollo:
char apollo e=confident -> when he's blinking, his mouth is open
char apollo e=confident be=confident2 -> When he's blinking, mouth is closed.
- downloader a little more fault tolerant
- downloader has less urls hardcoded, this will help when I move downloads
to a separate content service from the web site
- randomized clicksound volume
- fixed check button on examine
- loading a game uses correct path for art
- set _blinkspeed_global [min] [max] - overrides global minimum and maximum
frames to wait for a character to blink
set _blinkspeed_global default to reset
- set _blinkspeed_next [min] [max] - the next character added will inherit
this minimum and maimum frames to wait to play the next blink animation
- blinkspeed [min] [max] in art files will set the default speed for that sprite
- blinking sprites "park" at the first frame of the animation instead of the last
- can control a playing animation's properties:
controlanim name=thename start=n end=n jumpto=n {loop} {noloop} {b/t}
name should be equal to the name of an existing object
start will change the first frame of the animation
end will change the last frame of the animation
jumpto will set the current frame of the animation
loop will force the animation to loop
noloop will force the animation not to loop
b will control the blink sprite of named character
t will control the talking sprite of named character
- globaldelay command can control characters now by appending b or t to control
the blink or talk sprite of that character
- fixed word wrapping some more. Bugs seem to be gone. If
_textbox_wrap_avoid_controlled is true (defaults to true), lines containing
{n} will not be wrapped, even if _textbox_wrap is true. If you want to
have text wrapping on lines containing {n}, set _textbox_wrap_avoid_controlled
to false, and _textbox_wrap to true. To always control text wrapping manually,
set _textbox_wrap to false. AAO games have lines containing {n} that also
need wrapping, so aao conversion needs to use _textbox_wrap true and
_textbox_wrap_avoid_controlled false.
- added "gui Input" command:
gui Input [variable_name] {x=} {y=} {z=} {name=} {width=width of box}
The input box will start pre filled with the value of the variable given
When the player types in the box, it will save the results back to that variable
later you can get what they entered by checking the value of the variable
- entering the court record during a press of a cross examine statement doesn't show the
present option
- set _layering_method stack to make the order of objects be based
on the time they were added
set _layering_method zorder (default) to make the order be based on
each objects z= value
- set _penalty_script [scriptname] {label} to define a place to go if a penalty
bar runs out. Label is optional. Example:
set _penalty_script penalty - Will run "penalty.txt" if any penalty bar
runs out
set _penalty_script intro fail - Will run "intro.txt" and jump to label "fail"
if a penalty bar runs out
- added a screenshot command:
screenshot [name] {width=} {height=} {x=} {y=} {rwidth=} {rheight=}
saves a screenshot as [name], make sure to include the .png or .jpg on the end
[name] is relative to the current game directory
if you put it in art/fg you can then show it in game
will resize to width and height if they are listed (they
must both be listed if one is)
if x, y, rwidth, and rheight are listed, this is the region of the screen that
will be in the screenshot
*PyWright 0.960: March 11, 2010*
- fix for combined sprite fading
- cached fades are refreshed if the source content changes
- some fading graphics crashed
- F7 to load worked but not clicking the button
- valid expression "is var1 AND var2 OR var3" to test truth of flags or variables
*PyWright Version 0.95: February 28, 2010*
Version 0.95 represents a couple months of extra effort poured into various aspects
of the engine. Of all of the versions I have made, I am most happy with this one. It
has the least amount of bugs ever, and the least amount of things that just bug me.
It is a combination of some reworked code, some thrown on features, and some just plain
tinkering and experimenting. Most of the changes have been made possible due to the
great feedback I've received from the community, along with feature suggestions, and
some real effort at beta testing. I think it has earned it's not-beta-any-longer status.
Enjoy!
-----------------------------------------------------
Textual changes:
* Automatic wrapping is based on words, so it's a more sane default setting. If {n} is
in the text, the autowrapper will shut off, as behavior gets complex to mix the two.
If {n} is not in the text, can still disable wrap by setting _textbox_wrap to false.
* Colors can be either the old style 3 digit color, or the new 6 digit color based on html
* Colors can be set based on a variable, use {c variable} to set the color the variable value
* textblocks can be colored with "color=[color]" where color is anything accepted by {c}
Positioning of textbox and nametag:
set _textbox_x, _textbox_y (default 0,0) to reposition the textbox (absolute values!)
set _textbox_bg to change the image
set _nt_image to use a different nametag image
note: if _nt_image is set the image is displayed even if the nametag is blank
this is so you can put text on a nametag image in your art program
and display it instead of letting the code write the name
set _nt_x, _nt_y to reposition the nametag image (absolute values!)
set _nt_text_x _nt_text_y to reposition nametag text (relative values)
set _nt_text_color to 3 digit or 6 digit color string to change the nametag color
Animation changes:
The animation speed of objects is now controllable
2 ways:
* In the .txt file along with your animation (something.png which may have something.txt)
add a command "globaldelay x", where x is the amount of frames to pause between
frame changes.
* with the command "globaldelay x name=y" where x is the amount of frames to pause
between frame changes, and y should be the name of an existing object. Without
name it will change everything!
The delay amount can be a decimal number, like 4.5
The delay will not affect animations which already use "framedelay" in their .txt file
to set individual delays for specific frames
Customize button look:
Buttons can now have a graphic, allowing much more freedom in custom gui design.
gui Button [label] x=[x] y=[y] graphic=[path/to/image]
Path to image is the path starting after the art folder, such as "fg/my_button"
or "general/somebutton"
Customize list menus:
Asside from the more accurate builtin checkmark and check placing, you can also
customize your lists a bit more.
- adjust checkmark (for options you've already tried) image by setting variable
_list_checked_img to path relative to art folder
- change background with _list_bg_image (default general/black)
Might want to adjust _menu_fade_level to 0 to see fully opaque image
- adjust checkmark position with variables _list_checked_x, _list_checked_y
relative to top left corner of option button
- color of text more accurate
- little known tip: color of list options can be set with {c462} syntax
Zoom command: to zoom into the screen or scale objects
Syntax:
zoom mag=[amount] frames=[number] [last] [nowait] {name=somename}
mag is the number of scaling levels to zoom. A mag of 2 means "add 2 scaling
levels to current scale". If current scale is 1, the final scale is 3x. Semantics of this
is likely to change.
frames is the number of frames for zoom to happen
last will only scale the last object
nowait to continue script while zooming.
name=somename will only scale the named object
Customize investigation menu:
A new command "localmenu" was added, allowing you to set up the
investigation menu manually, and letting you organize your scripts how you please.
The syntax is this:
localmenu examine=on/off talk=on/off present=on/off move=on/off
This will show a normal investigation menu with those items either on or off. All of the
options default to off, so
localmenu talk=on
will show a menu that only has the talk option. The options work with variables so
you can have code or what the player has done determine what is shown:
localmenu talk=$ema_here present=$ema_here move=on examine=on
will only show talk and present when $ema_here is equal to on.
When a user chooses one of the options in localmenu, instead of running a
separate script, it will jump to a label for "examine", "talk", "move", or "present". If
a localmenu is shown with every item set to off, it will skip the localmenu line.
Can turn OFF menu items from the regular menu command
menu scene examine=off
will show the menu, and leave examine out of the selectable items, even if scene.examine.txt
exists.
Label none workaround:
Frequently in medium to complex scripts, it becoms impossible for an interface, such
as a "present" or an "examine", to jump to a label past another section of code - because
it stops when it hits a "label none" that was meant for a different interface. Frequently
when this happens you have to resort to jumping to a middle part of the code and then
calling "goto" from there to actually get where you want. 0.95 lets you be absolutely
explicit about the behavior of interfaces and labels.
Simply add a "fail=x" to the end of the interface command, and it will consider "x"
to be where it stops searching, instead of "none".
Commands that support "fail=x" in their arguments:
goto*, showlist, menu, localmenu, cross, present, examine
*normally goto does NOT stop when it hits label none, but with fail= you can
give it that behavior.
Logic commands in 0.95 also support "fail=x" in order to tell it to jump to "x" when the
expression is false; rather than continuing on the next line.
Logic commands that support "fail=x" at the very end of the command:
flag, noflag, is, isnot
Advanced scripting changes:
Some builtin interfaces give a bit more feedback to scripts in the form of variables
that they set:
_examine_clickx, _examine_clicky are set to x and y after
clicking a spot in the examine screen;
_selected is set to the evidence id when running an evidence check script
Script command:
Made "script" command a bit more flexible. Can pass a label= argument to jump
to a label after loading the file. If [name].script.txt is not found, will look for
[name].txt. Also, the script command can be called safely from a running macro.
Copying variables dynamically:
Can copy the value of a variable into another. Allows using code to generate a
variable name to access. Allows processing lists of items, or selecting variables
for some reason or other. More complicated than other methods, but more flexible
as well.
syntax: getvar [destination variable] [namefragment] [namefragment]
All of the name fragments are joined together into one name. The value of whatever
variable that combined name refers to is copied into the destination variable.
Example:
getvar x rectangle_ $index .x
First, "rectangle_", the VALUE of $index, and ".x" are all joined into a single
variable name. If $index were equal to 0, this would be like "getvar my_x rectangle_0.x",
and whatever was stored in the rectangle_0.x variable would be copied into the "my_x"
variable.
Timers:
Added a timer command, like a stopwatch or a countdown. It's possible to run multiple timers
at once, and the value of each timer is saved to an independant variable. When the timer
runs to zero, a macro you specifiy is run. It could be used to give the player a time limit
to solve some piece of logic, where they get a penalty if they run out of time. It is also
useful for many other things. Consider a short timer to control some animation - when the
timer runs out, you move an object, and then start the timer again. It will keep moving the
object at those set intervals.
Syntax:
timer [ticks] [macroname]
The value of the timer (ticks left till macro is run) can be accessed
from $_timer_value_[macroname]
Updated updater:
Metadata support added for all content types. This data used to be stored in a file
called ".pwv" which came with content, such as the game, or the character; and it
used to be limited to only a version number.
With 0.95, the standard filename is data.txt. A data.txt file should always be
included in the root of your game folder. It's purpose is to tell potential players or
potential downloaders some more information about your game. If data.txt is not
included, your version will be assumed to be 0, and you won't have an icon, or title,
etc.
Each row of the file has a field name, a space, followed by the field data.
Currently supported/planned to be supported fields:
* version - Any floating point number is valid. If a higher number is
available on updater, it will let the user know that they
can update. Also multiple decimal places are supported.
example: 1.5.1
* version_date - the date this version was released - mm/dd/yyyy
* version_notes - info about what was changed in this version
* description - info about the game itself
* author - the name of the game creator. Displayed next to
title on the game list.
* title - the game name, displayed on the game list
* icon - path to an image to use as the game's icon, relative to the root
of the game folder; include file extension
(i.e., if icon equals "data/art/general/icon.png" there should be a
"games/my_game/art/general/icon.png" present)
should be 70x70
required for games on update service
* website - a link to the project website if there is one
* category - may be used to sort games later on
Metadata changes have allowed some modifications to the view of the
updater and the games list, especially the icon, to make choosing the right
game easier.
Beyond that, the updater is now more stable, able to resume downloads
(if you try and download something that halted in the middle again, it will
resume), and will attempt to extract
Reworked saving system. Very careful about what can be saved and what cannot.
Logic behind it is still to record the state of every object currently in memory to
a file, and then recreate it when loading, but method is different.
What cannot be saved:
- position in currently playing song
- movie objects are not saved (a load will resume after the "movie" command)
- position of text - when saved in the middle of a textbox printing out,
loading that game will make the textbox start printing out from
the begining again. This can make perceive saves imperfect.
- many macros running at once, and many timers running at once can be
saved but the behavior of loading may not be accurate
* Be aware of these limitations, you can control when it is allowed to save the game or
not by setting the _allow_saveload variable on or off. It might be a good idea to turn
it off before starting a movie for instance.
* Also remember that there is a command to force the game to save, it might be a good
idea to use this for checkpoints to control where saves occur. A save at the start
of each scene might work.
Regressions (changes that could be seen as downgrades):
* It's official - gif support on pywright is not "recommended". The code is not actually
gone, but it will not work on a mac, and never worked wll anyway.
Converter available: http://pywright.dawnsoft.org/gif2strip/index.cgi
* Automatic updates are disabled. Too dangerous. In a later release, there will
at least be notifications that a new version is available, but it will never force
the user to upgrade.
* Any time an image fades in, the fadeable image will be stored to core/cache.
This will speed up the fade animation on later runs. The downside, is it eats hard
drive space, and if you make a modification to a graphic file, it will rever to the
old version during the fade. Faster fading without the cache is a possibility
down the road.
-other random bug fixes/additions:
*scrolling objects on bottom screen works
*psyche5 macro included in chains to have 5 locks
*if "intro.txt" not found in a game, looks for "[game].txt" instead, if you would rather
name it that
*fixed court record buttons from investigation menu
___________________________________________________________________________________
___________________________________________________________________________________
Beta versions before 0.95 (RIP December 2007-December 2009):
PyWright Beta 10.94
- Some more fixes to hidden statements
- Fix to gui mouse event handler, next button sometimes hard to click (thanks StBacchus for helping
pinpoint this longstanding bug!)
- Add the "random" command to generate random numbers. "random x 1 10" will set x to a number
from 1 to 10.
- The underscore character in nametags/character names will translate into spaces when the
name is printed
- The nametag bar expands horizontally to fit the width of the nametag
(The 3 image files, nt_left, nt_middle, and nt_right in art/general control how each part of
the name bar looks. The nt_left controls the left corner, nt_middle is repeated along
the length of the bar, and nt_right is displayed on the right corner.)
You can add arbitrary spacing in the name (extra padding) by adding spaces at the beginning
or end of the nametag: char guy nametag=_______Guy_______" will have a longer
name bar.
- safety mode for resolution changes, will revert back after a few seconds if the change is not OK'ed
- fading does not corrupt the original image (fixes ever darkening lists)
- black fade in for lists and investigation buttons is back in single screen mode (and optionally in
double screen mode, if _double_screen_list_fade is true)
PyWright Beta 10.93
- Access the updater from within pywright itself on all platforms (previously this
was only on OSX. Updater.exe will be discontinued in a later full release)
- Added _default_port_frame_delay, and _default_fg_frame_delay, to enable control
of the default speed of these respective animations
- Fading works decently without opengl, opengl still disabled
- statements now have a "test=" optional argument, placed after the statement name
if you want to hide statements, put a flag or variable name after the "test=" and the
statement will only be visible if that flag or variable is true
- added a few other commands to aid cross examinations:
next_statement, prev_statement, and cross_restart
go to the next statement, previous statement, or beginning of the cross examination,
respectively. Next and prev to be used within cross/endcross, cross_restart typically
to be used after endcross.
- "*" text character displays correctly
- New variables to further customize presenting:
_profiles_enable to toggle profile viewing
_evidence_enable to toggle evidence viewing
_profiles_present to toggle profile presenting
_evidence_present to toggle evidence presenting
NOTE: these ALSO control court record, so set them back if you need to when you are done
But you can also, for instance, disable profiles for the entire game if you don't use them
- Fix evidence deleting on enter keypress bug
- court macros added newwitness, newprosecutor, newdefense, newjudge, and newhelper
to trigger a character switch in the middle of a court macro session (uses the same variables
as used in court setup)
PyWright Beta 10.92 - hotfix
- Altered case title display slightly to fix some instances of cutoff
- emo command doesn't alter nametags
- "script newscript noclear" to run a new script without clearing the screen
- intro.txt from a game directory doesn't kill PyWright when it ends
- Double screen examine no longer broken
- added "loops" argument to the fg command, to control how many times fg animations loop from code
- can set the position of "gui Back" with "gui Back x=0 y=351 (note that y=351 will put it on the
bottom of the 2nd screen)
PyWright Beta 10.91
Fixes:
- Saves the current frame of fg animations - fixes a bug where loading a game would make
all of the hold it and objection animations show again (only fixes new saves)
- Supports ä ö ü and other international characters through the PWinternational font
(thanks to AAO for this) You'll have to wait for b11 for more control over fonts.
- Don't crash when trying to load and no save exists!
- Restored games that use the looping music feature will no longer get stuck looping the intro
- Saved games no longer save the state of the court record, solving some bugs with this
- Viewed list entries no longer have multiple sets of parenthesis
- Some keyboard issues fixed (couldnt interact with court-record displayed during
a list)
- Better able to handle multiple cross examinations in one file
- Macros defined in your game directory or in a script will override any built in macros
If you copy core/macros/court.mcro into your game directory and alter it,
the changes will be reflected in your game.
DO NOT MODIFY core/macros/* DIRECTLY!
Always copy the .mcro file you want to modify into your game or case
directory, and modify that copy. The reason for this is that updates to
pywright may modify those files, and wipe out any modifications you had made.
Also, when you distribute the game to someone elses pywright installation,
they wouldn't have the modification you made in yours.
- Opengl mode discontinued - weird graphical bugs in default viewmode are gone
Too difficult to maintain with very little payoff
Beta11 is written to better make use of opengl, but it's prohibitive to bring
these changes to beta10 series
Improvements:
- New variables _allow_click_load and _allow_click_save to enable/disable clicking of
the save/load buttons - best if used with custom court record button that doesnt
have those icons.
_allow_saveload can also be used to disable the save/load hotkeys along with the
buttons
- New variables _allow_present_evidence, _allow_present_profiles, and
[evidence_id]_presentable to change when court record items are
allowed to be presented
- Court macros now start one screen to the left of defense, so that it will
be black to begin with. The first command to go to a screen will then
be the first screen the player sees.
Also, the startcourt macro doesn't clear the existing screen. This is to allow you
to place objects to the left of the wide court before running the macro, if you want to
show things right before a court scene. Beware to clear the screen before running
startcourt, if you need to
- Set _list_checked_img to the path to a checkmark image. This will be displayed on lists
to show which items the player has already seen instead of the parenthesis.
- "forgetlist" command to forget that a player has chosen items from that list
- "forgetlistitem" command to forget a specific chosen item within a list
Tweaks:
- A bit more class with the save/load game messages
- Longer case names look less bad on case selection screen
- Slightly more PW styled list selection box
- left arrow hidden on first statement of a cross examination
- Added debug message in labels if the label doesn't exist
PyWright Beta 10.9
- Added a "print" command to print debug information to the log file.
- Debug error messages are no longer clipped (the whole message is visible)
- Added "framedelay" command in sprite text files to assign extra delay to specific frames in an animation
- its possible to skip the update check on program start by clicking anywhere
- Three new commands to deal with saves: savegame, loadgame, deletegame - check the doc and example
- Control over case order on case selection screen, also which cases are
shown:
* 'set _order_cases alphabetical' to use the default order
* 'set _order_cases variable' to only show cases that are assigned
to variables:
* in variable ordering, 'set _case_1 Turnabout Something'
'set _case_2 aaaa'
First case and second case will appear as shown, other cases
will be hidden
- Add save all variables option to exportvars
- Added a variable to control text skipping, independant from _debug mode -
"set _textbox_allow_skip true"
- move court record button to second screen when second screen is available
- Added two debug properties which stop hard-coded interfaces from pausing the game:
"set _textbox_skipupdate false" will make the script continue while a textbox is still printing text
"set _examine_skipupdate false" will make the script continue after an examine interface is shown
You can then use the "gui Wait" command to halt script execution where you want to.
- able to choose whether to hide bars on an examine with "set _examine_showbars false"
(can be toggled while an examine is shown as well)
- able to choose whether to hide the cursor on an examine with "set _examine_showcursor false"
(can be toggled while an examine is shown as well)
- Above modifications allow more custom interfaces, such as perceive
see the perceive example in games/beta10.9, which you can download through updater
- cross examination shows a back arrow as well as forward
PyWright Beta 10.86
- Added an exportvars and importvars function to write the value of variables to a file or read them in
Can use this to, for instance, record that the player has completed a case.
- Customization of case selection screen: place a file "case_screen.txt" inside of a case
When selected on the case menu, this script will be executed, allowing you to have custom
backgrounds for each case. Using the exportvars/importvars, and some extra logic in the case_screen
file, it is possible to show a different background when the case is completed.
- After a cross examination, testimony blinking object is deleted
It can also be deleted manually with the in-text command {tboff}
Or added manually with the in-text command {tbon}
- Green testimony only colors the text green, not the nametag
- Present command doesn't make pywright think a cross examination is occuring
- save/load buttons are clickable
- scroll command clamps at the endpoint of the scroll so that objects never go past where they should
- Add some loading dialogs for choosing a game, loading a case
- Add helper to court record (Thanks Brawldud!)
Also added some variables to rename the court characters:
judge_nt, prosecutor_nt, helper_nt,defense_nt, and witness_nt
Set those variables to the name you want to show up for that person
when using the court.mcro functions defined in core/court.mcro
- Saved game improvements: character positions, name of who is talking, what
text you have already seen so you can skip through it
- Engine auto-update updates more functions without having to restart the engine
- Tab brings up court record again
PyWright Beta 10.85
- Disabled certain keys in editor which inserted junk into the text
- Added Gotcha balloon
macro: {shout gotcha apollo}
just the image: fg GotchaAnim
- Make looping tracks work
- Court record graphics can be customized: see core/court_record_vars.txt
- can show a court record without a back button (forced present)
set _cr_back_button false
- Cannot press space to back out of hidden examine screen (examine hide)
- can change the graphic used for the continue button arrow
set _bigbutton_img "general/buttonpress.png"
(search _bugbutton_img in doc.txt for full help)
- added a command "emo" to set the emotion of characters with a bit
more freedom. See emo in doc.txt.
- most objects are added with a sane default name that can be referenced
for deleting or other commands that take names (char phoenix can
be referenced as phoenix). This only is a problem if you have for
instance char phoenix, and ev phoenix at the same time, in which case
you will still need to use name= manually to differentiate them.
- movies can be played with sound if a separate sound file is provided
- Added draw_on and draw_off commands to control rendering issues!
(ported from beta11)
Call draw_off before changing stuff around, then call draw_on again when done
- looping tracks from http://studio-amaterasu.com/storage/pwmusic/ work
command is:
mus introfile
set _music_loop loopfile
Thanks to maelstrom!
PyWright Beta 10.84
- Taller textbox to make text less squished
PyWright Beta 10.82-83
- Menu can load without a bg
- Again with the evil crashing music
- {next} in a dialog resets the profile to blink in case the next
message is from a diffferent speaker
- The right side of double-sided scenes is now clickable in single screen
display mode.
- Backgrounds actually overwrite things like they are supposed to
- Disable court record display while examining (the CR and examine
menu's conflict with each other)
PyWright Beta 10.78-81 (Turnabout Substitution Fixes)
- Fix for game crashing if music is broken
- Disable multiple evidence screens
- Save and Restore are functional again
- If there is a problem with the save, it won't
overwrite the old save, so you are free to save
often
- (beta 10.81 fixed save in software mode)
- Save/load/court record is available on more menus
PyWright Beta 10.76-77