Project Perfect Mod Forums
:: Home :: Get Hosted :: PPM FAQ :: Forum FAQ :: Privacy Policy :: Search :: Memberlist :: Usergroups :: Register :: Profile :: Log in to check your private messages :: Log in ::


The time now is Wed Apr 24, 2024 3:34 pm
All times are UTC + 0
MEDIC code
Moderators: Global Moderators, Red Alert 2 Moderators
Post new topic   Reply to topic Page 1 of 1 [24 Posts] Mark the topic unread ::  View previous topic :: View next topic
Author Message
badbully
Grenadier


Joined: 03 Jul 2015
Location: between heaven and hell "the healln point"

PostPosted: Sat Jul 25, 2015 9:51 am    Post subject:  MEDIC code Reply with quote  Mark this post and the followings unread

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

_________________

Back to top
View user's profile Send private message Send e-mail Visit poster's website
MustaphaTR
Scorpion Sniper


Joined: 22 Jan 2015
Location: Kastamonu, Turkey

PostPosted: Mon Jul 27, 2015 5:59 am    Post subject: Reply with quote  Mark this post and the followings unread

Try adding AttackCursorOnFriendlies=yes to unit.

_________________
CnCD2K Mod: http://www.moddb.com/mods/red-alert-2-yuris-revenge-cncd2k-mod
Changed Dune Mod: http://www.moddb.com/mods/changed-dune
MustaphaTR's D2K Mod: http://www.moddb.com/mods/mustaphatrs-d2k-mod
Generals Alpha: http://www.moddb.com/mods/generals-alpha
Romanov's Vengeange: https://www.moddb.com/mods/romanovs-vengeance

Back to top
View user's profile Send private message
Lin Kuei Ominae
Seth


Joined: 16 Aug 2006
Location: Germany

PostPosted: Mon Jul 27, 2015 6:26 am    Post subject: Reply with quote  Mark this post and the followings unread

give an infantry Primary=Heal
the unused weapon is still there.

_________________
SHP Artist of Twisted Insurrection:  Nod buildings

Public SHPs
X-Mech Calendar (28 Mechs for GDI and Nod)
5 GDI, 5 Nod, 1 Mutant, 1 Scrin unit, 1 GDI building

Tools
Image Shaper______TMP Shop______C&C Executable Modifier

Back to top
View user's profile Send private message
badbully
Grenadier


Joined: 03 Jul 2015
Location: between heaven and hell "the healln point"

PostPosted: Mon Jul 27, 2015 2:38 pm    Post subject: Reply with quote  Mark this post and the followings unread

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

_________________

Back to top
View user's profile Send private message Send e-mail Visit poster's website
MustaphaTR
Scorpion Sniper


Joined: 22 Jan 2015
Location: Kastamonu, Turkey

PostPosted: Mon Jul 27, 2015 3:23 pm    Post subject: Reply with quote  Mark this post and the followings unread

Are you sure it is not healing. Game uses red unable cursor for heal weapons and carrialls but in fact they works.

_________________
CnCD2K Mod: http://www.moddb.com/mods/red-alert-2-yuris-revenge-cncd2k-mod
Changed Dune Mod: http://www.moddb.com/mods/changed-dune
MustaphaTR's D2K Mod: http://www.moddb.com/mods/mustaphatrs-d2k-mod
Generals Alpha: http://www.moddb.com/mods/generals-alpha
Romanov's Vengeange: https://www.moddb.com/mods/romanovs-vengeance

Back to top
View user's profile Send private message
deathreaperz
Commander


Joined: 20 May 2013
Location: Indonesia

PostPosted: Mon Jul 27, 2015 3:52 pm    Post subject: Reply with quote  Mark this post and the followings unread

badbully wrote:
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

Use scanners

_________________
Quote:
Humans were born for two things: to pray and be productive.


Back to top
View user's profile Send private message
badbully
Grenadier


Joined: 03 Jul 2015
Location: between heaven and hell "the healln point"

PostPosted: Mon Jul 27, 2015 4:19 pm    Post subject: Reply with quote  Mark this post and the followings unread

do you mean VirtualScanner I also use it.

_________________

Back to top
View user's profile Send private message Send e-mail Visit poster's website
Millennium
Commander


Joined: 09 Mar 2008
Location: Osaka (JP)/Hong Kong/Germany

PostPosted: Mon Jul 27, 2015 6:11 pm    Post subject: Reply with quote  Mark this post and the followings unread

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.  

Back to top
View user's profile Send private message
gameaddict11707
Grenadier


Joined: 15 Jul 2011

PostPosted: Mon Jul 27, 2015 6:34 pm    Post subject: Reply with quote  Mark this post and the followings unread

Maybe set GuardRange on the Medic too? Couldn't hurt.

Back to top
View user's profile Send private message
badbully
Grenadier


Joined: 03 Jul 2015
Location: between heaven and hell "the healln point"

PostPosted: Mon Jul 27, 2015 7:32 pm    Post subject: Reply with quote  Mark this post and the followings unread

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

_________________

Back to top
View user's profile Send private message Send e-mail Visit poster's website
Millennium
Commander


Joined: 09 Mar 2008
Location: Osaka (JP)/Hong Kong/Germany

PostPosted: Mon Jul 27, 2015 8:21 pm    Post subject: Reply with quote  Mark this post and the followings unread

So what exactly did you change?
You removed VirtualScanner?
Was VirtualScanner in Primary or Secondary?

_________________
Mao Zedong wrote:

