• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece!🔗 Click here to enter!

Summoning System

Status
Not open for further replies.
Level 9
Joined
May 5, 2007
Messages
253
Hello everyone :)

I'm trying to make an advanced summon system for my RPG but I have no idea how to create this, I was wondering if anyone could help me out.

I want every summoned unit to follow the summoner/caster, always stay around the summoner (teleport back to the summoner when they come out of range of him) but attack the same unit the summoner attacks, but I only know how to make them follow the summoner once they are spawned.

I also want the summoned units to cast abilities right when they get into range of a target (like if I summoned a wolf, the wolf would cast lunge to lunge at the enemy whenever they start to attack the target), but this has proven to be difficult for my pea-sized intellect.

Thanks in advance for anyone who can help me out :)
 

Deleted member 177737

D

Deleted member 177737

The first part could probably be done in GUI, the rest sounds like it needs to be done in Jass. (Can't help with anything Jass related =/ )
 

Chaosy

Tutorial Reviewer
Level 40
Joined
Jun 9, 2011
Messages
13,183
My system here will only work if the summoned unit is permanent and dont disapear after a time, so i might edit the system else. sorry if there i leaks.
im not a spell maker but if this not owkrs change the
  • Unit - A unit Finishes casting an ability
with
  • Unit - A unit Starts the effect of an ability
  • prepare
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Trigger - Turn off follow <gen>
  • cast summon
    • Events
      • Unit - A unit Finishes casting an ability
    • Conditions
      • (Ability being cast) Equal to your_ability
    • Actions
      • Set TempLoc = (Position of (Casting unit))
      • Unit - Create 1 Footman for (Owner of (Casting unit)) at TempLoc facing Default building facing degrees
      • Custom script: call RemoveLocation(udg_TempLoc)
      • Set Your_unit = (Last created unit)
      • Set Your_summoning_unit = (Casting unit)
      • Trigger - Turn on follow <gen>
  • follow
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
    • Actions
      • Unit - Order Your_unit to Attack-Move To TempLoc
  • aid caster
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Attacked unit) Equal to Your_summoning_unit
    • Actions
      • Trigger - Turn off follow <gen>
      • Unit - Order Your_unit to Attack (Attacking unit)
      • Set attcking_unit = (Attacking unit)
  • back to follow
    • Events
      • Unit - A unit Dies
    • Conditions
      • (Dying unit) Equal to attcking_unit
    • Actions
      • Trigger - Turn on follow <gen>
NOTE
if your spell allready summons a unit remove that from the spell (data - sumoned unit)
 
Last edited:

Deleted member 177737

D

Deleted member 177737

I believe (without testing) that the "Attack Move to TempLoc" would cause the summoned unit to attack the unit it is moving to. (Again not sure because I didn't test)
Its basic but it would work.
 
Status
Not open for further replies.
Top