Joined: 03 Jul 2015 Location: between heaven and hell "the healln point"
Posted: Sat Jul 25, 2015 9:51 am Post subject:
MEDIC code
hi guys I decided to make medic with deferent colors for each side I made every thing the weapon and the codes but it doesn't want to attack "heal" my units how to fix that! please reply soon _________________ QUICK_EDIT
Joined: 03 Jul 2015 Location: between heaven and hell "the healln point"
Posted: Mon Jul 27, 2015 2:38 pm Post subject:
MustaphaTR wrote:
Try adding AttackCursorOnFriendlies=yes to unit.
nothing happened and to LKO I already use the unused heal weapon and it doesn't want to heal unless I set it to defend mode or pressed on the medic twice _________________ QUICK_EDIT
nothing happened and to LKO I already use the unused heal weapon and it doesn't want to heal unless I set it to defend mode or pressed on the medic twice
Use scanners _________________
Quote:
Humans were born for two things: to pray and be productive.
Joined: 09 Mar 2008 Location: Osaka (JP)/Hong Kong/Germany
Posted: Mon Jul 27, 2015 6:11 pm Post subject:
Do you mean he does not automatically acquire wounded infantry as targets? Or do you mean he will not heal when ordered on a target manually?
Can you post the unit and weapon code? Also make sure HealScanRadius is set to a decent number, and you won't need VirtualScanner. Infact, using VirtualScanner (especially as a Primary) on a Medic unit may be the very reason why it's not working - Medic units should have a negative damage anti-organic weapon as Primary only - giving it a Primary with a regular warhead and non-negative damage (like VirtualScanner) will make the game not realize that it is dealing with a Medic. Use HealScanRadius exclusively for Medics, not VirtualScanner. This may apply to Secondary too, not sure.
Another note (but I think this is not the problem):
Because mouse.sha is missing the crucial frames in RA2/YR, the "heal" cursor in RA2/YR actually looks like a "No" cursor. But that is purely graphical, clicking infantry with this cursor still causes the Medic to heal that infantry. You can give it a proper healing cursor by editing the mouse.sha. However, this will also change the cursor used by the Carryall's "Tote" cursor definition, and maybe others, as they all reference the same frame of mouse.sha. So if you also have Carryalls, try to invent a cursor frame that would match both functions. _________________
Mao Zedong wrote:
Our mission, unfinished, may take a thousand years.
Joined: 03 Jul 2015 Location: between heaven and hell "the healln point"
Posted: Mon Jul 27, 2015 7:32 pm Post subject:
Millennium wrote:
Do you mean he does not automatically acquire wounded infantry as targets? Or do you mean he will not heal when ordered on a target manually?
Can you post the unit and weapon code? Also make sure HealScanRadius is set to a decent number, and you won't need VirtualScanner. Infact, using VirtualScanner (especially as a Primary) on a Medic unit may be the very reason why it's not working - Medic units should have a negative damage anti-organic weapon as Primary only - giving it a Primary with a regular warhead and non-negative damage (like VirtualScanner) will make the game not realize that it is dealing with a Medic. Use HealScanRadius exclusively for Medics, not VirtualScanner. This may apply to Secondary too, not sure.
Another note (but I think this is not the problem):
Because mouse.sha is missing the crucial frames in RA2/YR, the "heal" cursor in RA2/YR actually looks like a "No" cursor. But that is purely graphical, clicking infantry with this cursor still causes the Medic to heal that infantry. You can give it a proper healing cursor by editing the mouse.sha. However, this will also change the cursor used by the Carryall's "Tote" cursor definition, and maybe others, as they all reference the same frame of mouse.sha. So if you also have Carryalls, try to invent a cursor frame that would match both functions.
I meant manually I will try again
Edit: Yes it works in both manually by the clicking on the injured by no cursor and automatic by clicking on the medic twice or setting it to defend mode _________________ QUICK_EDIT
Joined: 03 Jul 2015 Location: between heaven and hell "the healln point"
Posted: Mon Jul 27, 2015 8:25 pm Post subject:
no I kept virtualscanner in secondary why I kept it so the AI can use the medic to cure his injured and to make the medic work automatically after I set it to defend mode. _________________ QUICK_EDIT
Joined: 09 Mar 2008 Location: Osaka (JP)/Hong Kong/Germany
Posted: Mon Jul 27, 2015 10:17 pm Post subject:
Well, that's fine, as long as it works.
I still don't think it's needed though, as Medic infantry is hardcoded to use HealScanRadius (Tiberian Sun's version of DefaultToGuardArea/GuardRange, but limited to Medics only, and set in General, rather than on the unit). It's still present and functional in RA2/YR. _________________
Mao Zedong wrote:
Our mission, unfinished, may take a thousand years.
There is a "heal icon".
From TB, it is in the .mix .
If one wants to extract, then change the pallete, it is then usable for your medic.
Are you talking about this or the A.I.'s use of? QUICK_EDIT
Joined: 09 Mar 2008 Location: Osaka (JP)/Hong Kong/Germany
Posted: Fri Aug 21, 2015 2:12 pm Post subject:
Default YR does not have a "heal icon" in any mix (an icon in SHP format). It does have two variations of HEAL*.shp (ONE and ALL), which are not icons, nor cursors, but animations to use for heal crates. Only one of these is used in YR (HEALONE I think, even though the healing crates heal all units), the other one is unused and in wrong palette.
There is afaik no way to set animations as cursors, so you cannot use HEALONE/HEALALL as cursors for healing. Maybe Ares will allow for this feature eventually, but for now, you are limited to the cursors in mouse.sha, and most of the call-ups for frames in that file are hard-coded (SuperWeapons being the only exception, as they can specify their own distinct cursors). _________________
Mao Zedong wrote:
Our mission, unfinished, may take a thousand years.
- firstly, when you leave the mouse cursor over him, you can place him in Automatic Area Guard. This means he will scan for nearby friendly infantry units that are damaged and run to heal them. You can set the 'scanning' range for this by amending the HealScanRadius= tag (in cells) in the [General] section of the RULES file.
- secondly, the game is supposed to indicate this unit by giving him a unique 'pip' in the form of a red cross (this goes in place of any veteran stripes). Although this image exists, Red Alert 2 does not use it. In Red Alert 2 DeeZire, each frame from the SHP of the unit itself has been modified to give this effect.
- finally, such a unit can perform the unique Action of 'Heal'. The cursor for this does not exist in Red Alert 2, so you get the default 'Stop' cursor instead. You can change this with the following steps;-
(i) extract MOUSE.SHP from the game (MOUSE.SHA in Yuri's Revenge)
(ii) convert it to PCX format using the MOUSEPAL.PAL palette
(iii) change frame #384 to whatever you want the 'Heal' cursor to be, although you cannot have an animated one (it must be one frame or image)
(iv) convert the PCX image sequence back into a SHP (or SHA) but make sure that you do not use SHP compression. The mouse cursor is drawn in the uppermost 'layer' on screen since it must always be available - if you compress images in this layer, you will get bad corruption of the cursor.
Joined: 09 Mar 2008 Location: Osaka (JP)/Hong Kong/Germany
Posted: Mon Aug 24, 2015 10:27 pm Post subject:
Yes. You must edit the mouse.sha (or mouse.shp, for vanilla RA2) itself. Of course nothing speaks against putting HEALONE or HEALALL as the heal cursor into mouse.sha, however since the Heal action only points to a single-frame cursor, you cannot use animated cursors for healing. So you cannot use the entire HEALONE/HEALALL animation as cursor. _________________
Mao Zedong wrote:
Our mission, unfinished, may take a thousand years.
PostPosted: Thu Dec 29, 2011 3:33 pm Post subject: Reply with quote
i have done this before, a bit different method:
- modify psychic ring weapon (IFV weapon of yuri) to damage with negative verses, Range=255, OmniFire=yes, and AffectEnemies=no (ARES needed)
- give OpportunityFire=yes, AttackFriendlies=yes, AttackCursorOnFriendlies=yes, DefaultToGuardArea=yes, and GuardRange=255 to the vehicle
Joined: 09 Mar 2008 Location: Osaka (JP)/Hong Kong/Germany
Posted: Thu Sep 17, 2015 3:09 pm Post subject:
A vehicle to heal UNITS? Units being other vehicles? Or infantry?
Healing vehicles with vehicles with infantry is pretty much copy-paste from the Nod repair vehicle from TS.
Healing infantry with vehicles is possible, but needs more complicated coding. _________________
Mao Zedong wrote:
Our mission, unfinished, may take a thousand years.
Healing infantry with vehicles is possible, but needs more complicated coding.
I am trying to make a "medic robot" out of a .shp that is coded as a vehicle.
I have tried to make a new area effect healing weapon but, to no avail. QUICK_EDIT
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum