![]() |
NPCs casting - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: General Help (/Forum-General-Help) +--- Thread: NPCs casting (/Thread-NPCs-casting) |
NPCs casting - x77x - 11-02-2015 01:58 AM back in the old days to get a NPC to cast certain spells you gave them a newbied invisible spellbook, with only the spells you wanted in it tried that today, and it doesnt work... (human brain) what is the suggested way to make an NPC only cast the spells you want? also how could you adjust the weapon attack to spell ratio? (so they only cast every so often, and not all the time) RE: NPCs casting - XuN - 11-02-2015 06:40 PM NPCs must have the required MAGERY for that spell to cast it, the same with mana (they consume mana too) and there's no need to have an invisible spellbook, just create it with ITEMNEWBIE. To prevent them casting just do some rand checks in @SpellSelect trigger or @NPCActFight http://wiki.sphere.torfo.org/index.php/@NPCActFight RE: NPCs casting - x77x - 11-02-2015 09:49 PM they have magery and mana and its invis so no one sees it =) (i dont want it in their hands) i tried both brain human and monster still nothing... ideas? RE: NPCs casting - x77x - 11-12-2015 09:30 AM Code: [CHARDEF c_wei_infantry_ambush_f] he does not cast firefield... also i want him to hide and stay hidden he will be hidden sometimes when he originally spawns, the second he steps hes revealed and never goes back to hidden RE: NPCs casting - darksun84 - 11-12-2015 07:22 PM Toggle spellflag_playeronly from firefield and add spellflag_targ_char. Npc doesn't cast spells with spellflag_targ_xyz RE: NPCs casting - x77x - 11-12-2015 10:11 PM so i need to do that for EVERY spell i plan to have NPCs use... if spellflag_playeronly is present k thanks RE: NPCs casting - x77x - 11-13-2015 08:04 AM default is Code: FLAGS=spellflag_dir_anim|spellflag_targ_xyz|spellflag_harm|spellflag_damage|spellflag_fx_targ|spellflag_field|spellflag_playeronly ive tried Code: FLAGS=spellflag_dir_anim|spellflag_targ_xyz|spellflag_harm|spellflag_damage|spellflag_fx_targ|spellflag_field Code: FLAGS=spellflag_dir_anim|spellflag_targ_xyz|spellflag_harm|spellflag_damage|spellflag_fx_targ|spellflag_field|spellflag_targ_char Code: FLAGS=spellflag_dir_anim|spellflag_harm|spellflag_damage|spellflag_fx_targ|spellflag_field|spellflag_targ_char still nothing... BUILD 2569 RE: NPCs casting - darksun84 - 11-13-2015 09:15 AM Me build 2543 and works fine, remember when you change spells FLAGS or spell resources you have to restart the server RE: NPCs casting - x77x - 11-13-2015 12:22 PM thats what i was thinking... i was doing resync ill keep trying, thanks RE: NPCs casting - x77x - 11-14-2015 03:53 AM still nothing, restarted after ever change gave the npc only magery no wresting or swords brain human, brain monster 500 mana maybe its the build or maybe another script is stopping the cast... *keep digging* |