Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |
00001 00002 00003 00004 00005 00006 00007 00008 00009 00010 00011 00012 00013 00014 00015 00016 00017 00018 00019 00020 00021 00022 00023 00024 00025 00026 00027 00028 00029 00030 00031 00032 00033 00034 00035 00036 00037 00038 00039 00040 00041 00042 00043 00044 00045 00046 00047 00048 00049 00050 00051 00052 00053 00054 00055 00056 00057 00058 00059 00060 00061 00062 00063 00064 00065 00066 00067 00068 00069 00070 00071 00072 00073 00074 00075 00076 00077 00078 00079 00080 00081 00082 00083 00084 00085 00086 00087 00088 00089 00090 00091 00092 00093 00094 00095 00096 00097 00098 00099 00100 00101 00102 00103 00104 00105 00106 00107 00108 00109 00110 00111 00112 00113 00114 00115 00116 00117 00118 00119 00120 00121 00122 00123 00124 00125 00126 00127 00128 00129 00130 00131 00132 00133 00134 00135 00136 00137 00138 00139 00140 00141 00142 00143 00144 00145 00146 00147 00148 00149 00150 00151 00152 00153 00154 00155 00156 00157 00158 00159 00160 00161 00162 00163 00164 00165 00166 00167 00168 00169 00170 00171 00172 00173 00174 00175 00176 00177 00178 00179 00180 00181 00182 00183 00184 00185 00186 00187 00188 00189 00190 00191 00192 00193 00194 00195 00196 00197 00198 00199 00200 00201 00202 00203 00204 00205 00206 00207 00208 00209 00210 00211 00212 00213 00214 00215 00216 00217 00218 00219 00220 00221 00222 00223 00224 00225 00226 00227 00228 00229 00230 00231 00232 00233 00234 00235 00236 00237 00238 00239 00240 00241 00242 00243 00244 00245 00246 00247 00248 00249 00250 00251 00252 00253 00254 00255 00256 00257 00258 00259 00260 00261 00262 00263 00264 00265 00266 00267 00268 00269 00270 00271 00272 00273 00274 00275 00276 00277 00278 00279 00280 00281 00282 00283 00284 00285 00286 00287 00288 00289 00290 00291 00292 00293 00294 00295 00296 00297 00298 00299 00300 00301 00302 00303 00304 00305 00306 00307 00308 00309 00310 00311 00312 00313 00314 00315 00316 00317 00318 00319 00320 00321 00322 00323 00324 00325 00326 00327 00328 00329 00330 00331 00332 00333 00334 00335 00336 00337 00338 00339 00340 00341 00342 00343 00344 00345 00346 00347 00348 00349 00350 00351 00352 00353 00354 00355 00356 00357 00358 00359 00360 00361 00362 00363 00364 00365 00366 00367 00368 00369 00370 00371 00372 00373 00374 00375 00376 00377 00378 00379 00380 00381 00382 00383 00384 00385 00386 00387 00388 00389 00390 00391 00392 00393 00394 00395 00396 00397 00398 00399 00400 00401 00402 00403 00404 00405 00406 00407 00408 00409 00410 00411 00412 00413 00414 00415 00416 00417 00418 00419 00420 00421 00422 00423 00424 00425 00426 00427 00428 00429 00430 00431 00432 00433 00434 00435 00436 00437 00438 00439 00440 00441 00442 00443 00444 00445 00446 00447 00448 00449 00450 00451 00452 00453 00454 00455 00456 00457 00458 00459 00460 00461 00462 00463 00464 00465 00466 00467 00468 00469 00470 00471 00472 00473 00474 00475 00476 00477 00478 00479 00480 00481 00482 00483 00484 00485 00486 00487 00488 00489 00490 00491 00492 00493 00494 00495 00496 00497 00498 00499 00500 00501 00502 00503 00504 00505 00506 00507 00508 00509 00510 00511 00512 00513 00514 00515 00516 00517 00518 00519 00520 00521 00522 00523 00524 00525 00526 00527 00528 00529 00530 00531 00532 00533 00534 00535 00536 00537 00538 00539 00540 00541 00542 00543 00544 00545 00546 00547 00548 00549 00550 00551 00552 00553 00554 00555 00556 00557 00558 00559 00560 00561 00562 00563 00564 00565 00566 00567 00568 00569 00570 00571 00572 00573 00574 00575 00576 00577 00578 00579 00580 00581 00582 00583 00584 00585 00586 00587 00588 00589 00590 00591 00592 00593 00594 00595 00596 00597 00598 00599 00600 00601 00602 00603 00604 00605 00606 00607 00608 00609 00610 00611 00612 00613 00614 00615 00616 00617 00618 00619 00620 00621 00622 00623 00624 00625 00626 00627 00628 00629 00630 00631 00632 00633 00634 00635 00636 00637 00638 00639 00640 00641 00642 00643 00644 00645 00646 00647 00648 00649 00650 00651 00652 00653 00654 00655 00656 00657 00658 00659 00660 00661 00662 00663 00664 00665 00666 00667 00668 00669 00670 00671 00672 00673 00674 00675 00676 00677 00678 00679 00680 00681 00682 00683 00684 00685 00686 00687 00688 00689 00690 00691 00692 00693 00694 00695 00696 00697 00698 00699 00700 00701 00702 00703 00704 00705 00706 00707 00708 00709 00710 00711 00712 00713 00714 00715 00716 00717 00718 00719 00720 00721 00722 00723 00724 00725 00726 00727 00728 00729 00730 00731 00732 00733 00734 00735 00736 00737 00738 00739 00740 00741 00742 00743 00744 00745 00746 00747 00748 00749 00750 00751 00752 00753 00754 00755 00756 00757 00758 00759 00760 00761 00762 00763 00764 00765 00766 00767 00768 00769 00770 00771 00772 00773 00774 00775 00776 00777 00778 00779 00780 00781 00782 00783 00784 00785 00786 00787 00788 00789 00790 00791 00792 00793 00794 00795 00796 00797 00798 00799 00800 00801 00802 00803 00804 00805 00806 00807 00808 00809 00810 00811 00812 00813 00814 00815 00816 00817 00818 00819 00820 00821 00822 00823 00824 00825 00826 00827 00828 00829 00830 00831 00832 00833 00834 00835 00836 00837 00838 00839 00840 00841 00842 00843 00844 00845 00846 00847 00848 00849 00850 00851 00852 00853 00854 00855 00856 00857 00858 00859 00860 00861 00862 00863 00864 00865 00866 00867 00868 00869 00870 00871 00872 00873 00874 00875 00876 00877 00878 00879 00880 00881 00882 00883 00884 00885 00886 00887 00888 00889 00890 00891 00892 00893 00894 00895 00896 00897 00898 00899 00900 00901 00902 00903 00904 00905 00906 00907 00908 00909 00910 00911 00912 00913 00914 00915 00916 00917 00918 00919 00920 00921 00922 00923 00924 00925 00926 00927 00928 00929 00930 00931 00932 00933 00934 00935 00936 00937 00938 00939 00940 00941 00942 00943 00944 00945 00946 00947 00948 00949 00950 00951 00952 00953 00954 00955 00956 00957 00958 00959 00960 00961 00962 00963 00964 00965 00966 00967 00968 00969 00970 00971 00972 00973 00974 00975 00976 00977 00978 00979 00980 00981 00982 00983 00984 00985 00986 00987 00988 00989 00990 00991 00992 00993 00994 00995 00996 00997 00998 00999 01000 01001 01002 01003 01004 01005 01006 01007 01008 01009 01010 01011 01012 01013 01014 01015 01016 01017 01018 01019 01020 01021 01022 01023 01024 01025 01026 01027 01028 01029 01030 01031 01032 01033 01034 01035 01036 01037 01038 01039 01040 01041 01042 01043 01044 01045 01046 01047 01048 01049 01050 01051 01052 01053 01054 01055 01056 01057 01058 01059 01060 01061 01062 01063 01064 01065 01066 01067 01068 01069 01070 01071 01072 01073 01074 01075 01076 01077 01078 01079 01080 01081 01082 01083 01084 01085 01086 01087 01088 01089 01090 01091 01092 01093 01094 01095 01096 01097 01098 01099 01100 01101 01102 01103 01104 01105 01106 01107 01108 01109 01110 01111 01112 01113 01114 01115 01116 01117 01118 01119 01120 01121 01122 01123 01124 01125 01126 01127 01128 01129 01130 01131 01132 01133 01134 01135 01136 01137 01138 01139 01140 01141 01142 01143 01144 01145 01146 01147 01148 01149 01150 01151 01152 01153 01154 01155 01156 01157 01158 01159 01160 01161 01162 01163 01164 01165 01166 01167 01168 01169 01170 01171 01172 01173 01174 01175 01176 01177 01178 01179 01180 01181 01182 01183 01184 01185 01186 01187 01188 01189 01190 01191 01192 01193 01194 01195 01196 01197 01198 01199 01200 01201 01202 01203 01204 01205 01206 01207 01208 01209 01210 01211 01212 01213 01214 01215 01216 01217 01218 01219 01220 01221 01222 01223 01224 01225 01226 01227 01228 01229 01230 01231 01232 01233 01234 01235 01236 01237 01238 01239 01240 01241 01242 01243 01244 01245 01246 01247 01248 01249 01250 01251 01252 01253 01254 01255 01256 01257 01258 01259 01260 01261 01262 01263 01264 01265 01266 01267 01268 01269 01270 01271 01272 01273 01274 01275 01276 01277 01278 01279 01280 01281 01282 01283 01284 01285 01286 01287 01288 01289 01290 01291 01292 01293 01294 01295 01296 01297 01298 01299 01300 01301 01302 01303 01304 01305 01306 01307 01308 01309 01310 01311 01312 01313 01314 01315 01316 01317 01318 01319 01320 01321 01322 01323 01324 01325 01326 01327 01328 01329 01330 01331 01332 01333 01334 01335 01336 01337 01338 01339 01340 01341 01342 01343 01344 01345 01346 01347 01348 01349 01350 01351 01352 01353 01354 01355 01356 01357 01358 01359 01360 01361 01362 01363 01364 01365 01366 01367 01368 01369 01370 01371 01372 01373 01374 01375 01376 01377 01378 01379 01380 01381 01382 01383 01384 01385 01386 01387 01388 01389 01390 01391 01392 01393 01394 01395 01396 01397 01398 01399 01400 01401 01402 01403 01404 01405 01406 01407 01408 01409 01410 01411 01412 01413 01414 01415 01416 01417 01418 01419 01420 01421 01422 01423 01424 01425 01426 01427 01428 01429 01430 01431 01432 01433 01434 01435 01436 01437 01438 01439 01440 01441 01442 01443 01444 01445 01446 01447 01448 01449 01450 01451 01452 01453 01454 01455 01456 01457 01458 01459 01460 01461 01462 01463 01464 01465 01466 01467 01468 01469 01470 01471 01472 01473 01474 01475 01476 01477 01478 01479 01480 01481 01482 01483 01484 01485 01486 01487 01488 01489 01490 01491 01492 01493 01494 01495 01496 01497 01498 01499 01500 01501 01502 01503 01504 01505 01506 01507 01508 01509 01510 01511 01512 01513 01514 01515 01516 01517 01518 01519 01520 01521 01522 01523 01524 01525 01526 01527 01528 01529 01530 01531 01532 01533 01534 01535 01536 01537 01538 01539 01540 01541 01542 01543 01544 01545 01546 01547 01548 01549 01550 01551 01552 01553 01554 01555 01556 01557 01558 01559 01560 01561 01562 01563 01564 01565 01566 01567 01568 01569 01570 01571 01572 01573 01574 01575 01576 01577 01578 01579 01580 01581 01582 01583 01584 01585 01586 01587 01588 01589 01590 01591 01592 01593 01594 01595 01596 01597 01598 01599 01600 01601 01602 01603 01604 01605 01606 01607 01608 01609 01610 01611 01612 01613 01614 01615 01616 01617 01618 01619 01620 01621 01622 01623 01624 01625 01626 01627 01628 01629 01630 01631 01632 01633 01634 01635 01636 01637 01638 01639 01640 01641 01642 01643 01644 01645 01646 01647 01648 01649 01650 01651 01652 01653 01654 01655 01656 01657 01658 01659 01660 01661 01662 01663 01664 01665 01666 01667 01668 01669 01670 01671 01672 01673 01674 01675 01676 01677 01678 01679 01680 01681 01682 01683 01684 01685 01686 01687 01688 01689 01690 01691 01692 01693 01694 01695 01696 01697 01698 01699 01700 01701 01702 01703 01704 01705 01706 01707 01708 01709 01710 01711 01712 01713 01714 01715 01716 01717 01718 01719 01720 01721 01722 01723 01724 01725 01726 01727 01728 01729 01730 01731 01732 01733 01734 01735 01736 01737 01738 01739 01740 01741 01742 01743 01744 01745 01746 01747 01748 01749 01750 01751 01752 01753 01754 01755 01756 01757 01758 01759 01760 01761 01762 01763 01764 01765 01766 01767 01768 01769 01770 01771 01772 01773 01774 01775 01776 01777 01778 01779 01780 01781 01782 01783 01784 01785 01786 01787 01788 01789 01790 01791 01792 01793 01794 01795 01796 01797 01798 01799 01800 01801 01802 01803 01804 01805 01806 01807 01808 01809 01810 01811 01812 01813 01814 01815 01816 01817 01818 01819 01820 01821 01822 01823 01824 01825 01826 01827 01828 01829 01830 01831 01832 01833 01834 01835 01836 01837 01838 01839 01840 01841 01842 01843 01844 01845 01846 01847 01848 01849 01850 01851 01852 01853 01854 01855 01856 01857 01858 01859 01860 01861 01862 01863 01864 01865 01866 01867 01868 01869 01870 01871 01872 01873 01874 01875 01876 01877 01878 01879 01880 01881 01882 01883 01884 01885 01886 01887 01888 01889 01890 01891 01892 01893 01894 01895 01896 01897 01898 01899 01900 01901 01902 01903 01904 01905 01906 01907 01908 01909 01910 01911 01912 01913 01914 01915 01916 01917 01918 01919 01920 01921 01922 01923 01924 01925 01926 01927 01928 01929 01930 01931 01932 01933 01934 01935 01936 01937 01938 01939 01940 01941 01942 01943 01944 01945 01946 01947 01948 01949 01950 01951 01952 01953 01954 01955 01956 01957 01958 01959 01960 01961 01962 01963 01964 01965 01966 01967 01968 01969 01970 01971 01972 01973 01974 01975 01976 01977 01978 01979 01980 01981 01982 01983 01984 01985 01986 01987 01988 01989 01990 01991 01992 01993 01994 01995 01996 01997 01998 01999 02000 02001 02002 02003 02004 02005 02006 02007 02008 02009 02010 02011 02012 02013 02014 02015 02016 02017 02018 02019 02020 02021 02022 02023 02024 02025 02026 02027 02028 02029 02030 02031 02032 02033 02034 02035 02036 02037 02038 02039 02040 02041 02042 02043 02044 02045 02046 02047 02048 02049 02050 02051 02052 02053 02054 02055 02056 02057 02058 02059 02060 02061 02062 02063 02064 02065 02066 02067 02068 02069 02070 02071 02072 02073 02074 02075 02076 02077 02078 02079 02080 02081 02082 02083 02084 02085 02086 02087 02088 02089 02090 02091 02092 02093 02094 02095 02096 02097 02098 02099 02100 02101 02102 02103 02104 02105 02106 02107 02108 02109 02110 02111 02112 02113 02114 02115 02116 02117 02118 02119 02120 02121 02122 02123 02124 02125 02126 02127 02128 02129 02130 02131 02132 02133 02134 02135 02136 02137 02138 02139 02140 02141 02142 02143 02144 02145 02146 02147 02148 02149 02150 02151 02152 02153 02154 02155 02156 02157 02158 02159 02160 02161 02162 02163 02164 02165 02166 02167 02168 02169 02170 02171 02172 02173 02174 02175 02176 02177 02178 02179 02180 02181 02182 02183 02184 02185 02186 02187 02188 02189 02190 02191 02192 02193 02194 02195 02196 02197 02198 02199 02200 02201 02202 02203 02204 02205 02206 02207 02208 02209 02210 02211 02212 02213 02214 02215 02216 02217 02218 02219 02220 02221 02222 02223 02224 02225 02226 02227 02228 02229 02230 02231 02232 02233 02234 02235 02236 02237 02238 02239 02240 02241 02242 02243 02244 02245 02246 02247 02248 02249 02250 02251 02252 02253 02254 02255 02256 02257 02258 02259 02260 02261 02262 02263 02264 02265 02266 02267 02268 02269 02270 02271 02272 02273 02274 02275 02276 02277 02278 02279 02280 02281 02282 02283 02284 02285 02286 02287 02288 02289 02290 02291 02292 02293 02294 02295 02296 02297 02298 02299 02300 02301 02302 02303 02304 02305 02306 02307 02308 02309 02310 02311 02312 02313 02314 02315 02316 02317 02318 02319 02320 02321 02322 02323 02324 02325 02326 02327 02328 02329 02330 02331 02332 02333 02334 02335 02336 02337 02338 02339 02340 02341 02342 02343 02344 02345 02346 02347 02348 02349 02350 02351 02352 02353 02354 02355 02356 02357 02358 02359 02360 02361 02362 02363 02364 02365 02366 02367 02368 02369 02370 02371 02372 02373 02374 02375 02376 02377 02378 02379 02380 02381 02382 02383 02384 02385 02386 02387 02388 02389 02390 02391 02392 02393 02394 02395 02396 02397 02398 02399 02400 02401 02402 02403 02404 02405 02406 02407 02408 02409 02410 02411 02412 02413 02414 02415 02416 02417 02418 02419 02420 02421 02422 02423 02424 02425 02426 02427 02428 02429 02430 02431 02432 02433 02434 02435 02436 02437 02438 02439 02440 02441 02442 02443 02444 02445 02446 02447 02448 02449 02450 02451 02452 02453 02454 02455 02456 02457 02458 02459 02460 02461 02462 02463 02464 02465 02466 02467 02468 02469 02470 02471 02472 02473 02474 02475 02476 02477 02478 02479 02480 02481 02482 02483 02484 02485 02486 02487 02488 02489 02490 02491 02492 02493 02494 02495 02496 02497 02498 02499 02500 02501 02502 02503 02504 02505 02506 02507 02508 02509 02510 02511 02512 02513 02514 02515 02516 02517 02518 02519 02520 02521 02522 02523 02524 02525 02526 02527 02528 02529 02530 02531 02532 02533 02534 02535 02536 02537 02538 02539 02540 02541 02542 02543 02544 02545 02546 02547 02548 02549 02550 02551 02552 02553 02554 02555 02556 02557 02558 02559 02560 02561 02562 02563 02564 02565 02566 02567 02568 02569 02570 02571 02572 02573 02574 02575 02576 02577 02578 02579 02580 02581 02582 02583 02584 02585 02586 02587 02588 02589 02590 02591 02592 02593 02594 02595 02596 02597 02598 02599 02600 02601 02602 02603 02604 02605 02606 02607 02608 02609 02610 02611 02612 02613 02614 02615 02616 02617 02618 02619 02620 02621 02622 02623 02624 02625 02626 02627 02628 02629 02630 02631 02632 02633 02634 02635 02636 02637 02638 02639 02640 02641 02642 02643 02644 02645 02646 02647 02648 02649 02650 02651 02652 02653 02654 02655 02656 02657 02658 02659 02660 02661 02662 02663 02664 02665 02666 02667 02668 02669 02670 02671 02672 02673 02674 02675 02676 02677 02678 02679 02680 02681 02682 02683 02684 02685 02686 02687 |
//============================================================================= // Actor: The base class of all actors. // Actor is the base class of all gameplay objects. // A large number of properties, behaviors and interfaces are implemented in Actor, including: // // - Display // - Animation // - Physics and world interaction // - Making sounds // - Networking properties // - Actor creation and destruction // - Triggering and timers // - Actor iterator functions // - Message broadcasting // // This is a built-in Unreal class and it shouldn't be modified. //============================================================================= class Actor extends Object abstract native nativereplication; // Imported data (during full rebuild). #exec Texture Import File=Textures\S_Actor.pcx Name=S_Actor Mips=Off MASKED=1 //NEW (arl) exposed TraceFlags to UnrealScript //COM (mdf) engine should really go off of these instead, but there are 200+ places... //IF YOU CHANGE THESE ADD A CHECK TO ULevel::ULevel (see: traceflag sanity checks) // Bitflags. const TRACE_Pawns = 0x0001; // Check collision with pawns. const TRACE_Movers = 0x0002; // Check collision with movers. const TRACE_Level = 0x0004; // Check collision with BSP level geometry. const TRACE_Volumes = 0x0008; // Check collision with soft volume boundaries. const TRACE_Others = 0x0010; // Check collision with all other kinds of actors. const TRACE_OnlyProjActor = 0x0020; // Check collision with other actors only if they are projectile targets const TRACE_Blocking = 0x0040; // Check collision with other actors only if they block the check actor const TRACE_LevelGeometry = 0x0080; // Check collision with other actors which are static level geometry const TRACE_ShadowCast = 0x0100; // Check collision with shadow casting actors const TRACE_StopAtFirstHit = 0x0200; // stop as soon as something is hit (useful for can see type traces) const TRACE_SingleResult = 0x0400; // Stop when find guaranteed first nearest collision (for SingleLineCheck) const TRACE_Debug = 0x0800; // used for debugging specific traces const TRACE_Material = 0x1000; // Request that Hit.Material return the material the trace hit. const TRACE_VisibleNonColliding = 0x2000; //NEW: include visible but not normally hit actors (see IncludeInVisibleNonCollidingTraces) const TRACE_Usable = 0x4000; //NEW: all visible or usable actors (see bHiddenUsable) // Combinations. const TRACE_Actors = 0x0093; // TRACE_Pawns | TRACE_Movers | TRACE_Others | TRACE_LevelGeometry, const TRACE_AllColliding = 0x009F; // TRACE_Level | TRACE_Actors | TRACE_Volumes, const TRACE_ProjTargets = 0x00BF; // TRACE_OnlyProjActor | TRACE_AllColliding, const TRACE_AllBlocking = 0x00DF; // TRACE_Blocking | TRACE_AllColliding, const TRACE_World = 0x0086; // TRACE_Level | TRACE_Movers | TRACE_LevelGeometry, const TRACE_Hash = 0x009B; // TRACE_Pawns | TRACE_Movers | TRACE_Volumes | TRACE_Others | TRACE_LevelGeometry, //OLD const CCFloatHeight = 6.0; //NEW (mdf) !!mdf-tbd: it would be nice if we could get rid of this (CC's floating by different amounts on different geometry) const DefaultPathingCollisionRadius = 50.0; //NEW (mdf) const DefaultPathingCollisionHeight = 50.0; //NEW (mdf) //NEW (mdf) // Doesn't really belong here but accessing this through Pawn.xxx is a pain // because Controllers have a Pawn property... const ST_None = 0; const ST_Standing = 1; const ST_Crouching = 2; const ST_Prone = 3; //OLD //NEW (mdf) serpentine support (here to get around circular dependency problem) enum ETacticalMoveType { TMT_None, // no strafing -- NPC will move directly towards destination TMT_Basic, // old (pre-serpentine) tactical moves (calls UpdateTactics) TMT_Serpentine, // serpentine strafing while moving towards destination }; //OLD //NEW (mwp) P4 optimizations //----------------------------------------------------------------------------- // Lighting. // Light modulation. var(Lighting) enum ELightType { LT_None, LT_Steady, LT_Pulse, LT_Blink, LT_Flicker, LT_Strobe, LT_Scripted, //NEW (arl) Only valid for ScriptedLight Actors. LT_BackdropLight, LT_SubtlePulse, LT_TexturePaletteOnce, LT_TexturePaletteLoop , LT_PawnProximity //NEW (arl) Scales LightBrightness based on distance to closest pawn. (Interpolated from CollisionRadius to CollisionHeight). } LightType; // Spatial light effect to use. var(Lighting) enum ELightEffect { LE_None, LE_TorchWaver, LE_FireWaver, LE_WateryShimmer, LE_Searchlight, LE_SlowWave, LE_FastWave, LE_CloudCast, LE_StaticSpot, LE_Shock, LE_Disco, LE_Warp, LE_Spotlight, LE_NonIncidence, LE_Shell, LE_OmniBumpMap, LE_Interference, LE_Cylinder, LE_Rotor, LE_Spotlight2, //NEW (arl) Non-incident spotlight. LE_SquareSpotlight, //NEW (arl) Square non-incident spotlight. LE_Unused, LE_Sunlight, LE_QuadraticNonIncidence } LightEffect; // Lighting info. var(LightColor) byte LightBrightness, LightHue, LightSaturation; // Light properties. var(Lighting) byte LightRadius, LightPeriod, LightPhase, LightCone, VolumeBrightness, VolumeRadius, VolumeFog; // Priority Parameters // Actor's current physics mode. var(Movement) const enum EPhysics { PHYS_None, // 0 PHYS_Walking, // 1 PHYS_Falling, // 2 PHYS_Swimming, // 3 PHYS_Flying, // 4 PHYS_Rotating, // 5 PHYS_Projectile, // 6 PHYS_Interpolating, // 7 PHYS_MovingBrush, // 8 PHYS_Spider, // 9 PHYS_Trailer, // 10 PHYS_Ladder, // 11 PHYS_RootMotion, // 12 PHYS_Swinging, // 13 //NEW (arl) PHYS_Karma, // 14 PHYS_KarmaRagDoll // 15 } Physics; // Drawing effect. var(Display) const enum EDrawType { DT_None, DT_Sprite, DT_Mesh, DT_Brush, DT_RopeSprite, DT_VerticalSprite, DT_Terraform, DT_SpriteAnimOnce, DT_Custom, //NEW (arl) ParticleSystems DT_StaticMesh, DT_DrawType, DT_Particle, DT_AntiPortal, DT_FluidSurface // NEW JAG FLUID 29/09/2002 } DrawType; var(Display) StaticMesh StaticMesh; // StaticMesh if DrawType=DT_StaticMesh // Owner. var const Actor Owner; // Owner actor. var const Actor Base; // Actor we're standing on. struct ActorRenderDataPtr { var int Ptr; }; struct LightRenderDataPtr { var int Ptr; }; var const native ActorRenderDataPtr ActorRenderData; var const native LightRenderDataPtr LightRenderData; var const native int RenderRevision; enum EFilterState { FS_Maybe, FS_Yes, FS_No }; var native EFilterState StaticFilterState; struct BatchReference { var int BatchIndex, ElementIndex; }; var const native array<BatchReference> StaticSectionBatches; // Lighting. var(Lighting) bool bSpecialLit; // Only affects special-lit surfaces. var(Lighting) bool bActorShadows; // Light casts actor shadows. var(Lighting) bool bCorona; // Light uses Skin as a corona. var(Lighting) bool bLensFlare; // Whether to use zone lens flare. var(Display) bool bUseDynamicLights; //NEW (mwp) UT2K3 var transient bool bLightChanged; // Recalculate this light's lighting now. //OLD // Flags. //NEW (mwp) var(Advanced) const bool bStatic; // Does not move or change over time. Don't let L.D.s change this - screws up net play //var const bool bStatic; // Does not move or change over time. //OLD var(Advanced) bool bHidden; // Is hidden during gameplay. var(Advanced) bool bHiddenRelevant; //NEW (mjl) should relevant this actor even though it is bHidden, (for non-bAlwaysRelevant, bHidden actors) var(Advanced) bool bHiddenUsable; //NEW (mib) invisible usable actors that should get traced by the use mgr //NOTE: All hidden usable actors should set this flag whenever their useability changes //NEW (arl) particle render var(Advanced) bool bRenderLater; // actor should be rendered/ticked *after* normal actors have been ticked/rendered, so it can use the result of their render-generated information var(Advanced) bool bRequiresWorldZBuffer;//Actor should be drawn before the Z buffer has been cleared (before the weapon has been drawn) var(Advanced) bool bManualTick; // only used by particle systems to monitor ownership of tickage //OLD var(Advanced) const bool bNoDelete; // Cannot be deleted during play. var bool bAnimFinished; // Unlooped animation sequence has finished. var bool bAnimByOwner; // Animation dictated by owner. var const bool bAnimNoExist; //NEW (mjl) used so that animations which don't exist will still call FinishAnim one tick later. var bool bAnimLoopFinished; //NEW (mdf) used in engine with FinishAnim(false) to signal end of a loop without stopping it. //!!CDH: move into SimAnim? var(Advanced) const bool bDeleteMe; // About to be deleted. var transient const bool bTicked; // Actor has been updated. var(Lighting) bool bDynamicLight; // Temporarily treat this as a dynamic light. var bool bTimerLoop; // Timer loops (else is one-shot). var(Advanced) bool bCanTeleport; // This actor can be teleported. var bool bOwnerNoSee; // Everything but the owner can see this actor. var bool bOnlyOwnerSee; // Only owner can see this actor. var const bool bAlwaysTick; // Update even when players-only. var(Advanced) bool bHighDetail; // Only show up on high-detail. var(Advanced) bool bStasis; // In StandAlone games, turn off if not in a recently rendered zone turned off if bStasis and physics = PHYS_None or PHYS_Rotating. var bool bTrailerSameRotation; // If PHYS_Trailer and true, have same rotation as owner. var bool bTrailerPrePivot; // If PHYS_Trailer and true, offset from owner by PrePivot. var bool bClientAnim; // Don't replicate any animations - animation done client-side var bool bWorldGeometry; // Collision and Physics treats this actor as world geometry var(Advanced) bool bAcceptsProjectors; // Projectors can project onto this actor var bool bOrientOnSlope; // when landing, orient base on slope of floor var bool bPaused; //NEW (mjl) if true, the actor is currently paused and not being updated remotely var bool bCanFallOutOfWorld; //NEW (arl) suppress fell out of world message var(Advanced) bool bLaunchPawns; //NEW (mdf) Pawn's should be launched off this actor if they stand/land on it var(Advanced) bool bIgnoreSingularityDamage; //NEW (mdf) if true, actor is unaffected by damage from black holes var(Advanced) bool bIgnoreSingularityForces; //NEW (mdf) if true, actor is unaffected by forces from black holes var(Advanced) bool bIgnoreImpactForces; //NEW (mdf) if true, actor is not affected by forces from impacts (hit momentum transfer) // Networking flags var const bool bNetTemporary; // Tear-off simulation in network play. var const bool bNetOptional; // Actor should only be replicated if bandwidth available. var const bool bNetDirty; // set when any attribute is assigned a value in unrealscript, reset when the actor is replicated var bool bAlwaysRelevant; // Always relevant for network. var bool bReplicateInstigator; // Replicate instigator to client (used by bNetTemporary projectiles). var bool bReplicateMovement; // if true, replicate movement/location related properties var bool bSkipActorPropertyReplication; // if true, don't replicate actor class variables for this actor var bool bUpdateSimulatedPosition; // if true, update velocity/location after initialization for simulated proxies var bool bTearOff; // if true, this actor is no longer replicated to new clients, and // is "torn off" (becomes a ROLE_Authority) on clients to which it was being replicated. var bool bOnlyDirtyReplication; // if true, only replicate actor if bNetDirty is true - useful if no C++ changed attributes (such as physics) // bOnlyDirtyReplication only used with bAlwaysRelevant actors var bool bReplicateAnimations; // Should replicate SimAnim //NEW (mwp) var(Advanced) byte DetailLevel; // Actor detail level (0:Low - 2:High) var(Advanced) byte GoreLevel; // Actor gore level (0:None, 1:Low, 1:Medium, 2:High) var(Advanced) bool bDifficulty0; // actor is present in "EASY" difficulty var(Advanced) bool bDifficulty1; // actor is present in "NORMAL" difficulty var(Advanced) bool bDifficulty2; // actor is present in "HARD" difficulty //OLD //NEW (arl) // Swinging variables var(Movement) vector SwingPivot; var(Movement) float SwingLength; var(Movement) float SwingFriction; var(Movement) vector SwingGravDir; //OLD // Net variables. enum ENetRole { ROLE_None, // No role at all. ROLE_DumbProxy, // Dumb proxy of this actor. ROLE_SimulatedProxy, // Locally simulated proxy of this actor. ROLE_AutonomousProxy, // Locally autonomous proxy of this actor. ROLE_Authority, // Authoritative control over the actor. }; var ENetRole Role; var ENetRole RemoteRole; //NEW (arl) Lighting var transient int LightTag; // Change this if you want lightmaps to be rebuilt. //OLD var const transient int NetTag; var float LastRenderTime; // last time this actor was rendered. var(Events) name Tag; // Actor's tag name. // Execution and timer variables. var float TimerRate; // Timer event, 0=no timer. var const float TimerCounter; // Counts up until it reaches TimerRate. var(Advanced) float LifeSpan; // How old the object lives before dying, 0=forever. // Animation variables. #SKEL: Left in for this build only to wrap up any backward compatibility - but not used. - Erik var(Display) name AnimSequence; // Animation sequence we're playing. var(Display) float AnimFrame; // Current animation frame, 0.0 to 1.0. var(Display) float AnimRate; // Animation rate in frames per second, 0=none, negative=velocity scaled. var float TweenRate; // Tween-into rate. var transient MeshInstance MeshInstance; // Mesh instance. var(Display) float LODBias; var(Object) name InitialState; var(Object) name Group; //----------------------------------------------------------------------------- // Structures. // Identifies a unique convex volume in the world. struct PointRegion { var zoneinfo Zone; // Zone. var int iLeaf; // Bsp leaf. var byte ZoneNumber; // Zone number. }; //NEW (mdf) struct native TCollision { var() float Height; var() float Radius; }; struct Face { var array<vector> Points; //tbd: var vector FaceNormal; }; //OLD //----------------------------------------------------------------------------- // Major actor properties. // Scriptable. var const LevelInfo Level; // Level this actor is on. var transient const Level XLevel; // Level object. var(Events) name Event; // The event this actor causes. var Pawn Instigator; // Pawn responsible for damage caused by this actor. var(Sound) sound AmbientSound; // Ambient sound effect. var Inventory Inventory; // Inventory chain. var const PointRegion Region; // Region this actor is in. var transient array<int> Leaves; // BSP leaves this actor is in. // Internal. var const float LatentFloat; // Internal latent function use. var const array<Actor> Touching; // List of touching actors. var const actor Deleted; // Next actor in just-deleted chain. // Internal tags. var const native int CollisionTag, LightingTag, ActorTag; // The actor's position and rotation. var const PhysicsVolume PhysicsVolume; // physics volume this actor is currently in var(Movement) const vector Location; // Actor's location; use Move to set. var(Movement) const rotator Rotation; // Rotation. var(Movement) vector Velocity; // Velocity. var vector Acceleration; // Acceleration. //NEW (mdf) support for mucking with falling velocity and/or acceleration (e.g. for parachuting actors, slow projectiles) var(Movement) float FallingMaxVelocityZ; // Use to cap Abs(Z) component of velocity while PHYS_Falling, prior to applying TerminalVelocity. <0 ==> cap "falling down, >0 ==> Cap "falling up", 0 ==> won't fall up/down var(Movement) float FallingMaxVelocityXY; // Use to cap XY component of velocity while PHYS_Falling, prior to applying TerminalVelocity. 0 ==> no XY "drift" var(Movement) vector FallingAddedAcceleration; // Use to have per-actor acceleration (e.g. drift while parachuting). Enough -Z implies actor will "fall" up. //OLD // Attachment related variables var(Movement) name AttachTag; var bool bSpecialRotationRep; //NEW (arl) Hack to override Rotation replication statement for ParticleSprayers. var(Advanced) float ActorTimeDilation; //NEW (arl) Slomo for individual actors. var const array<Actor> Attached; // array of actors attached to this actor. var const vector RelativeLocation; // location relative to base/bone (valid if base exists) var const rotator RelativeRotation; // rotation relative to base/bone (valid if base exists) var const name AttachmentBone; // name of bone to which actor is attached (if attached to center of base, =='') // Projectors struct ProjectorRenderInfoPtr { var int Ptr; }; // Hack to to fool C++ header generation... struct StaticMeshProjectorRenderInfoPtr { var int Ptr; }; var const native array<ProjectorRenderInfoPtr> Projectors;// Projected textures on this actor var const native array<StaticMeshProjectorRenderInfoPtr> StaticMeshProjectors; //----------------------------------------------------------------------------- // Display properties. var(Display) Material Texture; // Sprite texture.if DrawType=DT_Sprite var(Display) mesh Mesh; // Mesh if DrawType=DT_Mesh. var(Display) string MeshParams; //NEW(cdh) Mesh creation parameters if desired var StaticMeshInstance StaticMeshInstance; // Contains per-instance static mesh data, like static lighting data. var const export model Brush; // Brush if DrawType=DT_Brush. var(Display) const float DrawScale; // Scaling factor, 1.0=normal size. var(Display) const vector DrawScale3D; // Scaling vector, (1.0,1.0,1.0)=normal size. //NEW (mdf) align mesh to surface support var vector AlignMeshTraceVector; // If set mesh will be aligned to normal found by tracing along this vector under "patch". var vector AlignMeshTraceOffset1; // Offset of 1st patch point from which to trace relative to origin/rotation. var vector AlignMeshTraceOffset2; // Offset of 2nd patch point from which to trace relative to origin/rotation. var vector AlignMeshTraceOffset3; // Offset of 3rd patch point from which to trace relative to origin/rotation. var vector AlignMeshNormal; // Normal used to align mesh -- calculated internally but should be cleared if AlignMeshTraceVector cleared. var int DebugAlignMeshLevel; // Debug level (!!mdf-tbr). (if all 3 offsets identical, does a simple trace?) //OLD var(Display) vector PrePivot; // Offset from box center for drawing. var(Display) float TerrainZOffset; //NEW (mdf) for shifting certain actors up on terrain (so they don't sink) var(Display) float SpriteProjForward; //NEW (arl) Distance to move Sprites toward the camera (worldspace). var(Display) float ScaleGlow; // Multiplies lighting. var(Display) array<Material> Skins; // Multiple skin support - not replicated. var(Display) color AmbientColor; //NEW (arl) Base additive ambient color. var(Display) byte AmbientGlow; // Ambient brightness, or 255=pulsing. var(Display) ConvexVolume AntiPortal; // Convex volume used for DT_AntiPortal var(Display) float BlurDegree; //NEW (arl) OSB_EFFECTS var(Display) float ActorFOV; //NEW (arl) Actor specific FOV rendering. var(Display) float VisibilityRadius;//NEW (mwp) Actor is drawn if viewer is within its visibility var(Display) float VisibilityHeight;//NEW (mwp) cylinder. Zero=infinite visibility. var(Display) float RenderBoundFactor;//NEW (cdh) Used to change render bounding box/sphere (render size = collision size * renderboundfactor) // Style for rendering sprites, meshes. var(Display) enum ERenderStyle { STY_None, // don't use this! STY_Normal, STY_Masked, STY_Translucent, STY_Brighten, //NEW (mw) STY_Modulated, STY_Alpha, STY_Particle } Style; // Display. var(Display) bool bMustFace; //NEW (arl) Set to false if you want this actor to be drawn whether you are facing it or not. var(Display) bool bUnlit; // Lights don't affect actor. var(Display) bool bNoSmooth; // Don't smooth actor's texture. var(Display) bool bShadowCast; // Casts static shadows. var(Display) bool bStaticLighting; // Uses raytraced lighting. var(Advanced) bool bRenderNoPredict; //NEW (cdh) Actor's render sorting behavior is sensitive; don't use a prediction box that can screw it up // Advanced. var(Advanced) bool bNeverBatch; //NEW (mwp) disable StaticMesh Batching var bool bHurtEntry; // keep HurtRadius from being reentrant var(Advanced) bool bGameRelevant; // Always relevant for game var(Advanced) bool bCollideWhenPlacing; // This actor collides with the world when placing. var bool bTravel; // Actor is capable of travelling among servers. var(Advanced) bool bMovable; // Actor can be moved. var(Events) bool bLocalGameEvent; // this event should be saved as a local saved game event var(Events) bool bTravelGameEvent; // this event should travel across levels as a saved game event var bool bDestroyInPainVolume; // destroy this actor if it enters a pain volume var bool bPendingDelete; // set when actor is about to be deleted (since endstate and other functions called // during deletion process before bDeleteMe is set). var(Advanced) bool bAutoEnableAgent; //NEW (arl) Automatically enables all agent channels for this mesh. var bool bMeshAlwaysRefresh; //NEW (cdh) Always refresh script processes, even when not rendering var bool bDisturbFluidSurface; // Cause ripples when in contact with FluidSurface. JAG FLUID //----------------------------------------------------------------------------- // Sound. // Ambient sound. var(Sound) float SoundRadius; // Radius of ambient sound. var(Sound) byte SoundVolume; // Volume of ambient sound. var(Sound) byte SoundPitch; // Sound pitch shift, 64.0=none. // Sound occlusion enum ESoundOcclusion { OCCLUSION_Default, OCCLUSION_None, OCCLUSION_BSP, OCCLUSION_StaticMeshes, }; var(Sound) ESoundOcclusion SoundOcclusion; // Sound occlusion approach. // Sound slots for actors. enum ESoundSlot { SLOT_None, SLOT_Misc, SLOT_Pain, SLOT_Interact, SLOT_Ambient, SLOT_Talk, SLOT_Interface, SLOT_Dialog, SLOT_Weapon, }; // Music transitions. enum EMusicTransition { MTRAN_None, MTRAN_Instant, MTRAN_Segue, MTRAN_Fade, MTRAN_FastFade, MTRAN_SlowFade, }; // Regular sounds. var(Sound) float TransientSoundVolume; // default sound volume for regular sounds (can be overridden in playsound) var(Sound) float TransientSoundRadius; // default sound radius for regular sounds (can be overridden in playsound) //----------------------------------------------------------------------------- // Dialog var(Dialog) string Speaker; // which dialog can be spoken //----------------------------------------------------------------------------- // Collision. // Collision size. var(Collision) const float CollisionRadius; // Radius of collision cyllinder. var(Collision) const float CollisionHeight; // Half-height cyllinder. // Collision flags. var(Collision) const bool bCollideActors; // Collides with other actors. var(Collision) bool bCollideWorld; // Collides with the world. var(Collision) bool bBlockActors; // Blocks other nonplayer actors. var(Collision) bool bBlockPlayers; // Blocks other player actors. var(Collision) bool bProjTarget; // Projectiles should potentially target this actor. var(Collision) bool bBlockZeroExtentTraces; // block zero extent actors/traces var(Collision) bool bBlockNonZeroExtentTraces; // block non-zero extent actors/traces var(Collision) bool bNoStaticMeshCollide; //NEW (arl) Force actors with static meshes to use collision cylinder collision instead. var(Collision) bool bCanMantle; //NEW (mdf) whether actor can be mantled var bool bCanEncroachPlayer; //NEW (mdf) allow some actors (usually scripted NPCs) to pass through players var(Collision) bool bPathColliding; //NEW (mdf) this actor should collide (if bWorldGeometry && bBlockActors is true) during path building (ignored if bStatic is true, as actor will always collide during path building) var(Collision) bool bBlockNavigation; //NEW (mdf) if true NPCs will treat this as a blocking actor and try to go around it (useful for small blocking volumes that the player can go onto) var(Collision) bool bBlockStepping; //NEW (mdf) if true NPCs will avoid stepping/jumping/crouch-stepping onto this actor if they bump it (useful for small blocking volumes that the player can go onto) var(Collision) array< class<Actor> > CanEncroachList; //NEW (mdf) list of actors classes that this actor can encroach during movement var(Lighting) float LightPriority; //NEW: Scales light priority calculation. //NEW (arl) ParticleLighting var(Lighting) const bool bLightParticles;// Use to light particles. var const Actor nextParticleLight; //OLD var const Actor PrimaryStaticLight; //NEW (arl) Shadows var const Actor PrimaryDynamicLight; //NEW (arl) Shadows //----------------------------------------------------------------------------- // Physics. // Options. var(Movement) bool bBounce; // Bounces when hits ground fast. var(Movement) bool bFixedRotationDir; // Fixed direction of rotation. var(Movement) bool bRotateToDesired; // Rotate to DesiredRotation. var bool bInterpolating; // Performing interpolating. var const bool bJustTeleported; // Used by engine physics - not valid for scripts. var(Movement) bool bAllowClipping; //NEW (mwp) If set to true, Actors with PHYS_Projectile will not be destroyed if they go outside the level. // Physics properties. var(Movement) float Mass; // Mass of this actor. var(Movement) float Buoyancy; // Water buoyancy. var(Movement) rotator RotationRate; // Change in rotation per second. var(Movement) rotator AmbientRotationRate;//NEW (mdf) Ambient rotation rate -- used if non-zero var(Movement) rotator DesiredRotation; // Physics will smoothly rotate actor to this rotation if bRotateToDesired. var Actor PendingTouch; // Actor touched during move which wants to add an effect after the movement completes var const vector ColLocation; // Actor's old location one move ago. Only for debugging //NEW (mdf) step height changes. /*OLD const MAXSTEPHEIGHT = 35.0; // Maximum step height walkable by pawns */ // ifdef WITH_KARMA var(Karma) export editinline KarmaParams KParams; // Parameters for Karma Dyanmics. See KaramParams.uc // endif //----------------------------------------------------------------------------- // Animation replication (can be used to replicate channel 0 anims for dumb proxies) struct AnimRep { var name AnimSequence; var bool bAnimLoop; var byte AnimRate; // note that with compression, max replicated animrate is 4.0 var byte AnimFrame; var byte TweenRate; // note that with compression, max replicated tweentime is 4 seconds }; var transient AnimRep SimAnim; // only replicated if bReplicateAnimations is true //NEW (cdh) mounting var(Mounting) name MountParentTag; // Tag of actor to mount to at level startup. var(Mounting) string MountParentNode; // Node name of mesh node to mount at, none for actor origin. var(Mounting) vector MountOrgLocation; // Origin location for mount, relative to node. var(Mounting) rotator MountOrgRotation; // Origin rotation for mount, relative to node. var(Mounting) EPhysics MountDetachPhysics; // Physics to use on detachment if not being destroyed. var(Mounting) bool bMountDetachDestroy;// Actor should be destroyed on detachment. var Actor MountParentActor; // Actor that we are mounted to. var vector MountOldLocation; // Internal use, old location of actor. var rotator MountOldRotation; // Internal use, old rotation of actor. //OLD //NEW (cdh) mesh node get/set "relative-to" type enum EMeshNodeRelType { MESHNODEREL_World, // location/rotation/scale in world space (default) MESHNODEREL_Mesh, // location/rotation/scale in mesh space MESHNODEREL_ParentNode, // location/rotation/scale in parent node space MESHNODEREL_RefPose, // location/rotation/scale relative to reference pose }; //OLD // AnimStruct used for scripted sequences struct AnimStruct { var() name AnimSequence; var() name BoneName; var() float AnimRate; var() byte alpha; var() byte LeadIn; var() byte LeadOut; var() bool bLoopAnim; }; //NEW (mjl) generic lists //defined here so subclasses can use them... struct ActorType { var() Class ClassType; // the class name (not an actual class) of the actor var() bool bExcludeSubclasses; // whether it should include subclasses of the ClassName as well }; struct ActorList { var() name ListName; // name for quick look-up of actor lists var() array<ActorType> ActorTypes; // the various types of actors which should be included in the List var() array<Actor> List; // the actual list of actors }; //OLD //----------------------------------------------------------------------------- // Forces. enum EForceType { FT_None, FT_DragAlong, }; var (Force) EForceType ForceType; var (Force) float ForceRadius; var (Force) float ForceScale; //----------------------------------------------------------------------------- // Networking. // Network control. var float NetPriority; // Higher priorities means update it more frequently. var float NetUpdateFrequency; // How many seconds between net updates. // Symmetric network flags, valid during replication only. var const bool bNetInitial; // Initial network update. var const bool bNetOwner; // Player owns this actor. var const bool bNetRelevant; // Actor is currently relevant. Only valid server side, only when replicating variables. var const bool bDemoRecording; // True we are currently demo recording var const bool bClientDemoRecording;// True we are currently recording a client-side demo var const bool bClientDemoNetFunc;// True if we're client-side demo recording and this call originated from the remote. //Editing flags var(Advanced) bool bHiddenEd; // Is hidden during editing. var(Advanced) bool bHiddenEdGroup;// Is hidden by the group brower. var(Advanced) bool bDirectional; // Actor shows direction arrow during editing. var const bool bSelected; // Selected in UnrealEd. var(Advanced) bool bEdShouldSnap; // Snap to grid in editor. var(Advanced) bool bEdCanOverlap; //NEW (mdf) If true won't get "in same location as" warnings when building maps. var transient bool bEdSnap; // Should snap to grid in UnrealEd. var transient const bool bTempEditor; // Internal UnrealEd. var bool bObsolete; // actor is obsolete - warn level designers to remove it //OLD (mdf) moved var(Collision) bool bPathColliding;// this actor should collide (if bWorldGeometry && bBlockActors is true) during path building (ignored if bStatic is true, as actor will always collide during path building) var bool bEditorPlaced; // true if actor was placed in the editor var transient bool bPathTemp; // Internal/path building var(Advanced) bool bScriptInitialized; //NEW (mdf) set to prevent re-initializing of actors spawned during level startup //OLD (mdf) var() bool bScriptInitialized; // set to prevent re-initializing of actors spawned during level startup var(Advanced) bool bLockLocation; // Prevent the actor from being moved in the editor. var class<LocalMessage> MessageClass; //----------------------------------------------------------------------------- // Enums. // Travelling from server to server. enum ETravelType { TRAVEL_Absolute, // Absolute URL. TRAVEL_Partial, // Partial (carry name, reset server). TRAVEL_Relative, // Relative URL. }; // double click move direction. enum EDoubleClickDir { DCLICK_None, DCLICK_Left, DCLICK_Right, DCLICK_Forward, DCLICK_Back, DCLICK_Active, DCLICK_Done }; //NEW (arl) // NOTE[aleiby]: Maintainance hazard -- make sure these stay in sync with C++ version. // Flags describing effects and properties of a Bsp polygon. //enum EPolyFlags //{ // Regular in-game flags. const PF_Invisible = 0x00000001; // Poly is invisible. const PF_Masked = 0x00000002; // Poly should be drawn masked. const PF_Translucent = 0x00000004; // Poly is transparent. const PF_NotSolid = 0x00000008; // Poly is not solid; doesn't block. const PF_Environment = 0x00000010; // Poly should be drawn environment mapped. const PF_Semisolid = 0x00000020; // Poly is semi-solid = collision solid; Csg nonsolid. const PF_Modulated = 0x00000040; // Modulation transparency. const PF_FakeBackdrop = 0x00000080; // Poly looks exactly like backdrop. const PF_TwoSided = 0x00000100; // Poly is visible from both sides. const PF_NoSmooth = 0x00000800; // Don't smooth textures. const PF_AlphaTexture = 0x00001000; // Honor texture alpha (reuse BigWavy and SpecialPoly flags) const PF_Flat = 0x00004000; // Flat surface. const PF_NoMerge = 0x00010000; // Don't merge poly's nodes before lighting when rendering. const PF_NoZTest = 0x00020000; // Don't test Z buffer const PF_SpecialLit = 0x00100000; // Only speciallit lights apply to this poly. const PF_Wireframe = 0x00200000; // Render as wireframe const PF_Unlit = 0x00400000; // Unlit. const PF_HighShadowDetail = 0x00800000; // High detail shadows. const PF_Portal = 0x04000000; // Portal between iZones. const PF_AntiPortal = 0x08000000; // Antiportal const PF_Mirrored = 0x20000000; // Mirrored BSP surface. // Editor flags. const PF_Memorized = 0x01000000; // Editor: Poly is remembered. const PF_Selected = 0x02000000; // Editor: Poly is selected. const PF_FlatShaded = 0x40000000; // FPoly has been split by SplitPolyWithPlane. // Unused flags. const PF_Unused0 = 0x00000200; const PF_Unused1 = 0x00000400; const PF_Unused2 = 0x00002000; const PF_Unused3 = 0x00008000; const PF_Unused4 = 0x00040000; const PF_Unused5 = 0x00080000; // Internal. const PF_EdProcessed = 0x40000000; // FPoly was already processed in editorBuildFPolys. const PF_EdCut = 0x80000000; // FPoly has been split by SplitPolyWithPlane. const PF_RenderFog = 0x40000000; // Render with fogmapping. const PF_Occlude = 0x80000000; // Occludes even if PF_NoOcclude. /* // Combinations of flags. const PF_NoOcclude = PF_Masked | PF_Translucent | PF_Invisible | PF_Modulated; const PF_NoEdit = PF_Memorized | PF_Selected | PF_EdProcessed | PF_NoMerge | PF_EdCut; const PF_NoImport = PF_NoEdit | PF_NoMerge | PF_Memorized | PF_Selected | PF_EdProcessed | PF_EdCut; const PF_AddLast = PF_Semisolid | PF_NotSolid; const PF_NoAddToBSP = PF_EdCut | PF_EdProcessed | PF_Selected | PF_Memorized; const PF_NoShadows = PF_Unlit | PF_Invisible | PF_FakeBackdrop; */ //}; /* struct IteratorList { var() Object Next; //IteratorList* }; struct IteratorActorList extends IteratorList { var() Actor Actor; }; */ struct CheckResult /*extends IteratorActorList*/ { var() Object Next; //IteratorList* var() Actor Actor; var() vector Location; // Location of the hit in coordinate system of the returner. var() vector Normal; // Normal vector in coordinate system of the returner. Zero=none. var() Primitive Primitive; // Actor primitive which was hit, or NULL=none. var() float Time; // Time until hit, if line check. var() int Item; // Primitive data item which was hit, INDEX_NONE=none. var() Material Material; // Material cached by LineCheck() }; // CheckResult is duplicated in Material.uc to prevent a circular dependency, please be sure to update both copies. //OLD //NEW (mdf) support showing Actor CC etc. const DF_None = 0x00000000; const DF_Collision = 0x00000001; var(Display) int SpecialDisplayFlags; //OLD //NEW (mwp) //Fix arl (tbr) var(Display) class<RenderIterator> RenderIteratorClass; // class to instantiate as the actor's RenderInterface var transient RenderIterator RenderInterface; // abstract iterator initialized in the Rendering engine //OLD var private string IndentStr; //NEW (mdf) Debug var const array<string> UseReticleOnEvents; //NEW (mib) UI var const array<string> ProximityReticleOnEvents; //NEW (mib) UI //NEW (mw) //----------------------------------------------------------------------------- // Atlantis relevancy for filter actors based on which missions we are transitioning between var(Filter) bool bDoMissionFiltering; var(Filter) bool bPreMission00; var(Filter) bool bPreMission01; var(Filter) bool bPreMission02; var(Filter) bool bPreMission03; var(Filter) bool bPreMission04; var(Filter) bool bPreMission05; var(Filter) bool bPreMission06; var(Filter) bool bPreMission07; var(Filter) bool bPreMission08; var(Filter) bool bPreMission09; var(Filter) bool bPreMission10; var(Filter) bool bPreMission11; var(Filter) bool bPreMission12; var(Filter) bool bPreMission13; var(Filter) bool bPostMission83; var(Filter) bool bPostMission110276; //OLD //----------------------------------------------------------------------------- // natives. // Execute a console command in the context of the current level and game engine. native function string ConsoleCommand( string Command ); function string GetCommandLine() { return ConsoleCommand( "getcommandline" ); } //----------------------------------------------------------------------------- // Network replication. replication { // replicated functions unreliable if( bDemoRecording ) DemoPlaySound; } event Replication() { if ( bSkipActorPropertyReplication && !bNetInitial ) return; if ( bReplicateMovement ) { if ( RemoteRole == ROLE_AutonomousProxy ) { if ( bNetInitial ) { DOREP('Location'); if( DrawType==DT_Mesh || DrawType==DT_StaticMesh ) DOREP('Rotation'); } } else if ( RemoteRole == ROLE_SimulatedProxy ) { DOREP('Base'); if ( bNetInitial || bUpdateSimulatedPosition ) DOREP('Velocity'); if( Base != None && !Base.bWorldGeometry ) { DOREP('RelativeLocation'); DOREP('RelativeRotation'); //!!cdh: do we still need an attachmentbone ? DOREP('AttachmentBone'); } //NEW else if( bUpdateSimulatedPosition ) { DOREP('Location'); if( DrawType==DT_Mesh || DrawType==DT_StaticMesh ) DOREP('Rotation'); } else if( bNetInitial ) { if( DrawType==DT_Mesh || DrawType==DT_StaticMesh ) DOREP('Rotation'); } /*OLD else if( bNetInitial || bUpdateSimulatedPosition ) { DOREP('Location'); if( DrawType==DT_Mesh || DrawType==DT_StaticMesh ) DOREP('Rotation'); } */ if( bNetInitial ) { DOREP('Physics'); } if( Physics==PHYS_Rotating ) { DOREP('bFixedRotationDir'); DOREP('bRotateToDesired'); DOREP('RotationRate'); DOREP('DesiredRotation'); } //NEW else if( Physics==PHYS_Swinging ) { DOREP('SwingPivot'); DOREP('SwingLength'); DOREP('SwingFriction'); DOREP('SwingGravDir'); } //OLD } else // dumb proxy { if( Base != None && !Base.bWorldGeometry ) { DOREP('RelativeLocation'); DOREP('RelativeRotation'); DOREP('AttachmentBone'); } else { //NEW if( !bNetInitial ) DOREP('Location'); /*OLD DOREP('Location'); */ if( DrawType==DT_Mesh || DrawType==DT_StaticMesh ) DOREP('Rotation'); } DOREP('Base'); DOREP('Physics'); if ( Physics == PHYS_Falling ) { DOREP('Velocity'); } else if( Physics==PHYS_Rotating ) { DOREP('bFixedRotationDir'); DOREP('bRotateToDesired'); DOREP('RotationRate'); DOREP('DesiredRotation'); } } } if ( !bNetOwner || !bClientAnim ) { DOREP('AmbientSound'); if( AmbientSound != None ) { DOREP('SoundRadius'); DOREP('SoundVolume'); DOREP('SoundPitch'); } } if ( bNetDirty ) { DOREP('Owner'); DOREP('DrawScale'); DOREP('DrawType'); DOREP('bCollideActors'); DOREP('bCollideWorld'); DOREP('bOnlyOwnerSee'); DOREP('Texture'); DOREP('Style'); if ( (DrawType == DT_Mesh) || (DrawType == DT_StaticMesh) ) { DOREP('PrePivot'); } if( bCollideActors || bCollideWorld ) { DOREP('bProjTarget'); DOREP('bBlockActors'); DOREP('bBlockPlayers'); DOREP('CollisionRadius'); DOREP('CollisionHeight'); } //NEW MJL: inventory linked-list done clientside /*OLD if( bNetOwner ) DOREP('Inventory'); */ if( bReplicateInstigator ) { DOREP('Instigator'); } if( DrawType==DT_Mesh ) { DOREP('AmbientGlow'); DOREP('ScaleGlow'); DOREP('bUnlit'); DOREP('Mesh'); } else if( DrawType==DT_StaticMesh ) { DOREP('StaticMesh'); } DOREP('LightType'); if( LightType!=LT_None ) { DOREP('LightEffect'); DOREP('LightBrightness'); DOREP('LightHue'); DOREP('LightSaturation'); DOREP('LightRadius'); DOREP('LightPeriod'); DOREP('LightPhase'); DOREP('VolumeBrightness'); DOREP('VolumeRadius'); DOREP('bSpecialLit'); } } if( bReplicateAnimations && (DrawType==DT_Mesh) ) { DOREP('SimAnim'); } DOREP('bHidden'); DOREP('Role'); DOREP('RemoteRole'); DOREP('ActorTimeDilation'); //NEW DOREP('bTearOff'); } //NEW MJL: NEWNET allows for much more optimized networking code in unrealscript //put code in this function instead of using the replication { ... } statements //example of this can be found above //event Replication(int NumReps); //This translates almost 100% to native code, aside from the need to specify the class in the native code native final function DOREP(name Variable); native final function FORCEREP(name Variable); native final function RedoBNetInitial(); //END NEW //NEW (mwp) DetailLevels //============================================================================= // Accessor functions for Client MaxDetaillevel and GoreDetailLevel //----------------------------------------------------------------------------- native final function int GetMaxDetailLevel(); native final function int GetGoreDetailLevel(); native final function Client GetClient(); //NEW (arl) function bool IsDifficultyOK() { local byte Difficulty; Difficulty = Level.Game.GetDifficulty(); return Difficulty == 0 && bDifficulty0 || Difficulty == 1 && bDifficulty1 || Difficulty == 2 && bDifficulty2 || Difficulty > 2; } function bool IsDetailLevelOK() { return DetailLevel <= GetMaxDetailLevel(); } function bool IsGoreOK() { return GoreLevel <= GetGoreDetailLevel(); } //OLD function NotifyGoreDetailChanged( byte NewGoreDetailLevel ); //NEW (mib) notify actor of gore changes //============================================================================= // Actor error handling. // Handle an error and kill this one actor. native(233) final function Error( coerce string S ); //============================================================================= // General functions. // Latent functions. native(256) final latent function Sleep( float Seconds ); // Collision. native(262) final function SetCollision( optional bool NewColActors, optional bool NewBlockActors, optional bool NewBlockPlayers ); native(283) final function bool SetCollisionSize( float NewRadius, float NewHeight ); //NEW (mdf) NOTE: execSetCollisionSize is hard-coded to return 1 currently native final function SetDrawScale(float NewScale); native final function SetDrawScale3D(vector NewScale3D); native final function SetDrawType(EDrawType NewDrawType); //NEW native final function ClearRenderData(); //OLD // Movement. //NEW (mdf) native(266) final function bool Move( vector Delta, optional bool bTest ); /*OLD native(266) final function bool Move( vector Delta ); */ native(267) final function bool SetLocation( vector NewLocation ); native(299) final function bool SetRotation( rotator NewRotation ); native final function SetClassStatic( class<Actor> TargetClass, bool bVal ); //NEW // SetRelativeRotation() sets the rotation relative to the actor's base native final function bool SetRelativeRotation( rotator NewRotation ); native final function bool SetRelativeLocation( vector NewLocation ); native(3969) final function bool MoveSmooth( vector Delta ); native(3971) final function AutonomousPhysics(float DeltaSeconds); // Relations. native(298) final function SetBase( actor NewBase, optional vector NewFloor ); native final function FindBase(); //NEW (mdf) native(272) final function SetOwner( actor NewOwner ); //============================================================================= // Animation. // Animation functions. native(259) final function PlayAnim( name Sequence, optional float Rate, optional float TweenTime, optional int Channel ); native(260) final function LoopAnim( name Sequence, optional float Rate, optional float TweenTime, optional int Channel ); native(294) final function TweenAnim( name Sequence, float Time, optional int Channel ); native(282) final function bool IsAnimating(optional int Channel); //NEW: Fix (see bAnimLoopFinished) native(261) final latent function FinishAnim( optional int Channel, optional bool bKillLoop ); /*OLD native(261) final latent function FinishAnim(optional int Channel); */ native(263) final function bool HasAnim( name Sequence ); native final function StopAnimating(); native final function bool IsTweening(int Channel); //NEW (mdf) - animation extensions native simulated final function int GetAnimFrames( name Sequence ); // returns # frames in given animation (0 if doesn't exist) native simulated final function name GetAnimBaseName( name Sequence ); // returns basename for given animation native simulated final function string GetAnimVersion( name Sequence ); // returns trailing ## for given animation (or "" if none) native simulated final function name GetAnimSlot( name Sequence ); // returns slot for given animation native simulated final function name GetAnimExtInfo1( name Sequence ); // returns extended info #1 for given animation native simulated final function name GetAnimExtInfo2( name Sequence ); // returns extended info #2 for given animation native simulated final function int GetAnimCount(); // returns # animations native simulated final function name GetAnim( int Index ); // returns animation at given index native simulated final function int GetAnimIndex( name Sequence ); // returns index of given animation native simulated final function name GetAnimGroup( name Sequence ); // ripped out of 777 build //OLD //NEW: Node/bone retrieval methods native simulated final function int MeshGetNodeCount ( optional bool InDefault ); native simulated final function int/*HMeshNode*/ MeshGetNodeIndexed ( int InIndex, optional bool InDefault ); native simulated final function int/*HMeshNode*/ MeshGetNodeNamed ( string InNameStr, optional bool InDefault ); native simulated final function string MeshGetNodeWeapon ( optional mesh Mesh ); native simulated final function int MeshNodeGetIndex ( int/*HMeshNode*/ InNode ); native simulated final function vector MeshNodeGetTranslation ( int/*HMeshNode*/ InNode, optional EMeshNodeRelType InRelType ); native simulated final function MeshNodeSetTranslation ( int/*HMeshNode*/ InNode, vector InTranslation, optional EMeshNodeRelType InRelType ); native simulated final function rotator MeshNodeGetRotation ( int/*HMeshNode*/ InNode, optional EMeshNodeRelType InRelType ); native simulated final function MeshNodeSetRotation ( int/*HMeshNode*/ InNode, rotator InRotation, optional EMeshNodeRelType InRelType ); native simulated final function vector MeshNodeGetScale ( int/*HMeshNode*/ InNode, optional EMeshNodeRelType InRelType ); native simulated final function MeshNodeSetScale ( int/*HMeshNode*/ InNode, vector InScale, optional EMeshNodeRelType InRelType ); native simulated final function RefreshAllScriptProcesses(); //OLD simulated final function NotifyLog( string Msg ){ DMN("[GAL]:"@Msg); } //NEW //NEW(arl): StaticMesh attachments. native simulated final function vector MeshGetStaticMeshAttachmentOffset( int AttachmentIndex ); native simulated final function MeshSetStaticMeshAttachmentOffset( int AttachmentIndex, vector Offset ); native simulated final function MeshSetStaticMeshAttachmentSkin( int AttachmentIndex, int SkinIndex, material Skin ); native simulated final function MeshSetStaticMeshAttachmentSkinsAll( material Skin ); native simulated final function MeshGetAttachments( string Name, out array<Actor> Attachments ); simulated final event ParticleTrigger( string Name ) { local int i; local array<Actor> Attachments; TM('TR_Render',Self,"TRACE: ParticleTrigger"@Name@Self); MeshGetAttachments(Name,Attachments); for( i=0; i<Attachments.length; i++ ) Attachments[i].Trigger(Self,Instigator); } simulated final event ParticleUnTrigger( string Name ) { local int i; local array<Actor> Attachments; TM('TR_Render',Self,"TRACE: ParticleTrigger"@Name@Self); MeshGetAttachments(Name,Attachments); for( i=0; i<Attachments.length; i++ ) Attachments[i].UnTrigger(Self,Instigator); } simulated final function MoveAttachment( string Parms ) { local int i; local vector Offset; i = int(Left(Parms,InStr(Parms," "))); Parms = Mid(Parms,InStr(Parms," ")+1); Offset.X = float(Left(Parms,InStr(Parms," "))); Parms = Mid(Parms,InStr(Parms," ")+1); Offset.Y = float(Left(Parms,InStr(Parms," "))); Parms = Mid(Parms,InStr(Parms," ")+1); Offset.Z = float(Parms); DMN("MoveAttachment:"@i@Offset); MeshSetStaticMeshAttachmentOffset(i,Offset); } //OLD //NEW: CDH... mesh satellites (external actors/locations that correspond to mesh internal nodes) native simulated final function actor MeshGetSatelliteActor( name InSatelliteName); native simulated final function vector MeshGetSatelliteLocation( name InSatelliteName); native simulated final function int MeshSetSatellite( name InSatelliteName, actor InTargetActor, optional vector InTargetLocation ); //OLD //NEW: CDH... mesh agents // primary functions native simulated final function bool MeshAgentEnableChannel( int InChannelIndex, bool InEnable ); // enable/disable agent mode on a given channel native simulated final function bool MeshAgentSetInputCurValue( name InInputName, name InInputValue ); // set a given input's current value native simulated final function name MeshAgentGetInputCurValue( name InInputName ); // get the current value of a given input native simulated final function bool MeshAgentSetInputLock( name InInputName, bool InLocked ); // lock an input's current value from changes, until later unlocked native simulated final function float MeshAgentCallAction( name InActionName ); // manually call the action with a given name, returns duration or zero if indeterminate native simulated final function float MeshAgentImmediateAction( string InActionText ); // compiles the given text on-the-fly as if it were part of an action, and calls it native simulated final function bool MeshAgentResetChannel( int InChannelIndex ); // reset a given channel to an empty & unbound state native simulated final function int MeshAgentGetChannelBoundLevel( int InChannelIndex ); // get the level this channel was bound at (zero is unbound, positive is actual level + 1) native simulated final function float MeshAgentGetChannelBoundTime( int InChannelIndex ); // get the time that a channel has been bound for (by keepset) native simulated final function name MeshAgentGetChannelBoundAction( int InChannelIndex ); // get the agent action that bound this channel (the set/force block owner) native simulated final function name MeshAgentGetChannelScriptName( int InChannelIndex ); // script intended to play on a channel; GetAnimParams() sequence will be this if it exists // query & support functions, for determining agent capabilities native simulated final function int MeshAgentGetChannelCount(); // get number of supported agent channels native simulated final function name MeshAgentGetChannelName( int InChannelIndex ); // get name of a channel for a given index native simulated final function int MeshAgentGetInputCount(); // get number of inputs used by agent native simulated final function name MeshAgentGetInputName( int InInputIndex ); // get the name of a given input native simulated final function int MeshAgentGetInputValueCount( int InInputIndex ); // get the number of values supported by an input native simulated final function name MeshAgentGetInputValueName( int InInputIndex, int InValueIndex ); // get the name of a value for the given input native simulated final function int MeshAgentGetActionCount(); // get number of actions provided by agent native simulated final function name MeshAgentGetActionName( int InActionIndex ); // get name of action for a given index //OLD //NEW (mdf) expose surface normal functionality from align mesh stuff native final function bool GetAverageSurfaceNormal( vector TraceVector, vector TraceOffset1, vector TraceOffset2, vector TraceOffset3, out vector Normal ); //OLD //NEW: line rendering (see also "lines xxx" commands, e.g. "lines clear") static final function Color MakeColor( byte R, byte G, byte B, optional byte A ) { local Color C; C.R=R;C.G=G;C.B=B;C.A=A; return C;} static final function Color ColorBlue() { return MakeColor( 0, 0, 255, 255); } static final function Color ColorGreen() { return MakeColor( 0, 255, 0, 255); } static final function Color ColorCyan() { return MakeColor( 0, 255, 255, 255); } static final function Color ColorRed() { return MakeColor(255, 0, 0, 255); } static final function Color ColorMagenta() { return MakeColor(255, 0, 255, 255); } static final function Color ColorYellow() { return MakeColor(255, 255, 0, 255); } static final function Color ColorDkBlue() { return MakeColor( 0, 0, 127, 255); } static final function Color ColorDkGreen() { return MakeColor( 0, 127, 0, 255); } static final function Color ColorDkCyan() { return MakeColor( 0, 127, 127, 255); } static final function Color ColorDkRed() { return MakeColor(127, 0, 0, 255); } static final function Color ColorDkMagenta(){ return MakeColor(127, 0, 127, 255); } static final function Color ColorDkYellow() { return MakeColor(127, 127, 0, 255); } static final function Color ColorBlack() { return MakeColor( 0, 0, 0, 255); } static final function Color ColorDkGrey() { return MakeColor( 63, 63, 63, 255); } static final function Color ColorGrey() { return MakeColor(127, 127, 127, 255); } static final function Color ColorLtGrey() { return MakeColor(191, 191, 191, 255); } static final function Color ColorWhite() { return MakeColor(255, 255, 255, 255); } static final function Color ColorBrown() { return MakeColor(128, 64, 0, 255); } static final function Color ColorOrange() { return MakeColor(255, 127, 0, 255); } static final function Color ColorPink() { return MakeColor(255, 0, 128, 255); } native static final function AddLine( vector Start, vector End, optional Color C ); native static final function AddArrow( vector Start, vector End, optional Color C ); native static final function AddBox( vector Location, vector Extent, optional Color C ); native static final function AddCylinder( vector Location, float Radius, float Height, optional Color C ); native static final function AddActor( Actor A, optional Color C ); static final function AddActorAt( Actor A, vector TargetLocation, optional Color C ) { AddCylinder( TargetLocation, A.CollisionRadius, A.CollisionHeight, C ); } //OLD // Animation notifications. event /*probe*/ AnimEnd( int Channel ); native final function EnableChannelNotify ( int Channel, int Switch ); native final function int GetNotifyChannel(); // Skeletal animation. native final function LinkSkelAnim( MeshAnimation Anim ); native final function AnimBlendParams( int Stage, optional float BlendAlpha, optional float InTime, optional float OutTime, optional name BoneName ); native final function AnimBlendToAlpha( int Stage, float TargetAlpha, float TimeInterval ); native final function coords GetBoneCoords( name BoneName ); native final function rotator GetBoneRotation( name BoneName, optional int Space ); native final function vector GetRootLocation(); native final function rotator GetRootRotation(); native final function vector GetRootLocationDelta(); native final function rotator GetRootRotationDelta(); native final function bool AttachToBone( actor Attachment, name BoneName ); native final function bool DetachFromBone( actor Attachment ); native final function LockRootMotion( int Lock ); native final function SetBoneScale( int Slot, optional float BoneScale, optional name BoneName ); native final function SetBoneDirection( name BoneName, rotator BoneTurn, optional vector BoneTrans, optional float Alpha ); native final function SetBoneLocation( name BoneName, optional vector BoneTrans, optional float Alpha ); native final function SetBoneRotation( name BoneName, optional rotator BoneTurn, optional int Space, optional float Alpha ); native final function GetAnimParams( int Channel, out name OutSeqName, out float OutAnimFrame, out float OutAnimRate, out float OutAnimBlend, optional bool bDeprecated ); native final function bool AnimIsInGroup( int Channel, name GroupName ); //========================================================================= // Rendering. native final function plane GetRenderBoundingSphere(); //========================================================================= // Physics. // Physics control. native(301) final latent function FinishInterpolation(); native(3970) final function SetPhysics( EPhysics newPhysics ); //NEW native final simulated function UpdateMountPhysics(); //OLD //NEW (mdf) // uses simulated physics to return predicted landing location for actor with given velocity at given location native final function vector FallLanding( vector TestLocation, vector TestVelocity ); //OLD //NEW native function box GetCollisionBoundingBox( optional actor Owner ); native function box GetRenderBoundingBox( optional actor Owner ); //OLD // ifdef WITH_KARMA native final function KSetMass( float mass ); native final function float KGetMass(); // Set inertia tensor assuming a mass of 1. Scaled by mass internally to calculate actual inertia tensor. native final function KSetInertiaTensor( vector it1, vector it2 ); native final function KGetInertiaTensor( out vector it1, out vector it2 ); native final function KSetDampingProps( float lindamp, float angdamp ); native final function KGetDampingProps( out float lindamp, out float angdamp ); native final function KSetFriction( float Friction ); native final function float KGetFriction(); native final function KSetRestitution( float rest ); native final function float KGetRestitution(); native final function KAddForce( vector Force ); native final function KAddTorque( vector Torque ); native final function KSetCOMOffset( vector Offset ); native final function KGetCOMOffset( out vector Offset ); native final function KGetCOMPosition( out vector pos ); // get actual position of actors COM in world space native final function KSetImpactThreshold( float thresh ); native final function float KGetImpactThreshold(); native final function KWake(); native final function KAddImpulse( vector Impulse, vector Position ); native final function KSetStayUpright( bool stayUpright, bool allowRotate ); // Disable/Enable Karma contact generation between this actor, and another actor. // Collision is on by default. native final function KDisableCollision( actor Other ); native final function KEnableCollision( actor Other ); // event called when PHYS_Karma actor hits with impact velocity over KImpactThreshold event KImpact(actor other, vector pos, vector impactVel, vector impactNorm); // endif //========================================================================= // Music native final function int PlayMusic( string Song, float FadeInTime ); native final function StopMusic( int SongHandle, float FadeOutTime ); native final function StopAllMusic( float FadeOutTime ); //NEW //========================================================================= // Voice native final function sound PlayVoice( string Filename, optional float Volume, optional float Radius, optional float Pitch ); native final function StopVoice(); native final function StopVoiceFile( string Filename ); //OLD //========================================================================= // Engine notification functions. // // Major notifications. // event /*probe*/ Destroyed(); event /*probe*/ GainedChild( Actor Other ); event /*probe*/ LostChild( Actor Other ); event /*probe*/ Tick( float DeltaTime ); // // Triggers. // //NEW (mdf) cleanup function /*probe*/ Trigger( Actor Other, Pawn EventInstigator, optional name EventName ); function /*probe*/ UnTrigger( Actor Other, Pawn EventInstigator, optional name EventName ); function /*probe*/ BeginEvent(); function /*probe*/ EndEvent(); /*OLD function Trigger( Actor Other, Pawn EventInstigator ); event UnTrigger( Actor Other, Pawn EventInstigator ); event BeginEvent(); event EndEvent(); */ //NEW // // Use interface. // function OnUse( Actor Other ); // used to use a useable actor function OnUnuse( Actor Other ); // used to stop using a useable actor function NotifyUnuse( Actor Other ); // tells using actor that Other is no longer being used function bool IsUsable( optional Actor Other ){ return false; } function string GetDescription(){ return ""; } //OLD // // Physics & world interaction. // event /*probe*/ Timer(); event /*probe*/ HitWall( vector HitNormal, actor HitWall ); //NEW (mdf) falling cleanup (moved to Pawn) /*OLD event Falling(); */ event /*probe*/ Landed( vector HitNormal ); event ZoneChange( ZoneInfo NewZone ); event /*probe*/ PhysicsVolumeChange( PhysicsVolume NewVolume ); event /*probe*/ Touch( Actor Other ); event PostTouch( Actor Other ); // called for PendingTouch actor after physics completes event /*probe*/ UnTouch( Actor Other ); event /*probe*/ Bump( Actor Other ); event /*probe*/ BaseChange(); event /*probe*/ Attach( Actor Other ); event /*probe*/ Detach( Actor Other ); event /*probe*/ Actor SpecialHandling(Pawn Other); event /*probe*/ bool EncroachingOn( actor Other ); event /*probe*/ EncroachedBy( actor Other ); event /*probe*/ EndedRotation(); // called when rotation completes //NEW (mdf) function UsedBy( Pawn user ); //NEW (mb?) called if this Actor was touching a Pawn who pressed Use /*OLD event UsedBy( Pawn user ); //NEW (mb?) called if this Actor was touching a Pawn who pressed Use */ //NEW (mdf) not implemented //OLD event FinishedInterpolation(InterpolationPoint Other); //NEW (mdf) align mesh to surface support -- does this generalize alignment parameters enough? event AlignMeshSpecialHandling( bool bFloating ); //OLD //NEW (mwp) CheckResult and TextureType support event HitWallEx( CheckResult Hit ) { HitWall( Hit.Normal, Hit.Actor ); } // by default redirect all calls to the original event LandedEx( CheckResult Hit ) { Landed( Hit.Normal ); } // functions to maintain backwards compatibility. native(1092) final function bool SingleLineCheck // returns true if nothing was hit ( out CheckResult Hit , Actor Source , vector End , vector Start , int TraceFlags , optional vector Extent ); //OLD event FellOutOfWorld() { SetPhysics(PHYS_None); Destroy(); } // // Damage and kills. // //NEW (mdf) function KilledBy( pawn EventInstigator ); function TakeDamage( int Damage, Pawn EventInstigator, vector HitLocation, vector Momentum, class<DamageType> DamageType); /*OLD event KilledBy( pawn EventInstigator ); event TakeDamage( int Damage, Pawn EventInstigator, vector HitLocation, vector Momentum, class<DamageType> DamageType); */ //NEW (mwp) TraceTexture // Traces and returns the surface texture if one exists. native(1074) final function Material TraceTexture( vector TraceEnd, optional vector TraceStart ); //OLD // // Trace a line and see what it collides with first. // Takes this actor's collision properties into account. // Returns first hit actor, Level if hit level, or None if hit nothing. // native(277) final function Actor Trace ( out vector HitLocation, out vector HitNormal, vector TraceEnd, optional vector TraceStart, optional bool bTraceActors, optional vector Extent, optional out material Material, //NEW (mdf) optional int TraceFlags //OLD ); // returns true if did not hit world geometry native(548) final function bool FastTrace ( vector TraceEnd, optional vector TraceStart ); // // Spawn an actor. Returns an actor of the specified class, not // of class Actor (this is hardcoded in the compiler). Returns None // if the actor could not be spawned (either the actor wouldn't fit in // the specified location, or the actor list is full). // Defaults to spawning at the spawner's location. //NEW (mdf) //NOTE that bDeleteMe could be true for the returned Actor, e.g., if the Actor //was destroyed in the call to eventTouch via the call to CheckEncroachment. //OLD // native(278) final function actor Spawn ( class<actor> SpawnClass, optional actor SpawnOwner, optional name SpawnTag, optional vector SpawnLocation, optional rotator SpawnRotation , optional actor SpawnTemplate //NEW (rlo) , optional actor Spawner // NEW (mib) , optional bool bSkipCollisionCheck // NEW (mdf) ); //NEW (mdf) /* Returns 1 if the actor fits at the given location with the given CollisionRadius/CollisionHeight (optional - defaults to Actor's CollisionRadius/ CollisionHeight)). If the actor was "pushed" out of geometry somewhat in order to fit returns 2 and TargetLocation will be set to the modified location. If the actor doesn't fit, returns 0. */ native final function int FitActorAt( out vector TargetLocation, optional float TargetCollisionRadius, optional float TargetCollisionHeight ); //OLD // // Destroy this actor. Returns true if destroyed, false if indestructable. // Destruction is latent. It occurs at the end of the tick. // native(279) final function bool Destroy(); //============================================================================= // Timing. // Causes Timer() events every NewTimerRate seconds. native(280) final function SetTimer( float NewTimerRate, bool bLoop ); //============================================================================= // Sound functions. //NEW: Golem sound support. simulated final function NotifyPlaySound( string SoundStr ) { local sound Sound; Sound = Sound(DynamicLoadObject( SoundStr, class'Sound' )); if( Sound? ) PlaySound(Sound); else warn("Sound not found:"@SoundStr); } simulated final function NotifyPlaySoundRadius( float Radius, string SoundStr ) { local sound Sound; Sound = Sound(DynamicLoadObject( SoundStr, class'Sound' )); if( Sound? ) PlaySound( Sound, /*slot*/, /*volume*/, /*bNoOverride*/, Radius ); else warn("Sound not found:"@SoundStr); } //OLD /* Play a sound effect. */ native(264) final function PlaySound ( sound Sound, optional ESoundSlot Slot, optional float Volume, optional bool bNoOverride, optional float Radius, optional float Pitch, optional bool Attenuate ); /* play a sound effect, but don't propagate to a remote owner (he is playing the sound clientside) */ native simulated final function PlayOwnedSound ( sound Sound, optional ESoundSlot Slot, optional float Volume, optional bool bNoOverride, optional float Radius, optional float Pitch, optional bool Attenuate ); native simulated event DemoPlaySound ( sound Sound, optional ESoundSlot Slot, optional float Volume, optional bool bNoOverride, optional float Radius, optional float Pitch, optional bool Attenuate ); //NEW (mib) native function PauseAudio( optional bool bPauseMusic ); native function UnPauseAudio(); native function StopSound( sound Sound, optional float FadeOutDuration ); native function StopSoundSlot( ESoundSlot Slot, optional bool bStopNoOverrideSounds ); //OLD /* Get a sound duration. */ native final function float GetSoundDuration( sound Sound ); native final function float GetOggDuration( string Filename ); //NEW (mwp) //----------------------------------------------------------------------------- // Dialog functions. /* Start/Join a dialog session */ function DialogInitiate( Actor Other, optional name Topic, optional Actor WaitingActor ); /* Remove from all dialog sessions */ function DialogTerminate(); /* Notification that we've started talking to Other */ event DialogBegin( Actor Other ); /* Notification that we've stopped all dialog */ event DialogEnd(); /* Notification that NPC AI scripting will be paused (events and timer-based actions can wake up the script) */ function DialogPause(); /* Notification that NPC AI scripting will resume */ function DialogUnPause(); /* face/headtrack this actor during dialog, set to none to look straight ahead */ function DialogSetFocus( Actor FocusActor ); /* sets the focus to use when dialog ends, set to none to clear it */ function DialogSetEndingFocus( Actor FocusActor ); /* ?*/ function bool PreparedForDialog() { return true; } //============================================================================= // AI functions. /* Inform other creatures that you've made a noise they might hear (they are sent a HearNoise message) Senders of MakeNoise should have an instigator if they are not pawns. */ native(512) final function MakeNoise( float Loudness ); /* PlayerCanSeeMe returns true if any player (server) or the local player (standalone or client) has a line of sight to actor's location. */ native(532) final function bool PlayerCanSeeMe(); //============================================================================= // Regular engine functions. // Teleportation. //NEW (mdf) function bool PreTeleport( Teleporter InTeleporter ); function PostTeleport( Teleporter OutTeleporter ); /*OLD event bool PreTeleport( Teleporter InTeleporter ); event PostTeleport( Teleporter OutTeleporter ); */ // Level state. event BeginPlay(); //======================================================================== // Disk access. // Find files. native(539) final function string GetMapName( string NameEnding, string MapName, int Dir ); native(545) final function GetNextSkin( string Prefix, string CurrentSkin, int Dir, out string SkinName, out string SkinDesc ); native(547) final function string GetURLMap(); native final function string GetNextInt( string ClassName, int Num ); native final function GetNextIntDesc( string ClassName, int Num, out string Entry, out string Description ); native final function bool GetCacheEntry( int Num, out string GUID, out string Filename ); native final function bool MoveCacheEntry( string GUID, optional string NewFilename ); //============================================================================= // Iterator functions. // Iterator functions for dealing with sets of actors. /* AllActors() - avoid using AllActors() too often as it iterates through the whole actor list and is therefore slow */ native(304) final iterator function AllActors ( class<actor> BaseClass, out actor Actor, optional name MatchTag ); /* DynamicActors() only iterates through the non-static actors on the list (still relatively slow, bu much better than AllActors). This should be used in most cases and replaces AllActors in most of Epic's game code. */ //NEW (mdf) native(313) final iterator function DynamicActors ( class<actor> BaseClass, out actor Actor, optional name MatchTag, optional float Radius, optional vector Loc ); /*OLD native(313) final iterator function DynamicActors ( class<actor> BaseClass, out actor Actor, optional name MatchTag ); */ /* ChildActors() returns all actors owned by this actor. Slow like AllActors() */ native(305) final iterator function ChildActors ( class<actor> BaseClass, out actor Actor ); /* BasedActors() returns all actors based on the current actor (slow, like AllActors) */ native(306) final iterator function BasedActors ( class<actor> BaseClass, out actor Actor ); /* TouchingActors() returns all actors touching the current actor (fast) */ native(307) final iterator function TouchingActors( class<actor> BaseClass, out actor Actor ); /* TraceActors() return all actors along a traced line. Reasonably fast (like any trace) */ native(309) final iterator function TraceActors ( class<actor> BaseClass, out actor Actor, out vector HitLoc, out vector HitNorm, vector End, optional vector Start, optional vector Extent ); /* RadiusActors() returns all actors within a give radius. Slow like AllActors(). Use CollidingActors() or VisibleCollidingActors() instead if desired actor types are visible (not bHidden) and in the collision hash (bCollideActors is true) */ native(310) final iterator function RadiusActors ( class<actor> BaseClass, out actor Actor, float Radius, optional vector Loc ); /* VisibleActors() returns all visible actors within a radius. Slow like AllActors(). Use VisibleCollidingActors() instead if desired actor types are in the collision hash (bCollideActors is true) */ native(311) final iterator function VisibleActors ( class<actor> BaseClass, out actor Actor, optional float Radius, optional vector Loc ); /* VisibleCollidingActors() returns visible (not bHidden) colliding (bCollideActors==true) actors within a certain radius. Much faster than AllActors() since it uses the collision hash */ native(312) final iterator function VisibleCollidingActors ( class<actor> BaseClass, out actor Actor, float Radius, optional vector Loc, optional bool bIgnoreHidden ); /* CollidingActors() returns colliding (bCollideActors==true) actors within a certain radius. Much faster than AllActors() for reasonably small radii since it uses the collision hash */ //NEW (mdf) Fix: clashes with Object natives native simulated final iterator function CollidingActors ( class<actor> BaseClass, out actor Actor, float Radius, optional vector Loc ); /*OLD native(321) final iterator function CollidingActors ( class<actor> BaseClass, out actor Actor, float Radius, optional vector Loc ); */ //============================================================================= // Color functions native(549) static final operator(20) color - ( color A, color B ); native(550) static final operator(16) color * ( float A, color B ); native(551) static final operator(20) color + ( color A, color B ); native(552) static final operator(16) color * ( color A, float B ); //============================================================================= // Scripted Actor functions. /* RenderOverlays() called by player's hud to request drawing of actor specific overlays onto canvas */ /*NEW: removed (ARL) function RenderOverlays(Canvas Canvas); */ //NEW MB // Callback hook for changing properties during Spawn, before PreBeginPlay event ModifyDefaultProperties( actor SpawningActor ); //OLD //NEW (mdf) function bool ShouldDestroy() { if ( !bGameRelevant && Level.Game != None // Added check for GameInfo, in case this gets called in the editor (GameInfo doesn't exist in the Editor, and there's no easy way to tell if we're in the Editor). && ( !IsDifficultyOK() || !IsDetailLevelOK() || !IsGoreOK() || Level.Game.BaseMutator != None //Since an actor can be spawned before the gameinfo is set up, like when the PhysicsVolume is spawned upon load for unconvered maps && !Level.Game.BaseMutator.CheckRelevance( self ) ) ) { return true; } return false; } // // Called immediately before gameplay begins. // simulated //NEW event PreBeginPlay() { // Handle autodestruction if desired. //NEW (mdf) //DMTNS( "PreBeginPlay called for " $ Self $ " bEditorPlaced:" $ bEditorPlaced ); if( ShouldDestroy() ) { AutoDestroy(); } else { bEditorPlaced = default.bEditorPlaced || Level.bStartup; bHiddenUsable = bHidden && IsUsable(); //NEW Set up hidden usable actors to be traced based on their initial usability. } /*OLD if( !bGameRelevant && (Level.NetMode != NM_Client) && !Level.Game.BaseMutator.CheckRelevance(Self) ) Destroy(); */ } //NEW (mib) self-destruction function AutoDestroy() { Destroy(); } //OLD // // Broadcast a localized message to all players. // Most message deal with 0 to 2 related PRIs. // The LocalMessage class defines how the PRI's and optional actor are used. // //NEW (mdf) function BroadcastLocalizedMessage( class<LocalMessage> MessageClass, optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2, optional Object OptionalObject ) /*OLD event BroadcastLocalizedMessage( class<LocalMessage> MessageClass, optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2, optional Object OptionalObject ) */ { Level.Game.BroadcastLocalized( self, MessageClass, Switch, RelatedPRI_1, RelatedPRI_2, OptionalObject ); } //NEW: CDH... mounting // find actor based on tag (utility function) simulated final function actor FindActorByTag(class<actor> ActorClass, name ActorName) { local actor result, a; if (ActorName=='') return(None); if (ActorClass==None) ActorClass = class'Actor'; result = None; foreach AllActors(ActorClass, a, ActorName) { result = a; // stop at first find break; } return(result); } function MountSetParent(actor InParent) { local actor a; MountParentActor = InParent; if (MountParentActor==None) { MountParentTag = ''; return; } MountParentTag = MountParentActor.Tag; if (MountParentNode=="") { if (MountOrgLocation == vect(0,0,0)) MountOrgLocation = (Location - MountParentActor.Location) << MountParentActor.Rotation; if (MountOrgRotation == rot(0,0,0)) MountOrgRotation = Rotation - MountParentActor.Rotation; } MountOldLocation = Location; MountOldRotation = Rotation; } //OLD: ...CDH mounting // Called immediately after gameplay begins. // event PostBeginPlay() { local actor a; if ((MountParentActor==None) && (MountParentTag!='')) { a = FindActorByTag(None, MountParentTag); if (a!=None) MountSetParent(a); } } // Called after PostBeginPlay. // simulated event SetInitialState() { bScriptInitialized = true; if( InitialState!='' ) GotoState( InitialState ); else GotoState( 'Auto' ); } //NEW MJL: use PostRecv<VarName>() instead: it's safer /* OLD // called after PostBeginPlay. On a net client, PostNetBeginPlay() is spawned after replicated variables have been initialized to // their replicated values event PostNetBeginPlay(); */ /* HurtRadius() Hurt locally authoritative actors within the radius. */ //NEW simulated final function HurtRadius( float DamageAmount, float DamageRadius, class<DamageType> DamageType, float Momentum, vector HitLocation, optional bool bNoFalloff ) /*OLD simulated final function HurtRadius( float DamageAmount, float DamageRadius, class<DamageType> DamageType, float Momentum, vector HitLocation ) */ { local actor Victims; local float damageScale, dist; local vector dir; //DMTNS( "HurtRadius " $ DamageAmount @ DamageRadius ); if( bHurtEntry ) return; //NEW (mdf) if( DamageRadius <= 0 || (DamageAmount <= 0 && Momentum <= 0.0) ) return; //OLD bHurtEntry = true; //!!mdf-tbd: VCA seems to be really slow -- should it be avoided/fixed? foreach VisibleCollidingActors( class 'Actor', Victims, DamageRadius, HitLocation ) { if( (Victims != self) && (Victims.Role == ROLE_Authority) ) { dir = Victims.Location - HitLocation; dist = FMax(1,VSize(dir)); dir = dir/dist; damageScale = 1 - FClamp((dist - Victims.CollisionRadius)/DamageRadius,0,1); //NEW // damageScale = 1 - FMax(0,(dist - Victims.CollisionRadius)/DamageRadius); //OLD //NEW (arl) if( bNoFalloff ) damageScale = 1.0; //OLD //NEW (mdf) if( damageScale > 0.0 ) //OLD Victims.TakeDamage ( damageScale * DamageAmount, Instigator, Victims.Location - 0.5 * (Victims.CollisionHeight + Victims.CollisionRadius) * dir, (damageScale * Momentum * dir), DamageType ); } } bHurtEntry = false; } // Called when carried onto a new level, before AcceptInventory. // event TravelPreAccept(); // Called when carried into a new level, after AcceptInventory. // event TravelPostAccept(); // Called by PlayerController when this actor becomes its ViewTarget. // function BecomeViewTarget(); // Returns the string representation of the name of an object without the package // prefixes. // //NEW (mdf) Fix static function String GetItemName( string FullName ) /*OLD function String GetItemName( string FullName ) */ { local int pos; pos = InStr(FullName, "."); While ( pos != -1 ) { FullName = Right(FullName, Len(FullName) - pos - 1); pos = InStr(FullName, "."); } return FullName; } function bool IsPlayer(){ return false; } //NEW -- Actor is a player/bot function bool IsRealPlayer(){ return false; } //NEW -- Actor is a real (live) player function bool IsNPC(){ return false; } //NEW -- Actor is an NPC // // Returns the human readable string representation of an object. // // CHANGED function name from GetHumanName() function String GetHumanReadableName() { return GetItemName(string(class)); } final function ReplaceText(out string Text, string Replace, string With) { local int i; local string Input; Input = Text; Text = ""; i = InStr(Input, Replace); while(i != -1) { Text = Text $ Left(Input, i) $ With; Input = Mid(Input, i + Len(Replace)); i = InStr(Input, Replace); } Text = Text $ Input; } // Set the display properties of an actor. By setting them through this function, it allows // the actor to modify other components (such as a Pawn's weapon) or to adjust the result // based on other factors (such as a Pawn's other inventory wanting to affect the result) function SetDisplayProperties(ERenderStyle NewStyle, Material NewTexture, bool bLighting ) { Style = NewStyle; texture = NewTexture; bUnlit = bLighting; } function SetDefaultDisplayProperties() { Style = Default.Style; texture = Default.Texture; bUnlit = Default.bUnlit; } // Get localized message string associated with this actor static function string GetLocalString( optional int Switch, optional PlayerReplicationInfo RelatedPRI_1, optional PlayerReplicationInfo RelatedPRI_2 ) { return ""; } function MatchStarting(); // called when gameplay actually starts /* DisplayDebug() list important actor variable on canvas. HUD will call DisplayDebug() on the current ViewTarget when the ShowDebug exec is used */ simulated function DisplayDebug(Canvas Canvas, out float YL, out float YPos) { local string T; local float XL; local int i; local Actor A; local name anim; local float Frame,Rate,Blend; Canvas.Style = ERenderStyle.STY_Normal; Canvas.StrLen("TEST", XL, YL); YPos = YPos + YL; Canvas.SetPos(4,YPos); Canvas.SetDrawColor(255,0,0); T = GetItemName(string(self)); if ( bDeleteMe ) T = T$" DELETED (bDeleteMe == true)"; Canvas.DrawText(T, false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.SetDrawColor(255,255,255); if ( Level.NetMode != NM_Standalone ) { // networking attributes T = "ROLE "; Switch(Role) { case ROLE_None: T=T$"None"; break; case ROLE_DumbProxy: T=T$"DumbProxy"; break; case ROLE_SimulatedProxy: T=T$"SimulatedProxy"; break; case ROLE_AutonomousProxy: T=T$"AutonomousProxy"; break; case ROLE_Authority: T=T$"Authority"; break; } T = T$" REMOTE ROLE "; Switch(RemoteRole) { case ROLE_None: T=T$"None"; break; case ROLE_DumbProxy: T=T$"DumbProxy"; break; case ROLE_SimulatedProxy: T=T$"SimulatedProxy"; break; case ROLE_AutonomousProxy: T=T$"AutonomousProxy"; break; case ROLE_Authority: T=T$"Authority"; break; } if ( bTearOff ) T = T$" Tear Off"; Canvas.DrawText(T, false); YPos += YL; Canvas.SetPos(4,YPos); } T = "Physics "; Switch(PHYSICS) { case PHYS_None: T=T$"None"; break; case PHYS_Walking: T=T$"Walking"; break; case PHYS_Falling: T=T$"Falling"; break; case PHYS_Swimming: T=T$"Swimming"; break; case PHYS_Flying: T=T$"Flying"; break; case PHYS_Rotating: T=T$"Rotating"; break; case PHYS_Projectile: T=T$"Projectile"; break; case PHYS_Interpolating: T=T$"Interpolating"; break; case PHYS_MovingBrush: T=T$"MovingBrush"; break; case PHYS_Spider: T=T$"Spider"; break; case PHYS_Trailer: T=T$"Trailer"; break; case PHYS_Ladder: T=T$"Ladder"; break; } T = T$" in physicsvolume "$GetItemName(string(PhysicsVolume))$" on base "$GetItemName(string(Base)); if ( bBounce ) T = T$" - will bounce"; Canvas.DrawText(T, false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("Location: "$Location, false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("Rotation: "$Rotation, false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("Velocity: "$Velocity$" Speed "$VSize(Velocity), false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("Acceleration: "$Acceleration, false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawColor.B = 0; Canvas.DrawText("Collision Radius "$CollisionRadius$" Height "$CollisionHeight); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("Collides with Actors "$bCollideActors$", world "$bCollideWorld$", and proj. target "$bProjTarget); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("Blocks Actors "$bBlockActors$", players "$bBlockPlayers); YPos += YL; Canvas.SetPos(4,YPos); T = "Touching "; ForEach TouchingActors(class'Actor', A) T = T$GetItemName(string(A))$" "; if ( T == "Touching ") T = "Touching nothing"; Canvas.DrawText(T, false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawColor.R = 0; T = "Rendered: "; Switch(Style) { case STY_None: T=T; break; case STY_Normal: T=T$"Normal"; break; case STY_Masked: T=T$"Masked"; break; case STY_Translucent: T=T$"Translucent"; break; case STY_Brighten: T=T$"Brighten"; break; //NEW (mw) case STY_Modulated: T=T$"Modulated"; break; case STY_Alpha: T=T$"Alpha"; break; } Switch(DrawType) { case DT_None: T=T$" None"; break; case DT_Sprite: T=T$" Sprite "; break; case DT_Mesh: T=T$" Mesh "; break; case DT_Brush: T=T$" Brush "; break; case DT_RopeSprite: T=T$" RopeSprite "; break; case DT_VerticalSprite: T=T$" VerticalSprite "; break; case DT_Terraform: T=T$" Terraform "; break; case DT_SpriteAnimOnce: T=T$" SpriteAnimOnce "; break; case DT_StaticMesh: T=T$" StaticMesh "; break; } if ( DrawType == DT_Mesh ) { T = T$Mesh; if ( Skins.length > 0 ) { T = T$" skins: "; for ( i=0; i<Skins.length; i++ ) { if ( skins[i] == None ) break; else T =T$skins[i]$", "; } } Canvas.DrawText(T, false); YPos += YL; Canvas.SetPos(4,YPos); // mesh animation GetAnimParams(0,Anim,Frame,Rate,Blend); T = "AnimSequence "$Anim$" Frame "$Frame$" Rate "$Rate; if ( bAnimByOwner ) T= T$" Anim by Owner"; } else if ( (DrawType == DT_Sprite) || (DrawType == DT_SpriteAnimOnce) ) T = T$Texture; else if ( DrawType == DT_Brush ) T = T$Brush; Canvas.DrawText(T, false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawColor.B = 255; Canvas.DrawText("Tag: "$Tag$" Event: "$Event$" STATE: "$GetStateName(), false); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("Instigator "$GetItemName(string(Instigator))$" Owner "$GetItemName(string(Owner))); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("Timer: "$TimerCounter$" LifeSpan "$LifeSpan); YPos += YL; Canvas.SetPos(4,YPos); Canvas.DrawText("AmbientSound "$AmbientSound); YPos += YL; Canvas.SetPos(4,YPos); } // NearSpot() returns true is spot is within collision cylinder // FIXME - make intrinsic //NEW (mdf) /* NOTE: should *NOT* be used in conjunction with MoveToActor -- use AtDestinationPoint/Actor instead since NearSpot and MoveToActor can end up "disagreeing" about whether the destination was reached (each uses different tests) which can result in an NPC not being able to move (if script code thinks NPC hasn't arrived but call to MoveToActor returns immediately for example). Both MoveToActor and AtDestinationPoint/Actor map to the exact same code for determining whether a final destination was reached. NearSpot can be used any time code wants to determine if given location is at least partly inside the Actor's collision cylinder but this result should not be used to inform calls to MoveToActor. */ //OLD simulated final function bool NearSpot(vector Spot) { local vector Dir; Dir = Location - Spot; if ( abs(Dir.Z) > CollisionHeight ) return false; Dir.Z = 0; return ( VSize(Dir) <= CollisionRadius ); } simulated final function bool TouchingActor(Actor A) { local vector Dir; Dir = Location - A.Location; if ( abs(Dir.Z) > CollisionHeight + A.CollisionHeight ) return false; Dir.Z = 0; return ( VSize(Dir) <= CollisionRadius + A.CollisionRadius ); } // returns true if shortest rotation direction is in the positive (clockwise) direction // from A to B function bool PlusDir(int A, int B) { A = A & 65535; B = B & 65535; if ( Abs(A - B) > 32768 ) return ( A - B < 0 ); return ( A - B > 0 ); } /* StartInterpolation() when this function is called, the actor will start moving along an interpolation path beginning at Dest */ simulated function StartInterpolation() { GotoState(''); SetCollision(True,false,false); bCollideWorld = False; bInterpolating = true; SetPhysics(PHYS_None); } /* Reset() reset actor to initial state - used when restarting level without reloading. */ function Reset(); /* Trigger an event */ event TriggerEvent( Name EventName, Actor Other, Pawn EventInstigator ) { //NEW class'TriggerHelper'.static.TriggerActors( Self, class'Actor', Other, EventInstigator, EventName, true ); /*OLD local Actor A; if ( (EventName == '') || (EventName == 'None') ) return; ForEach DynamicActors( class 'Actor', A, EventName ) A.Trigger(Other, EventInstigator); // if triggered event is actor's event, check if it should be registered as persistent game event if ( (EventName == Event) && (Level.Game != None) ) { if ( bTravelGameEvent ) Level.Game.AddTravelGameEvent(EventName); else if ( bLocalGameEvent ) Level.Game.AddLocalGameEvent(EventName); } */ } /* Untrigger an event */ function UntriggerEvent( Name EventName, Actor Other, Pawn EventInstigator ) { local Actor A; if ( (EventName == '') || (EventName == 'None') ) return; ForEach DynamicActors( class 'Actor', A, EventName ) //NEW (mdf) A.Untrigger( Other, EventInstigator, EventName ); /*OLD A.Untrigger(Other, EventInstigator); */ } function bool IsInVolume(Volume aVolume) { local Volume V; ForEach TouchingActors(class'Volume',V) if ( V == aVolume ) return true; return false; } function bool IsInPain() { local PhysicsVolume V; ForEach TouchingActors(class'PhysicsVolume',V) if ( V.bPainCausing && (V.DamagePerSec > 0) ) return true; return false; } function bool CanSplash() { return false; } //NEW (mdf) function StopMovement( bool bKillAcceleration, bool bKillVelocity ) { if( bKillAcceleration ) Acceleration = vect(0,0,0); if( bKillVelocity ) Velocity = vect(0,0,0); } // Actors can return false if the AttackingController shouldn't be allowed to hit it with an attack. function bool CanHit( Controller AttackingController ) { return true; } // defaults to the game's difficulty, specific classes, e.g. AI, can alter this function float GetSkill() { return Level.Game.GetNormalizedDifficulty(); } //OLD //NEW: Debug //----------------------------------------------------------------------------- function GetAgentAnimInfo( out array<string> InfoStrings ) { local int Count, i; local name ChanSeq, DepChanSeq; local float ChanFrame, ChanRate, ChanBlend; local float DepChanFrame, DepChanRate, DepChanBlend; local int ChanFrameCount; local int ChanBoundLevel; Count = MeshAgentGetChannelCount(); if (Count == 0) return; for (i=0;i<Count;i++) { GetAnimParams(i, ChanSeq, ChanFrame, ChanRate, ChanBlend); GetAnimParams(i, DepChanSeq, DepChanFrame, DepChanRate, DepChanBlend, true); ChanFrameCount = 0; if (ChanSeq!='') ChanFrameCount = GetAnimFrames(ChanSeq); if (ChanFrameCount!=0) ChanFrame = ChanFrame*ChanFrameCount; else ChanFrame = 0.f; ChanBoundLevel = MeshAgentGetChannelBoundLevel(i); InfoStrings[InfoStrings.Length] = class'Util'.static.PadString( " Channel[" $ i $ ":" $ MeshAgentGetChannelName(i) $ "]", 25 ); InfoStrings[InfoStrings.Length-1] = InfoStrings[InfoStrings.Length-1] $ "Anim=("$ChanSeq$"("$DepChanSeq$"), "$class'Util'.static.GetFloatString(ChanFrame)$"/"$class'Util'.static.GetFloatString(float(ChanFrameCount))$")," @ "Script="$MeshAgentGetChannelScriptName(i)$", " ; if (ChanBoundLevel > 0) { InfoStrings[InfoStrings.Length-1] = InfoStrings[InfoStrings.Length-1] $ "Bound("$(ChanBoundLevel-1)$")=("$MeshAgentGetChannelBoundAction(i)$", "$class'Util'.static.GetFloatString(MeshAgentGetChannelBoundTime(i))$")"; } else { InfoStrings[InfoStrings.Length-1] = InfoStrings[InfoStrings.Length-1] $ "Unbound"; } } } //------------------------------------------------------------------------------ function GetAgentInputInfo( out array<string> Strings ) { local int Count, i; local name InputName; Count = MeshAgentGetInputCount(); for (i=0;i<Count;i++) { InputName = MeshAgentGetInputName(i); Strings[Strings.Length] = class'Util'.static.PadString( " Input["$i$":"$InputName$"]", 25 ); Strings[Strings.Length-1] = Strings[Strings.Length-1] $ MeshAgentGetInputCurValue(InputName); } } //------------------------------------------------------------------------------ // unfiltered broadcast Msg to all (real) players simulated final function BM( coerce string Msg ) { local Controller C; for (C=Level.ControllerList;C!=None;C=C.NextController) if (PlayerController(C)!=None) PlayerController(C).ClientMessage(Msg); } //------------------------------------------------------------------------------ // echo Msg to all (real) players and to log simulated final function DM( coerce string Msg, optional bool bNoBM, optional bool bNoLog, optional name Tag ) { if( !bNoBM ) BM( Msg ); if( !bNoLog ) { if( Tag == '' ) Tag = 'DM'; Log( default.IndentStr $ Msg, Tag ); } } //------------------------------------------------------------------------------ // DM with name appended. simulated final function DMN( coerce string Msg, optional bool bNoBM, optional bool bNoLog, optional name Tag ) { DM( Name $ " " $ Msg, bNoBM, bNoLog, Tag ); } //------------------------------------------------------------------------------ // DM with time appended. simulated final function DMT( coerce string Msg, optional bool bNoBM, optional bool bNoLog, optional name Tag ) { DM( class'Util'.static.GetPaddedTime( Level.TimeSeconds, 8, true ) $ " " $ Msg, bNoBM, bNoLog, Tag ); } //------------------------------------------------------------------------------ // DMT with name appended. simulated final function DMTN( coerce string Msg, optional bool bNoBM, optional bool bNoLog, optional name Tag ) { DMT( Name $ " " $ Msg, bNoBM, bNoLog, Tag ); } //----------------------------------------------------------------------------- // DMTN with state prepended. simulated function final DMTNS( coerce string Msg, optional bool bNoBM, optional bool bNoLog, optional name Tag ) { DMTN( GetStateName() $ " " $ Msg, bNoBM, bNoLog, Tag ); } //------------------------------------------------------------------------------ // currently just an alias for TraceMessage -- see Object.uc simulated final function TM( name TraceName, Actor ContextActor, coerce string Msg ) { TraceMessage( TraceName, ContextActor, default.IndentStr $ Msg ); } //------------------------------------------------------------------------------ // hack for temporarily turning TM's into DMT's simulated final function DTM( name TraceName, Actor ContextActor, coerce string Msg ) { Msg = class'Util'.static.GetPaddedTime( Level.TimeSeconds, 8, true ) $ " " $ ContextActor.Name $ " " $ Msg; BM( class'Util'.static.PadString(TraceName, 11 ) $ Msg ); Log( default.IndentStr $ " " $ Msg, 'TM' ); } //----------------------------------------------------------------------------- static final function ID() { default.IndentStr = default.IndentStr $ " "; if( Len(default.IndentStr) >= 64 ) warn( "ID more than 32 levels deep?" ); } //----------------------------------------------------------------------------- static final function OD() { if( default.IndentStr == "" ) warn( "mismatched OD/ID pair?" ); default.IndentStr = Left( default.IndentStr, Len(default.IndentStr)-2 ); } //----------------------------------------------------------------------------- function DMAssert( bool bTestCondition, coerce string Msg, optional coerce string Prefix ) { local bool bDebugMode; if( !bTestCondition ) { #debug bDebugMode = true; if( Prefix != "" ) { if( bDebugMode ) DM( Prefix $ "WARNING (ASSERT!): " $ Msg ); else Log( Prefix $ "WARNING (ASSERT!): " $ Msg ); } else { if( bDebugMode ) DMT( "WARNING (ASSERT!): " $ Msg ); else Log( class'Util'.static.GetPaddedTime( Level.TimeSeconds, 8, true ) $ "WARNING (ASSERT!): " $ Msg ); } assert( true ); // <-- DO NOT CHECK IN UNLESS TRUE (use assert directly otherwise) } } //OLD defaultproperties { DrawType=DT_Sprite bUseDynamicLights=true bIgnoreSingularityDamage=true bIgnoreSingularityForces=true bReplicateMovement=true bDifficulty0=true bDifficulty1=true bDifficulty2=true SwingGravDir=(Z=-1.000000) Role=ROLE_Authority RemoteRole=ROLE_DumbProxy LODBias=1.000000 FallingMaxVelocityZ=-10000000.000000 FallingMaxVelocityXY=10000000.000000 ActorTimeDilation=1.000000 Texture=Texture'Engine.S_Actor' DrawScale=1.000000 DrawScale3D=(X=1.000000,Y=1.000000,Z=1.000000) ScaleGlow=1.000000 RenderBoundFactor=1.000000 Style=STY_Normal bMustFace=true bMovable=true SoundRadius=64.000000 SoundVolume=128 SoundPitch=64 TransientSoundVolume=1.000000 TransientSoundRadius=80.000000 CollisionRadius=22.000000 CollisionHeight=22.000000 bBlockZeroExtentTraces=true bBlockNonZeroExtentTraces=true bCanMantle=true LightPriority=1.000000 bJustTeleported=true Mass=100.000000 NetPriority=1.000000 NetUpdateFrequency=100.000000 MessageClass=Class'Engine.LocalMessage' UseReticleOnEvents(0)="UseReticleText" UseReticleOnEvents(1)="UseReticleCorners" UseReticleOnEvents(2)="UseReticleTopBars" ProximityReticleOnEvents(0)="ProximityReticleCorners" ProximityReticleOnEvents(1)="ProximityReticleTopBars" bPreMission01=true bPreMission02=true bPreMission03=true bPreMission04=true bPreMission05=true bPreMission06=true bPreMission07=true bPreMission08=true bPreMission09=true bPreMission10=true bPreMission11=true bPreMission12=true } |
Overview | Package | Class | Source | Class tree | Glossary | UnrealScript Documentation |
previous class next class | frames no frames |