Creating a new mod, Some things I need help with.

Discussion in 'Modding and Scripting Support' started by Chaoswizard98, Jan 17, 2013.

Remove all ads!
Support Terra-Arcanum:

GOG.com

PayPal - The safer, easier way to pay online!
  1. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    As the title says, I am starting to make a new mod. Since I know im going to have a ton of major questions and issues along the way I thought I might as well put them all into one thread.

    First a little bit about the mod. Since I like playing coop maps with my brother it will be multiplayer compatible. The size of the map however, is way too big to travel by foot (50 by 50 sectors). In singleplayer the world map is the main means of transportation. I will be adding a "hub" system for multiplayer use. It will have custom music and sounds and if everything goes according to plan the gameplay should be somewhat faster than arcanums. Things will explode and pop out when you least expect it. Every npc will be voiced as well.

    Anyways for issue number 1.
    Im working on setting the mood in the begining of the game as well as the players reason to go on the journey. Basically bandits trash the town and kill most of the people.

    Is there a way to have the wall of fire spell pop up in certain places when the player completes a quest? I tryed adding an npc generator and changing the art to the "wall of fire" but since its an npc and not a light it doesnt have the "add blending" option to it and it has the black border. How do I go about adding a fire suddenly starting in the town?
     
  2. Nataku

    Nataku Member

    Messages:
    243
    Likes Received:
    1
    Joined:
    Jun 19, 2011
    I would had never try that way. The black border problem is simple, some npc (like purple, blue, yellow and red spirits, don't know heir names in the english version) haven't the boards.
    I think the simpliest way is to make some scenery (there is a scenery "firewall" on worlded (you cannot ad blocktiles if you want fire block pc) and to past them on "off" BY A SCRIPT declenched when the player enter on the map. A npc (off) should have a heartbeat script who loop fire the fire walls the past them off, then call a script every second with attachee each firewall wich check if the condition for the fire appear is okay. (call script X at line Y with trigger current looped object and attache current loop object in 1 second, and the script called "if .... THEN toogle attache stat on/off ELSE call script X at line Y with trigger attachee and attachee attachee in 1 second Return and RUN default). By this way, fire light wich will appear with a light and animation.
    The only matter with that solution is : i don't know what will happen with the script if player leave village map (and eventually the sector). And don't forget generate townmap without fire walls
     
  3. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    Thanks Nataku. It mostly worked. The only issue is that the closer to the fire you get the faster the animation plays. Its a little strange but it serves its purpose.
     
  4. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    is there a list of npc prototypes somewhere? I looked in the edit docs and found everything but critters.

    Edit: I currently dont have this problem but I know I will run into it again. Occasionally when I place an npc in world ed, they show up in a different place in arcanum. No clue why, and deleting the npc and replacing him doesnt seem to fix the problem either. Any clue why World ed does that?
     
  5. Nataku

    Nataku Member

    Messages:
    243
    Likes Received:
    1
    Joined:
    Jun 19, 2011
    Proto from 17087 to 28491 (except 26020 to 26027 used for traps) It saw it on the proto folder (in data). Personally, I never used proto (except for a tailor's inventory) and never modify it. Worlded is enough complex without them and there is always (or almost always) a way to do that I wanna do without modify proto.
    Some members of the forum know how to create some, so they can answer to you.

    I think you thought to that but isn't a simple daystand/nightstand/waypoint matter ? :hippy:

    EDIT :
    So, did you try go to the sector (so active the heartbeat script) then leave the map before make fire appear and come back ? I'm not sure the called script resist to that but, according to my personnal experience, I think the script in "attending" that the pc come back to the map
     
  6. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    The only reason I needed the prototype list is because im planning on adding some more combat mechanics such as when you damage a boss it will summon a smaller monster. Or something similar to that. I was planning on using the "create object with basic prototype (num) near (obj)" and attach it to the "was hit" flag.

    I also remember trying to set day / night stand points for the npcs that showed up in a different area but that also didnt fix the problem. Its probebly just one of the bugs with world ed.

    For the fire even when I leave and come back it does the same thing. It still plays its animation super fast. If I stand about 10 tiles away its normal. The closer I get the faster the fire's animation plays.

    Basically This is what im trying to do.

    Player starts the game in the town and completes a few quests.
    On one of the later quests the player leaves town for a minute to get something.
    Upon returning to the town the player finds it on fire and being attacked by bandits.
    After dealing with the bandits the player leaves the town through a crypt and continues his quest.
    Later on the player may return to the village which will no longer be on fire.
     
  7. Nataku

    Nataku Member

    Messages:
    243
    Likes Received:
    1
    Joined:
    Jun 19, 2011
    My only advice for that is use npc with heartbeat script. Prototypes are... :drunk:

    Never saw that bug but there are some much bug in worldEd. In my module, I can't delete any item, npc, container, ... from the map, I have to flag them off (what the f*** ?). So try place npc to their defenitive place or delete them and start again if you want to move them. Are you sure they are not going taking a item on the ground ? (You can fix that with the flag "no npc pick up on the items)

    Once again, I never so that, but I guess there is no other solution. The most important is fire appear and have animation no ?

    Okay, so it's perfect. Actually I tried leaving the map just once time but is it's work, this is perfect (because it's the only way to make sceneries appear because they haven't heartbeat script (this is so bad).

    Good luck for your module, I'm sure it will be so cool and if you have any questions... :bunny:
     
  8. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    Dont I still need the prototype number for the script to summon the monster? Or is there another script to summon a different creature other than this one? "create object with basic prototype (num) near (obj)"
    where prototype num is the weaker npc and object is the boss.
     
  9. Nataku

    Nataku Member

    Messages:
    243
    Likes Received:
    1
    Joined:
    Jun 19, 2011
    Yes, I understood what you meant. I think the simplest way is to attach a heartbeat script to the summoned creatures and make them off. They can appear when the boss is hurt (by triggering a condition at the "taking damage" point of the boss, you can test his life, ...) and with that way you can said how many monsters will appear exactly.
    If you want to make them appear close to the boss, you make teleport them to one tile of him (get the boss' position in a couple of locals and teleport creature to local 1 -1, local 2 -1 (except if you're next to a wall then +1, -1, ...).
    The numbers of heartbeat scripts that the computer can assume is huge, so don't hesitate to place a lot a monsters
     
  10. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    Will this make them all visible at once, or will it make them visible 1 at a time (1 appearing every time the boss is hit)?
    Thanks for all the help! Everything is working great so far.
     
  11. Nataku

    Nataku Member

    Messages:
    243
    Likes Received:
    1
    Joined:
    Jun 19, 2011
    It's depending of your script be it's obviously possible : if you attach a script to boss' point "taking damage" wich increase a global variabl and if you make or a script for each monster either one script with counters, you can make appear the monsters in a order and only when the boss is hurted.
    Personally, everytime pc hurts the boss, I would test his current health, set the difference betwenn max and current health in a global variable and make monsters appear with a heartbeat script
    0.If global variable (num) <= counter 0
    THEN toggle attache state on/off
    ELSE return and RUN default
    1.remove this script
    2.return and RUN default
     
  12. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    I added custom combat music (by renaming the file to arcanums name) but it plays too loud. The combatmusic.mp3 is not listed in schemeindex, is it listed somewhere else? Or do I need to manually make the music quieter?
     
  13. Nataku

    Nataku Member

    Messages:
    243
    Likes Received:
    1
    Joined:
    Jun 19, 2011
    I think you should better do it manually, shemeindex and schemelist are... some curiosities of WorldEd (I never sucess to modify correctly them)
     
  14. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    The only luck I have with modifying them are for changing the volumes. As for adding music...not so much. Ill just do it manually.
     
  15. Nataku

    Nataku Member

    Messages:
    243
    Likes Received:
    1
    Joined:
    Jun 19, 2011
    For technical reasons, in my own module, music are in fact sound, that's why it's so heavy (sounds are wav files). But I discover two things :
    -How to cute a sound : teleport the player on a other map and, if he don't change map, teleport on a jump point on another map (and you can get his position and do it during a fade, so it will cut the sound without moving player.
    -How to make sound repeat (as for music) : with call a script in (num) seconds (with num=track time) w/ attache player. I have just to don't forget remove the script when the pc leaves the map.

    :hidepc: :hump:
     
  16. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    I've heard that Sony Acid was a good program. At the moment I'm using WavePad which is also really nice. Especially for removing the static background noises from the characters voices.
     
  17. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    I might have done something different with the script causing me to get different results. How exactly did you get the npc to loop fire the firewall?
     
  18. Nataku

    Nataku Member

    Messages:
    243
    Likes Received:
    1
    Joined:
    Jun 19, 2011
    A heartbeat script :

    0.Remove this script
    1.Loop for (any scenery in vicinity)
    2.If (Current looped object) is named (firewall internal)
    THEN Goto line 5
    [ELSE Do nothing]
    3.Loop end
    4.Return and RUN default
    5.Toggle (Current looped object) state on/off
    6.Call script (that script) at line (8) with trigger (Current looped object) and attachee (Current looped object) in (1) second
    7.Goto line 4
    8.If global flag ("fire must appear") is set,
    THEN toggle (attachee) state on/of
    ELSE Call script (that script) at line 8 with trigger (attachee) and attachee (attachee) in (1) second
    9.Return and RUN default

    (I wrote it using my WorldEd memories but I think there is no mistakes)
     
  19. Chaoswizard98

    Chaoswizard98 Member

    Messages:
    82
    Likes Received:
    0
    Joined:
    Dec 28, 2011
    Ok I just tested it and its not showing up :???: heres what I got.

    Firewall script you gave me is 00050Firewall

    Then the global flag set script is 00051Firewall
    0 Set global flag 10 to true.
    1 return and run default.

    I have an npc (off) near the firewall with script 50 (the firewall script) on heartbeat.
    the firewall is also off with an internal of 1801

    I have a test object (bread) with script 51 (set global flag) set on the (get) option.

    Is this correct and I just missed something? or did I do something wrong with the global variable?
    Thanks!
     
  20. ArnelMachida

    ArnelMachida New Member

    Messages:
    2
    Likes Received:
    0
    Joined:
    Nov 3, 2010
    maybe you can adjust your settings?
     
Our Host!