Our mission, unfinished, may take a thousand years.  

Back to top
View user's profile Send private message
badbully
Grenadier


Joined: 03 Jul 2015
Location: between heaven and hell "the healln point"

PostPosted: Mon Jul 27, 2015 8:25 pm    Post subject: Reply with quote  Mark this post and the followings unread

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.

_________________

Back to top
View user's profile Send private message Send e-mail Visit poster's website
Millennium
Commander


Joined: 09 Mar 2008
Location: Osaka (JP)/Hong Kong/Germany

PostPosted: Mon Jul 27, 2015 10:17 pm    Post subject: Reply with quote  Mark this post and the followings unread

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.  

Back to top
View user's profile Send private message
Tod0001
Combat Engineer


Joined: 31 Dec 2013

PostPosted: Thu Aug 20, 2015 11:14 pm    Post subject: Reply with quote  Mark this post and the followings unread

[MEDIC]
UIName=Name:MEDIC
Name=Medic
Category=Soldier
Primary=Heal
Secondary=VirtualScanner
;;;Prerequisite=GAPILE
CrushSound=InfantrySquish
Strength=125
Pip=red
Armor=none
TechLevel=4
Sight=6
Speed=4
Owner=Russians,Confederation,Africans,Arabs,YuriCountry,British,French,Germans,Americans,Alliance
AllowedToStartInMultiplayer=no
Cost=600
Soylent=300
Points=5
VoiceSelect=CivAllSelect
VoiceMove=CivAllMove
VoiceAttack=CivAllAttackCommand
VoiceFeedback=CivAllFear
DieSound=CivAllDie
Locomotor={4A582744-9839-11d1-B709-00A024DDAFD1}
PhysicalSize=1
MovementZone=Infantry
ThreatPosed=0
SpecialThreatValue=1
GuardRange=8
SelfHealing=yes
ImmuneToRadiation=no
ImmuneToPsionics=no
PreventAttackMove=yes
Bombable=yes
Trainable=no
Size=1
AllowedToStartInMultiplayer=no
IFVMode=0
SelfHealing=yes
SpecialThreatValue=1
ImmuneToPoison=yes



I never pulled the heal .shp from the mix to enable cursor....
The "heal" cursor is in there....

Back to top
View user's profile Send private message
Tod0001
Combat Engineer


Joined: 31 Dec 2013

PostPosted: Thu Aug 20, 2015 11:31 pm    Post subject: Reply with quote  Mark this post and the followings unread

I aslo verify that the medic is working from "heal units" sound from box.....

Back to top
View user's profile Send private message
Tod0001
Combat Engineer


Joined: 31 Dec 2013

PostPosted: Fri Aug 21, 2015 12:23 am    Post subject: Reply with quote  Mark this post and the followings unread

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?

Back to top
View user's profile Send private message
Millennium
Commander


Joined: 09 Mar 2008
Location: Osaka (JP)/Hong Kong/Germany

PostPosted: Fri Aug 21, 2015 2:12 pm    Post subject: Reply with quote  Mark this post and the followings unread

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.  

Back to top
View user's profile Send private message
Tod0001
Combat Engineer


Joined: 31 Dec 2013

PostPosted: Sat Aug 22, 2015 3:05 pm    Post subject: Reply with quote  Mark this post and the followings unread

Quote:
- 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.

From http://cncguild.net/item-181?addview" target="_blank" rel="nofollow" class="postlink"> http://cncguild.net/item-181?addview cncguild.net .

Back to top
View user's profile Send private message
Millennium
Commander


Joined: 09 Mar 2008
Location: Osaka (JP)/Hong Kong/Germany

PostPosted: Mon Aug 24, 2015 10:27 pm    Post subject: Reply with quote  Mark this post and the followings unread

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.  

Back to top
View user's profile Send private message
Tod0001
Combat Engineer


Joined: 31 Dec 2013

PostPosted: Thu Aug 27, 2015 8:34 am    Post subject: Reply with quote  Mark this post and the followings unread

I just use "guard-area"...

Back to top
View user's profile Send private message
Tod0001
Combat Engineer


Joined: 31 Dec 2013

PostPosted: Mon Sep 14, 2015 12:05 am    Post subject: Reply with quote  Mark this post and the followings unread

Has anyone ever gotten a vehicle to heal units?

Back to top
View user's profile Send private message
Tod0001
Combat Engineer


Joined: 31 Dec 2013

PostPosted: Mon Sep 14, 2015 4:07 am    Post subject: Reply with quote  Mark this post and the followings unread

Quote:
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

and done!

Not working!....

Back to top
View user's profile Send private message
Millennium
Commander


Joined: 09 Mar 2008
Location: Osaka (JP)/Hong Kong/Germany

PostPosted: Thu Sep 17, 2015 3:09 pm    Post subject: Reply with quote  Mark this post and the followings unread

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.  

Back to top
View user's profile Send private message
Tod0001
Combat Engineer


Joined: 31 Dec 2013

PostPosted: Sat Sep 19, 2015 11:44 am    Post subject: Reply with quote  Mark this post and the followings unread

Quote:
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. Sad

Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [24 Posts] Mark the topic unread ::  View previous topic :: View next topic
 
Share on TwitterShare on FacebookShare on Google+Share on DiggShare on RedditShare on PInterestShare on Del.icio.usShare on Stumble Upon
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


Powered by phpBB © phpBB Group

[ Time: 0.2173s ][ Queries: 11 (0.0097s) ][ Debug on ]