Ayane | Code :
- HEL Initialisation
- Evénements
- Map initialization
- Conditions
- Actions
- -------- Définition des variables --------
- Set HEL_NbFeuFollet = 9
- Set HEL_Separation = 200.00
- Set HEL_T = 0.04
- Set HEL_Teta = (90.00 / 24.00)
- Set HEL_Alpha = 0.00
- Set HEL_Beta = 90.00
- Set HEL_Centre = (Point(0.00, 0.00))
- Set HEL_Position = HEL_Centre
- -------- Création des feu follets --------
- For each (Integer A) from 0 to (HEL_NbFeuFollet - 1), do (Actions)
- Boucle - Actions
- Unité - Create 1 Feu follet for Joueur 1 (Rouge) at HEL_Position facing Orientation bâtiment par défaut degrees
- Set HEL_FeuFollet[(Integer A)] = (Last created unit)
- Effet spécial - Create a special effect attached to the chest of HEL_FeuFollet[(Integer A)] using Abilities\Weapons\AvengerMissile\AvengerMissile.mdl
- -------- Active le rendu --------
- Déclencheur - Add to HEL Rendu <gen> the event (Temps - Every HEL_T seconds of game time)
- Déclencheur - Turn on HEL Rendu <gen>
- Caméra - Lock camera target for Joueur 1 (Rouge) to HEL_FeuFollet[1], offset by (0.00, 0.00) using Rotation par défaut
|
Il doit y avoir l'action Déclencheur Add New Event que tu n'ais pas dans ROC
Déclencheur - Add to HEL Rendu <gen> the event (Temps - Every HEL_T seconds of game time)
Donc tu ajoute directement l'événement dans HEL Rendu (avec la valeur de HEL_T).
Code :
- HEL Rendu
- Evénements
- Conditions
- Actions
- Set HEL_Alpha = (HEL_Alpha + HEL_Teta)
- -------- Déplacement de l'hélice --------
- Set HEL_Position = (Point(((X of HEL_Centre) + (1000.00 x (Cos((HEL_Alpha / -2.00))))), ((Y of HEL_Centre) + (1000.00 x (Sin((HEL_Alpha / -2.00)))))))
- -------- Pour une hélice --------
- Set HEL_Beta = (HEL_Beta + HEL_Teta)
- Unité - Move HEL_FeuFollet[(HEL_NbFeuFollet - 1)] instantly to HEL_Position
- -------- Lame 1d --------
- For each (Integer A) from 0 to ((HEL_NbFeuFollet - 2) / 4), do (Actions)
- Boucle - Actions
- Unité - Move HEL_FeuFollet[(Integer A)] instantly to (Point(((X of HEL_Position) + (((Real((Integer A))) + 1.00) x (HEL_Separation x (Cos(HEL_Alpha))))), ((Y of HEL_Position) + (((Real((Integer A))) + 1.00) x (HEL_Separation x (Sin(HEL_Alpha)))))))
- -------- Lame 1g --------
- For each (Integer A) from 0 to ((HEL_NbFeuFollet - 2) / 4), do (Actions)
- Boucle - Actions
- Unité - Move HEL_FeuFollet[((Integer A) + ((HEL_NbFeuFollet - 1) / 4))] instantly to (Point(((X of HEL_Position) + ((Real((((Integer A) + 1) x -1))) x (HEL_Separation x (Cos(HEL_Alpha))))), ((Y of HEL_Position) + ((Real((((Integer A) + 1) x -1))) x (HEL_Separation x (Sin(HEL_Alpha)))))))
- -------- Lame 2d --------
- For each (Integer A) from 0 to ((HEL_NbFeuFollet - 2) / 4), do (Actions)
- Boucle - Actions
- Unité - Move HEL_FeuFollet[((Integer A) + ((HEL_NbFeuFollet - 1) / 2))] instantly to (Point(((X of HEL_Position) + (((Real((Integer A))) + 1.00) x (HEL_Separation x (Cos(HEL_Beta))))), ((Y of HEL_Position) + (((Real((Integer A))) + 1.00) x (HEL_Separation x (Sin(HEL_Beta)))))))
- -------- Lame 2g --------
- For each (Integer A) from 0 to ((HEL_NbFeuFollet - 2) / 4), do (Actions)
- Boucle - Actions
- Unité - Move HEL_FeuFollet[((Integer A) + (((HEL_NbFeuFollet - 1) x 3) / 4))] instantly to (Point(((X of HEL_Position) + ((Real((((Integer A) + 1) x -1))) x (HEL_Separation x (Cos(HEL_Beta))))), ((Y of HEL_Position) + ((Real((((Integer A) + 1) x -1))) x (HEL_Separation x (Sin(HEL_Beta)))))))
|
Pour ton problème il faut donc que tu mette au début des actions de HEL Rendu: set HEL Centre = Position of ton unité. Ainsi tu peux même téléporter ton unité cela tournera toujoura toujours autour de ton unité. Message édité par Ayane le 26-08-2006 à 10:30:47
|