Jump to content

Ishad Nha

Member
  • Posts

    2,420
  • Joined

  • Last visited

Everything posted by Ishad Nha

  1. What about get_stat(36)? A quick test shows that it does actually work in practice. Is this code of yours meant for PCs or monsters or both? If you have problems with the get_stat(36) including the effects of adjustments from items, such items aren't all that common. For instance the editor documentation states: "Note that you can’t change Health or Spell Energy with an item, and changes to Intelligence and Endurance won’t change Health or Spell Energy".
  2. Spoiler: the encounter is actually with a Sprite found in another outdoor section, you have to be generous to him. He then tells you where to go and who you will meet, Shaynee a dryad.
  3. Do you mean the south side of the Spire of Ages? Walk in cardinal directions from some of those rocks, but you must have a certain special encounter first.
  4. One thing that I have noticed: if you edit your post, this won't show up in the list of posts and when they were last edited. Especially if yours is the last post in a given topic. Thus the post above was orginally written on November 3, it was then edited several times. But the Blades of Avernum Editor forum always listed "November 3" in its list of posts.
  5. I will have to send you v1.1 of the River and Leaf port, when I get around to finishing it. It features a few corrections to town and boat entrance problems. Above all else, it features an attempt to systematically use Geneforge graphics in a BoA scenario.
  6. One possible shortcut is the source code for the Windows 3D Editor. If you could figure out how to get that to compile on a standard Windows compiler, others might be able to do the rest from there. This code already has the graphics hassles resolved.
  7. I downloaded a "Dialog Editor Source Code.zip", it has a vestigial 1Kb MacOSX fork. It is 38Kb, is that the one you are looking for? I can email it to you and let you check it. Edit: the Mac version has a purely vestigial OSX fork too. Maybe it is not the Windows version.
  8. As for the Geneforge graphics themselves, one thing that I could not help noticing: in the actual game the automap icons are derived from the editor icons. There are editor icons found in all the Geneforge games, look around G1600.bmp, but they are in many cases a bit crude for use in the automap. So I have had to design my own. Edit: I have had some luck converting the Geneforge 4 and Avernum 4 graphics to BoA format. One success is the logs in 1313.bmp. Things like the brazier in 1490.bmp are easy to convert because they are smaller than usual BoA terrain types. I am currently working on the floor graphics. Floors are easy, they can just be reduced in size. However there will be distortion if the floor had a distinct pattern. For instance some of those carpets in Geneforge 4. One solution, that may or may not work, is to use only a part of the original graphic. Thus the A4 stairs going into ground graphics, 1370.bmp &, were easily ported to BoA format. This won't work if there is something special about the border of the graphic proper. In GF4, 1250.bmp, the first three icons will look funny if this technique is used: the outside edges won't join in the proper pattern. The mask can be removed in one hit by the methods used for the "snow" above. Ditto if you want to remove part of a group of pictures. Say you want to use the hills parts of "flboehil.png" with other floor types. (This graphic is the "Hills" part of the Blazing Blades BoA Pics - Floors sheet.) Thus you can remove the grass part which will leave only the desired hills. Walls are in need of special masks. I have devised a mask which lines up correctly with the original GF4/A4 graphic. It has an external black border which lines up with the border of the original graphic, then the intended BoA borders lie inside this. Doors are tough, they are much bigger than the BoA doors, so far I have not been able to solve this problem.
  9. What we really need for things like the boulders is a graphics program that lets you see the same graphic at both 100% and 400%, at the same time. That way you can see immediately and exactly what the effect of deleting a particular pixel is. While we are at it, if graphics are so tricky maybe we should compile a list of useful programs.
  10. Yes, the snow is RGB = 255,255,253 or some such combination. The snow can be removed in one hit by the use of a transparency function set to a color similarity of 1%. However Bitmaps don’t support the transparency function. One option is to convert the jpg to a png, then reduce the resulting png from 24-bit to 8-bit. Reading the help file for the Microsoft Photo Editor: “PNG saves images as 8-bit or 24-bit images. In 24-bit images, PNG saves transparency in an alpha channel. In 8-bit images, PNG substitutes a transparent color on the palette.” What we want here is the transparency option not the alpha channel. Thus the trick is to go into File > Properties and choose “Palette or 256 color (8 bit)” type. Then save the file and exit the editor. Next open the file in Paint and save as 24 – bit Bitmap Another option is to deal with the pixels individually; the file is left as 24-bit. What is really needed is a replace – one - color - with - another function. If the transparency function has the “Color similarity: Exact” setting, if 255,255,255 is deleted, a lot of the snow will then show up clearly. In the Editor you can’t delete near – transparent colors, but the information will be a guide in the Paint program where you can delete. Pixel view is 400%, there it only takes a few minutes to clean up one icon. You can use varying sizes of erasers, and a pencil if needs be. As for deleting backgrounds from boulders, like the graphics for terrain types 128 thru 136, sometimes I am not too sure whether a given pixel is wanted or not.
  11. The Geneforge problem was actually simple to understand and solve. I went into Windows Explorer and looked at the directory where the original jpg images were stored. Perusing the Size and Dimensions columns showed that most of the jpgs had a size (in bytes) slightly larger than the area (width x height) of the image. Hence they were 1 byte or 8 – bit images, whereas the images giving me all the “snow” I had saved as 24 – bit. Problem solved.
  12. The Geneforge graphics found on the Louvre site really look good. Unfortunately using the grass floor in a BoA scenario leads to white "snow" at the edge of the screen. This is only a problem with the Geneforge graphics, all other custom graphics work well. (When other custom graphics are at the edge of the screen the snow disappears.) I think this is due to the original Geneforge graphics being reduced in size. It was also a problem with other Geneforge graphics, like the hot pads on the floor. In the latter case I manually cleaned up the white border zone, that seemed to work. Has anyone else struck this problem? While on the subject of graphics, how did Niemand do those boulders on his site? I tried the same thing with the grass and boulder graphics, turning one color transparent at a time. I used the Microsoft Photo Editor, the results were passable but not perfect.
  13. If we are discussing the icon_adjust calls, they work well enough. But you have to hit the tab key in the 3D Editor to see what they do, because the ed_icon_adjust calls do nothing. I view the effect as being best when the base graphic is colorful unlike the floor type 0 icons. If an icon has no red or blue it won't be affected by an adjustment that swaps red and blue.
  14. Certain page numbers are the best approximation that I can give. I was trying to find the most logical place in the help file to list the corrections. Page 41 is the best place to list corrections and clarifications for beam projectors. A subject like "boats" has no clear entry in the file, there are a few entries here and there. Outdoor scripts, the init_state seems to fail to work more often than not. It is actually Amnesia that had the problem with searchable walls, the Amnesia Readme.txt mentions the problem. If Dikiyoba or anyone else wants to publish a list then fine.
  15. I am just rehashing the contents of TSE and the Editor help docs. Most of the stuff written by other people I have not checked myself. If there is no explicit credit given in my post above, the comment was originally written by Kelandon. Personally I don't know when containers break, or what break means, disappear? If te_can_look_at is hard coded that might explain problems in one of the scenarios with custom walls, (was it Foul Hordes?). Here we can only make a list of which terrains are hard - coded for this call. Having the list, designers may be able to work around it.
  16. This is a draft list of certain bugs, listed according to the order found in the BoA Editor Help file, part 1. All page numbers come from the PDF file BoA Editor Docs v12.pdf, this is done to provide a standardized page numbering system. The Word documents are hard to read so people may edit them, thus altering the numbering system. TSE = the Windows Technical Support for the Editor. Bugs in the Editor itself: I didn’t include these because some may have been corrected in the various Mac versions. Further they can be removed by re – compiling the editor. Chapter 1.4: Using the Editor Page 18, Ishad Nha: The commands in the Edit menu are not explained in the Editor Help menu. Lines 886… of the source file “Bl A Editor.c” suggest that the commands involve copying and pasting of creatures, items and terrain scripts. Chapter 1.5: Editing Terrain Page 22, Ishad Nha: It seems that a town entrance won’t work from the outdoors if the relevant square has a terrain type that is impassable to the party. Ditto, there may be problems if the town entrance rectangle is smaller than 3x3. A lot of the trouble in A Large Rebellion in the Alexandra area came from this. There may be problems, I don’t know exactly when they occur. Boats generally. Using A Large Rebellion as an example: the boat entering t3 from the east, from t10, always arrives at the east town entrance wherever that may be. It doesn’t have any connection to state 13 in t10.txt. If the move_to_new_town call doesn’t work when the party is in a boat, town entrances should be used for this case. Save the special encounters for when the party is walking along a footpath. Actually the encounter does something, it moves the party to a new town. Suddenly reversing a boat onto a special encounter can cause it to enter a town on the wrong side. The direction the boat is facing may cause this error. It seems that the boat is sent to the wrong town entrance, (and when it arrives inside a town it is always located on one of the four town entrance squares?) Chapter 1.7: Editing Towns Page 32: Set Town Boundaries - * Putting a town border right next to the edge of the town causes weird behavior: you can't exit the town, the town doesn't match the edge, etc. Page 33, Ishad Nha: Totally Dark seems not to happen in actual practice if the “Town is on surface” box is checked. Page 41:* Beam projectors malfunction wildly in close quarters, next to walls, in varying heights, etc. I have a small utility scenario to demonstrate a number of ways in which this can occur. TSE: Beam terrains (projectors, power sources, etc.) are always drawn animated. This is because the game handles these terrain types differently. If you want to draw one of these terrains without animation, make a custom terrain graphic and copy the icon into it. TSE: If a terrain type a beam can crumble and a mirror are in the same spot; the terrain will always crumble, even if the mirror would reflect it. As a workaround, use crumbling terrains that fill the whole space, or place crumbling walls so that the party can't push a mirror into their space until the wall is crumbled. Chapter 2.2: Creating Custom Objects Page 44: Corescendata and default graphic errors * Floors 85 and 86 have fl_ed_which_icon reversed. Floor 85 should have icon 7, and floor 86 should have icon 6. * The slith avatar, (creature 100), in order to match Avernum 1, should not have the graphic of a gorgon, which is what it has now. Two calls need to be added: cr_which_sheet = 1532 and cr_icon_adjust = 2, as Bahssikava does. * In corescendata, Augmented Giant (creature 135) ought to have the line "cr_which_sheet_upper = 1618;" * The efreet (creature 174) has cr_natural_armor defined twice, the first time as 15 and the second time as 50. * As far as I can tell, aranea (and elder aranea), (creatures 71 and 83), default to carrying pots. I'm assuming that item 373 was aranea fangs, once upon a time. * In corescendata2.txt Terrains #172 and #173 (fences) have an incorrect name. The line te_name = "Fence"; needs to be added to them. As far as I can tell, terrains 172 and 173 (in addition to being mis-named) default to not showing up on the automap. I tried to add the line te_draw_on_automap = 1; but this did not seem to help. Their graphics are properly set. * In corescendata2.txt Terrain #331 and #332 (underground hillside cave entrances) import the incorrect terrain. This causes problems with the automatic hills functionality of the editor. It will also cause the party to be drawn incorrectly when upon these terrains. * In corescendata2.txt Terrain #367 (ruined statue) is missing the upper half. The lines te_second_icon = 1; and te_second_icon_offset_y = -55; need to be added to correct this. Art graphics: * Graphic 1654 in Blades of Avernum Art (the swarthy gal with a green shirt and brown armor) has no sword-with-shield-and-armor graphic. The graphic of her armored with sword-and-shield is missing the shield. Character Graphics: * The default rakshasa image (1607) needs realignment -- it has a black line on it. * The default Asp graphic (1551) has its icons in the wrong order. North and west are reversed. * The default Eyebeast graphic (1552) has its icons in the wrong order. This means that the creature will appear to be facing south when it's actually facing north in the editor, east when west, west when south, and north when east. Terrain Graphics, these problems may have since been fixed * Graphics sheet 680, icon 52, is incorrectly drawn. It needs to be flipped horizontally to be correct. * Graphics sheet 768, icon 8, has 3 off-white pixels. Chapter 2.5: Creating Custom Terrain Types Page 53: te_can_look_at (Defaults to 0) - * Sometimes searchable terrain breaks. For certain terrain with the searchable and container attribute, they are only searchable if there is something inside the container. This means that the call te_can_look_at doesn't do a lot. Additionally, sometimes terrain becomes searchable for reasons that are obscure to me (custom hills, for instance). I can provide a scenario demonstrating this if needed. Nicholas Bellerophon: I have found an issue. When importing any of the wallset terrains into a later spot, the walls no longer draw correctly on the automap in the game under certain circumstances. For example: I imported the four doors from the first wallset into spots 404, 405, 406 & 407 in order to remove their default scripts. Chapter 2.6: Creating Custom Creature Types Page 60, TSE: cr_start_item, cr_start_item_chance. It is possible to get an error on Macintosh systems or a crash on Windows systems when you set a creature type to be able to start with multiple varieties of missile weapon (e.g. bows, thrown missiles, etc.). For example, if a creature can start with a bow or with razordisks, you can get a problem. To work around this, have any given creature type only carry one variety of missile weapon. The creature can potentially have different versions of that weapon (for example, a nephil archer can potentially have a yew or cavewood bow), but don't have a single creature type that can have a bow or a crossbow, or a bow or javelins. TSE: Do not give a creature both a bow and a crossbow. Do not give a creature both a two-handed weapon and a shield. This can cause a crash. This crash should be fixed in future versions. However, since this can still cause crashes in older versions, it should be avoided completely. Chapter 2.7 - Creating Custom Item Types Page 58, Ishad Nha: “The spells Divine Retribution and (Ravage Life?) only affect creatures of species 0-6.” Was the spell Ravage Life not included in the final version of BoA? Page 58, TSE: Characters with species "Special" are affected by Assassination and Lethal Blow. This is an error in the documentation, not a bug. However, special creatures are affected by stoning, which is a bug. This is fixed in the versions more recent than 10/8/04. Page 62: it_bonus (Defaults to 0) – * The call it_bonus may be described inaccurately. It does not provide any protection for rings, necklaces, and bracelets, and instead of preventing the given amount of damage, it prevents a random amount of damage up to the given amount. (I have not verified this.) Page 63: it_cursed (Defaults to 0) – * If cursed items are placed on ground/in a container in the editor, they lose their cursed ability. Page 63, Ishad Nha: Apparently items can be used even if they are equippable, like armor and weapons. In BoA Editor Help parlance they can have active abilities. They just can’t be used while they are equipped. Weapons with such abilities can only be used in combat. Of course, when they can be used, this can only happen when they are in a PC’s backpack. If an item has both active and passive abilities: one of the two sets of abilities will be suppressed. Page 64: Ishad Nha, item ability 65: From what I can see, item ability 65: Affect Rune Reading skill, does nothing in actual practice. Ditto when it is rephrased as item ability 43: “Affects the statistic equal to this value, minus one”. (Rune Reading is statistic number 42.) You can increase Arcane Lore via an item ability, but this increase does not affect Rune Reading, unlike increases to Arcane Lore coming from skill points. I think Rune Reading is redundant, there is no need for both it and Arcane Lore. Page 64, TSE: Item special ability 89 does cold damage, not acid damage. Page 65: * Unlike the traditional Orb of Thralni, items with it_ability_1 = 213 can give the party extra rounds of flight while the party is still in the air. Chapter 2.8: Programming with Avernumscript Page 67, TSE: Mathematical expressions without spaces between terms may cause errors. Instead of writing "x = 3+(2*i-1)", write "x = 3 + (2 * i - 1)". Also, the precedence of the % operator is peculiar. 2 + 4 % 5 is 6, not 1. Use parenthesis for stuff you use the % operator on (for example, (2 + 4) %5). Precedence isn't quite right with subtraction and addition. Subtraction and addition have the same precendence and are done from right to left, so 24 - 21 + 1 will be 2 instead of 4. To get subtraction to work right, you may want to put it in parenthesis (i.e. "(24 - 21) + 1"). Page 67: Dintiradan: it's been a while since I discovered this, but the maximum string limit is 254 characters, not 255 characters (at least with string literals; don't know about the buffer). Excalibur: When creating dialogue you're supposed to use underscores for quotation marks, since using quotations marks will end the text. However, if you put underscores in the script for a shop description, they show up as underscores instead of quotation marks. Ephesos: As for the quotation marks, you can just use an apostrophe... another workaround. Yay. Page 68: TM, Another constant to watch out for is "shop". I don't know if this has a value or not, but if you use it as a variable, your script will crash. TSE: Be careful not to use reserved or already used terms for variable names. For example, don't have a variable called "shop". The word shop is reserved for an action type in dialog nodes. Page 69: * The constants BASE_TRAP_XP (which is 50) and NUM_CHARS (which is 120) are not documented. In fact, it'd be nice to have a list of constants somewhere like the one that Khoth posted. Also, the other reserved variable names (like the Spidweb-bug-page-listed "shop") should be listed somewhere. Chapter 2.9: Creating Scenario Scripts (Edit: this comment may be wrong. "Ishad Nha: Currently my observation is that a scenario script cannot exceed 4,257 lines in length.") Page 79, Ishad Nha: you can actually use around 255 states, this I know from porting Exile scenarios. Edit: see comments by Niemand on November 26 and 27 in a recent post, "Picky Details" http://www.ironycentral.com/cgi-bin/ubb/ubb/ultimatebb.php?ubb=get_topic;f=18;t=001024 Once again the documentation does not give the full story. It seems that the script can use hundreds or thousands of states. Chapter 2.11: Creating Outdoor Scripts Page 83, Ishad Nha: Init_state is activated well before the boundary is reached, not only that, it also appears to be erratic. It may or may not work. Chapter 2.12: Creating Creature Scripts * Custom scripts for joined NPCs don't do much. Everything except the DEAD_STATE is ignored. (Is this still true? Do any other states work?) Lazarus: New bug: This one drove me nuts for two days when I was working on FB (Frostbite). It is known that joined NPC's don't run their default scripts properly, and that only their dead state is ever called. What isn't known (or at least what I didn't know) is that they don't run ANY script until they exit and reenter town. This means that if you add an NPC in town 0 with a unique dead state, he better not die while still in town 0 or nothing will happen. Suggestion: accompany any joined NPCs with a move_to_new_town() call, even if it's just re-entering the same town you're already in. Otherwise you might get burned. Chapter 3.1: Porting Scenarios, the Basics Page 101, Ishad Nha: Timers In reality this is nowhere near as simple as Jeff describes it. I have never finally figured out what you can and cannot do but I do know that there are limitations on this. You can get timers to work alright, but sometimes they will just freeze. Page 101, Ishad Nha: Custom Terrain, Items, Creatures. The method for porting is based upon a default Exile scenario that has no custom items, terrain or monsters. Create a special porting scenario if you can’t recompile the editor. For example, walls are types 5-35 and 122-169. If you have custom terrain in the second interval, terrain that is not a wall, you can go into town maps and replace it with something else, then do your porting. For example, type 137 in Shadow of the Stranger is just a blocked cave floor, unless you do something it will be ported as a part of a wall. Page 101, Ishad Nha: Special Nodes Called When Creatures Die You can just alter basicnpc.txt with this addition to the Dead_State: if (get_memory_cell(4) >= 10) run_town_script(get_memory_cell(4)); Chapter 4.1: Basics of Custom Graphics TSE: Page 103: The documentation says that a custom graphic can have a resolution of 8 bits (with a custom palette) or 16 bits. It should say that custom graphics can have 8 bit or 24 bit color. Macintosh custom graphics can, in addition, have 16 bit color. BoA Manual Page 10: * When a statistic gets very large (perhaps over 100 or 200), the game will eventually give a message saying, "Error: File corruption caused too-high skill. Skill being reset to 0. Can correct it manually with editor." This is a problem for very high-level parties, which should naturally have Health at these levels. Page 16: * When a regular PC is next to a spot and you look at that spot, you search the spot. If only a joined NPC (and not a regular NPC) is next to a spot, however, you don't search the spot. (It just seemed odd to me. Not sure it's a "bug" bug, though.) Page 17, TSE: When getting items, Blades of Avernum is intentionally very liberal about what items can be taken by the party. Beams and damaging terrain (like lava) don't block getting. If you want an item to be unreachable by the party, place it inside a container. Page 17: * Enter-combat-end-combat bug: you can get placed in totally nonsensical locations when ending combat. If you enter and then end combat immediately, you get placed one space forward. This allows you to skip special rectangles extremely easily unless specifically prevented from doing so by a designer. Page 19, TSE: Floor shimmering and similar special effects will not be drawn when, in Preferences, special effects are turned off or the game speed is set to Fast.
  17. Here is a list of bug reports listed in the order in which they appear in the Wiki BoA Script Reference. All calls have been listed, even though most appear to be alright, this is in case bugs are found in the future. I hope to follow up with companion files for bugs relating to functions found in the manual or in the BoA Editor Help file. This is a plain text condensation of a Rich Text Format original. Miscellaneous Special Calls: in my own version I have distributed these calls among the other headings, but here I will use the standard format. In the comments below, “I” will be the person who wrote the original post. TSE = the Windows version of Technical Support for the Editor. Comments with no attribution come from Kel. Script and IO Calls 1 Campaign and Scenario Calls 2 Basic Character Calls 2 Item, Special Item and Gold Calls 4 Location and Distance Calls 4 Statistic and Damage Functions 5 Animation and SFX Functions 5 Scenario Initialization Calls 6 Boats and Horses 6 Event Calls 6 Town Calls 6 Outdoor Calls 7 The Passage of Time 7 Miscellaneous Special Calls 7 Terrain Checking and Modification 8 Dialog Calls 8 Basic Dialog Box Calls 9 Advanced Dialog Box Calls 9 Terrain Script and Creature Script Calls 9 Terrain Script Calls 10 Movement, AI Functions 10 Combat and Targeting Calls 10 Grouping Calls 11 Messaging Calls 11 Advanced Item Management Calls 11 NPCs Joining Party Calls 11 Splitting Up the Party Calls 11 Custom Item Ability Calls 11 Custom Character Ability Calls 11 Cutscene Calls 12 String Manipulation Calls 12 Debugging Procedures 12 Script and IO Calls 1 print_big_str 2 print_big_str_num TSE: print_big_str_color ignored the color field. The text was always black. This is fixed in the versions more recent than 10/8/04, (it is?). 3 void block_entry 4 void end 5 short get_ran 6 short get_selected_char 7 short is_combat 8 short is_outdoor 9 short is_town 10 void play_sound 11 void print_str 12 void print_str_color 13 void run_scenario_script 14 void run_town_script 15 void set_incidental_sound 16 void set_state 17 void set_state_continue Campaign and Scenario Calls 18 void clear_quest 19 void end_scenario 20 short get_flag 21 short get_sdf 22 void inc_flag 23 void set_flag 24 void toggle_quest Basic Character Calls 25 void alert_char 26 void award_char_xp 27 void award_party_xp 28 short can_see_char 29 void change_char_xp 30 void change_pc_skill_pts 31 void change_spell_level TSE: change_spell_level currently gives an unfortunate text message when used for a non-party creature. This is fixed in the versions more recent than 10/8/04. (It is?) 32 short char_attitude_to_char 33 short char_has_trait 34 short char_ok 35 short char_on_spot TSE: The descriptions of the calls char_on_loc and char_on_spot are unclear (and the call names are unhelpful). char_on_spot only checks for NPCs, so it will return -1 if one of the player's characters is on that spot. char_on_loc checks for all characters (as does char_on_me). 36 short char_status 37 short creature_type 38 void deduct_ap TSE: calls end_combat_turn and deduct_ap were originally designed to only be called in creature scripts. This is highly unfortunate, because these calls are very valuable for custom abilities, and because there is no way to reliably get them to work on PCs. If called in a scenario script, these calls affect PC 0 only. In later versions of Blades of Avernum (v1.0.1 Windows), when these calls are used in a non-creature script, they will affect the currently selected character (when not in combat) or the currently active character (in combat). 39 void end_combat_turn 40 short enemies_nearby 41 void erase_char 42 short friends_nearby 43 short get_attitude * As far as I can tell, the attitude of the party is 0, which should be mentioned under the get_attitude description. 44 short get_char_skill_pts 45 short get_energy TM: Either there is no get_max_energy(); call, or there is no such call in the docs. Either way, this should be fixed. Ishad Nha: Maximum Spell Energy is statistic 36, so “get_stat( which_char,36);” should work here. 46 short get_health 47 short get_level TSE: the ME paramater doesn't work with relocate_character or get_level If you want to use these calls inside a creature script, use the my_number call. 48 short get_max_health 49 short get_species 50 short get_spell_level 51 short get_summon_level 52 void give_recipe 53 short has_recipe 54 void kill_char 55 short my_ap 56 short my_number 57 short party_can_see_loc 58 short party_has_trait 59 short party_size 60 void print_named_str 61 short random_party_member 62 void revive_party 63 void set_attitude 64 void set_char_alert 65 short set_char_script_mode 66 void set_char_trait 67 void set_creature_memory_cell 68 void set_level 69 void set_mobility 70 void set_name 71 void set_special_ability 72 void set_summon_level 73 short species_in_party Item, Special Item and Gold Calls 74 void change_coins 75 void change_spec_item 76 void char_give_item * Items don't stack when given via this call_give_item (so if you give three potions of the same kind, the character ends up with three different potions). This doesn't happen with reward_give or other item management calls as far as I know. 77 short char_has_item 78 short char_has_item_of_class_equip 79 void char_take_item TSE: Don't use the call char_take_item. It won't work. Use the call take_item instead. Note that this means that you can't take items from NPCs once they have been given. 80 short coins_amount 81 short has_item 82 short has_item_of_class 83 short has_num_of_item 84 short has_special_item 85 short item_of_class_on_spot 86 void move_item_on_spot 87 short pay_coins 88 void put_item_on_spot 89 short reward_give 90 short take_all_of_item 91 short take_all_of_item_class 92 void take_item 93 short take_item_of_class_on_spot 94 void take_num_of_item 95 void take_special_item Location and Distance Calls 96 short char_loc_x 97 short char_loc_y 98 short char_dist_to_loc 99 short char_on_loc TSE: The descriptions of the calls char_on_loc and char_on_spot are unclear (and the call names are unhelpful). char_on_spot only checks for NPCs, so it will return -1 if one of the player's characters is on that spot. Char_on_loc checks for all characters (as does char_on_me). 100 short dist_to_waypoint 101 short group_dist_to_loc 102 short my_dist_from_start Statistic and Damage Functions 103 void alter_stat TSE: alter_stat can't drop the main stats Strength, Dexterity, Intelligence, or Endurance below the default starting level for those stats. Which is probably a good thing. 104 void change_char_energy 105 void change_char_health 106 short char_with_highest_skill 107 void damage_char 108 void damage_near_loc 109 short get_char_status 110 short get_highest_skill 111 short get_skill_total 112 short get_stat 113 short get_stat_levels_bought 114 void heal_char 115 short party_has_status 116 short party_member_has_skill 117 void restore_energy_char 118 void restore_pc 119 void set_char_status TSE: When using set_char_status with is_forced set to 0, curse/bless and shield/weaken are flipped. So set_char_status(5,1,10,FALSE,TRUE) will give character 5 10 levels of bless instead of shield (because the 1, which should be shield, is being read as bless instead). 120 void set_party_status 121 void status_near_loc 122 void waypoint_damage_party Animation and SFX Functions 123 void put_boom_on_char 124 void put_boom_on_space 125 void put_effect_on_char 126 void put_effect_on_space 127 void put_jagged_zap 128 void put_sparkles_on_char 129 void put_sparkles_on_space 130 void put_straight_zap 131 void run_animation 132 void run_animation_sound Scenario Initialization Calls Using Load Scen state to alter boats and horses in save games: Here I will be exploring alterations to the contents of the Start Scen state, after the designer has started to play test the scenario. If you test a design and add a boat to the Start_Scen_State it won't show up in an existing save game. What Load Scen state does is mandate the location of all the affected boats and horses, it overrides the save file. Hence a boat will vanish if its location is overridden. It is best only used for boats and horses that need to be altered. The relevant boat or horse entry should be "commented out" in the scenario script as soon as the game is next saved. Else, when the save game is next re-loaded, the boat or horse will be restored to the location specified by Load Scen state, the state always overrides the save file. Boats and horses can also be created in the Init State of a town script. Appropriate SDFs can ensure that a boat or horse is only available if the right conditions are met. Shops would also be covered by these comments. 133 void add_item_to_shop 134 void create_boat 135 void create_horse 136 void init_quest 137 void init_special_item 138 void set_creature_type_level Boats and Horses 139 short in_boat 140 short in_horse 141 void set_boat_property 142 short set_boat_range_property 143 void set_horse_property 144 short set_horse_range_property Event Calls 145 short day_event_happened 146 void set_event_happened Town Calls 147 void activate_hidden_group 148 void change_crime_level 149 void change_outdoor_location 150 void clear_town * Something odd and undocumented is going on with the clear_town call. The description of the problem is here. 151 short current_town 152 short current_town_size 153 void enable_add_chars 154 short get_crime_level 155 void make_town_hostile 156 void move_to_new_town * The call move_to_new_town can't be called from an INIT_STATE, a START_STATE, a creature script, or a terrain script, even if you distance the call from the state with set_state_continue, run_town_script, or run_scenario_script. (I put this under documentation because apparently this would be hard to change.) 157 short num_killed_in_town * The call num_killed_in_town always returns 0. (I have not verified this.) 158 void place_monster 159 void set_crime_tolerance 160 void set_items_not_property 161 void set_town_status TSE: Problems With town_status Calls. The call town_status only works when passed the value -1 (for the current town). So town_status(-1) will return the status of the current town, but town_status(any other number) won't work correctly. 162 void set_town_visibility 163 short spawn_creature 164 short teleport_party Ishad Nha: Mode 2 does not work, fortunately modes 0,1 do work. 165 short town_status 166 void turn_off_training Outdoor Calls 167 void create_out_spec_enc 168 short current_out_section 169 void eliminate_outdoor_enc 170 void out_move_party 171 short outdoor_enc_exists 172 void outdoor_enc_result 173 void place_out_spec_enc 174 void set_out_fight_town_loaded The Passage of Time 175 void force_start_day 176 short get_current_tick 177 void set_ticks_forward 178 short tick_difference 179 short what_day_of_scenario * Arguably not a documentation problem, using force_start_day(-1) makes what_day_of_year always return 0, but what_day_of_scenario still works fine. This should at least be mentioned somewhere. Also, what_day_of_scenario starts at 0, despite the fact that the games in-game calendar starts at 1, which should at least be mentioned. 180 short what_day_of_year Lancer: It is worth noting that what_day_of_year() always returns a value of 0 if used with force_start_day(). In other words, the value for what_day_of_year fails to increment with each passing day. The way around it is by using the what_day_of_scenario() call which works correctly in conjunction with force_start_day(). Thralni: the call what_day_of_scenario() appears to always return the number of days - 1. This appears to be normal...So, if its day 3, what_day_of_scenario will return 2. Miscellaneous Special Calls 181 void create_text_bubble * The call create_text_bubble cannot be called from a terrain script, even though the docs say that it can. (I have not verified this.) 182 void drop_item 183 short get_char_who_stepped_on 184 void make_wandering_monst 185 void put_object_on_waypoint 186 short run_bash_door 187 short run_pick_lock 188 short set_ter_script_mode 189 void set_terrain_memory_cell 190 void text_bubble_on_char Terrain Checking and Modification 191 void change_blocked 192 short get_floor 193 short get_height 194 short get_terrain 195 void flip_terrain 196 short is_blocked 197 short is_field_on_space 198 short is_object_on_space 199 short is_stain_on_space 200 void put_field_on_space 201 void put_object_on_space 202 void put_stain_on_space * The call put_stain_on_space sometimes does nothing when attempting to remove a stain. This is a bit unpredictable, but most of the time that I've tried it, it does nothing. It also works fine putting a stain down, just not removing it. 203 void set_floor * The calls set_terrain, set_floor, and set_height only inconsistently work outdoors. They most often do nothing. 204 void set_height 205 void set_terrain 206 void swap_floor 207 void swap_terrain Dialog Calls 208 void add_string 209 void begin_shop_mode 210 void begin_talk_mode 211 short character_talking_to 212 void clear_strings 213 short current_personality 214 void remove_string 215 void set_char_dialogue_pic Basic Dialog Box Calls 216 reset_dialog 217 void add_dialog_choice * As described here, in a dialog box, choosing the second dialog choice always returns the number 2, even if the dialog choice was added as the third option. 218 reset_dialog_preset_options 219 void add_dialog_str 220 void message_dialog 221 short run_dialog Advanced Dialog Box Calls 222 void check_text_response_match 223 short get_selected_pc 224 void get_text_response 225 short got_text_match 226 void large_draw_pic_dialog 227 short run_select_a_pc 228 void small_draw_pic_dialog Terrain Script and Creature Script Calls 229 short can_see_loc 230 void damage_nearby 231 short dist_to_char 232 short dist_to_loc 233 short dist_to_party 234 short floor_in_this_spot 235 void force_status_nearby 236 short get_memory_cell 237 short get_nearest_char TSE: If you use this call in a creature script, it will return the number of the creature whose script is running, not the nearest other creature. This makes the call useless for creatures (it was originally intended for use in terrain scripts). Alignment-based calls (like get_nearest_evil_char) work fine as long as you're looking for creatures of a different alignment. 238 short get_nearest_evil_char 239 short get_nearest_good_char 240 void heal_nearby 241 short my_loc_x 242 short my_loc_y 243 void restore_energy_nearby 244 void set_memory_cell 245 short set_script_mode 246 void status_nearby 247 short terrain_in_this_spot Terrain Script Calls 248 short char_on_me 249 short char_who_activated_script 250 short get_mechanism_difficulty 251 short get_physical_strength * The call get_unlock_spell_strength is undocumented. 252 void set_mechanism_difficulty 253 void set_physical_strength Movement, AI Functions 254 short am_i_doing_action 255 short approach_char 256 void approach_ter_script 257 short approach_waypoint 258 void fidget 259 short flee_char 260 short maintain_dist_to_char 261 short move_to_loc_x_y 262 short return_to_start * When a creature can't get to a location that it's trying to get to, the game slows to a crawl. For example, when a creature gets lured out of a building hrough an open door, the door gets closed, and then the creature tries to return_to_start, the game slows. (This has been reported on Windows, and I have not verified it personally.) 263 void stop_moving Combat and Targeting Calls 264 void do_attack 265 void do_attack_tactic 266 short get_aggression 267 short get_courage TSE: The description of the call get_courage in the documentation is wrong. It should read: “short get_courage(short which_char,short dummy_value) - Returns the current courage of which_char. Dummy_value is ignored.” 268 short get_strategy 269 short get_target 270 short select_target 271 void set_aggression 272 void set_courage 273 void set_strategy 274 void set_target 275 short target_ok 276 short who_hit_me Grouping Calls 277 void add_char_to_group 278 void add_range_to_group 279 short char_in_group 280 void clear_all_groups 281 short first_group_member 282 short num_chars_in_group 283 short random_group_member 284 void remove_char_from_group 285 short what_group_in Messaging Calls 286 void broadcast_char_message 287 void broadcast_message_from_x_y 288 void broadcast_terrain_message 289 void give_char_message 290 void give_ter_script_message 291 short my_current_message Advanced Item Management Calls TSE: Do not use the ME value for which_char for these calls. Use the creature's actual number. Inside a creature script, you can get this with the my_number call. 292 void destroy_char_item 293 short get_item_variety 294 short item_type_in_slot 295 void take_item_char_item NPCs Joining Party Calls 296 short add_char_to_party 297 short character_in_party 298 short remove_char_from_party 299 short this_char_is_in_party Splitting Up the Party Calls 300 void reunite_party 301 void split_off_one_char 302 short try_to_split_party Custom Item Ability Calls 303 short who_is_custom_item_target 304 short who_used_custom_item Custom Character Ability Calls 305 void change_custom_abil_uses 306 short get_custom_abil_uses 307 void init_special_abil 308 short who_used_custom_abil Cutscene Calls 309 void erase_text_bubbles 310 void force_instant_terrain_redraw 311 void force_view_center 312 void march_party 313 void pause 314 void relocate_character TSE: the ME paramater doesn't work with relocate_character or get_level If you want to use these calls inside a creature script, use the my_number call. 315 void set_character_facing 316 void set_character_pose 317 void set_total_visibility String Manipulation Calls 318 void append_char_name 319 void append_number 320 void append_string 321 void clear_buffer 322 void get_buffer_text Debugging Procedures 323 void print_num TSE: The call print_num won't properly print negative numbers. If you need negative numbers, use print_nums. 324 void print_nums 325 turn_on_debug_mode EDIT (Ephesos): Tidied it up a bit, changed The Immortal back to TM.
  18. Time: Manual correction I drew up this table of time versus day/night cycles in BoA by using the following two calls: s = get_current_tick() % 5000; print_big_str("The time is now ",s," minutes."); 3,750 = start of dusk 4,000 = it gets darker 4,250 = darker still 4,500 = (midnight) 4,750 = brighter 5,000 = brighter still (A new calendar day starts now.) 250 = daylight Teleportation Yes, I wanted the party to be teleported not surrounded by pretty lights, that is why I chose “teleport party” not an SFX call. Fortunately the modes 0 and 1 both work. While I am at it, we really need a bugs page that lists the bugs in some definite order. For instance, bugs affecting calls could be listed in the order in which the calls are described in the Wiki guide.
  19. short teleport_party(short new_loc_x,short new_loc_y,short fade_type) mode - 0 full teleport flash 1 no teleport flash 2 only fade flash // this does not work in practice. The first two modes work, while the third does not, it only produces a flash.
  20. Experimental versions of BoE, "OBoE" As for compatibility of save games when the party goes from a scenario in official BoE to a scenario in an experimental version. The party will exit the official scenario via the main screen of the official version of BoE. It will enter a scenario in an experimental version via its main screen. While at the main screen, the party records will really consist of only their statistics, their items and their gold/food. The 72Kb will consist of other things like boat records and so forth, but they won’t be relevant in the new scenario. A porting program might be a good idea, something that will convert an official save game to a format compatible with the relevant experimental version. Currently it seems that any experimental version of BoE will be more alike than not. A porting program could also convert an experimental save game to a standard format. This might be necessary if there were a whole lot of experimental versions, all incompatible with each other. So translation would go: format of version 1 to standard format to format of version 2.
  21. Yes, the extra boats I was able to generate with hex - editing. Extra sdf won't be allowed by the scenario Editor.
  22. Especially in the desert areas of Geneforge 1 and 2, I am reminded of the TSR Advanced Dungeons and Dragons games "Dark Sun 1: Shattered Lands" and "Dark Sun 2: Wake of the Ravager". These two games date from the first half of the 90s, so they are credible guesses but only guesses. The feel is similar as the games use a similar format: party grouped for exploring and individual movement during combat.
  23. About the only thing you could do here is to swap an item for a better one of the same type. Here you would use calls like "void move_item_on_spot" to make the old item disappear and "void put_item_on_spot" to make the new one appear.
  24. While we are at it we can have Editor support for all 30 boats and 30 horses. Perusal of the source code shows that the scenario file has provision for 30 boats, 30 horses and 20 scenario timers, not just 24, 24 and 10. Here and now the six extra boats can be hex – edited into the game: Twenty-four supported entries: 440,53 through 444,12. Six unsupported entries: 444,13 thru 445,2. The format: location X,Y, four spaces, short town number, Boolean exists and the Boolean party property identifier. Edit Horses [30], unsupported entries: 448,33 thru 449,22. Scenario timers Number of moves is found from 507, 61 through 508,10. Ten unsupported entries: 508,11 through 508,30. Scenario state to be called is found from 508,31 through 508,50. Ten unsupported entries: 508,51 through 508,70. The same file, Global.h lines 312… also shows that there is provision for 3,100 Stuff Done Flags not 3,000.
  25. I can now get the open source editor to compile, but the resulting program is 296Kb versus the correct size of 735Kb. The economy size editor starts up properly then, I can't get it to load a scenario.
×
×
  • Create New...