View unanswered posts | View active topics It is currently Mon Dec 30, 2024 9:29 pm



Reply to topic  [ 11 posts ] 
 Need help with defining Muzzle Flash 
Author Message
User avatar

Joined: Sat Feb 12, 2011 8:05 pm
Posts: 39
Location: Somewhere over the Double Rainbow
Reply with quote
Post Need help with defining Muzzle Flash
Hi, forum!

I'm new to modding and I don't know much. And like all new modders, I have a problem. The problem is that B23 crashes whenever I try to load a copied MDC digger (again, still new at modding and figuring out how to make things) and it says that it is

"Referring to an instance ('PlasmaGlowSmall') [Which is in the MDC Effects folder] to copy from hasn't been defined! This error is at line 145 and about 3/4 down the page.

If possible, please help and try to remedy this. Thanks!


Attachments:
BrokenDigger.ini [4.33 KiB]
Downloaded 153 times
Tue Feb 15, 2011 12:54 am
Profile
User avatar

Joined: Tue Jun 12, 2007 11:52 pm
Posts: 13144
Location: Here
Reply with quote
Post Re: Need help with defining Muzzle Flash
I'm assuming "PlasmaGlowSmall" is an image file?

Muzzle flashes are objects in CC, and require code as well as an image file (or multiple images) to function.

Example code:
Code:
AddEffect = Attachable
   PresetName = Muzzle Flash Pistol
   Mass = 0.0001
   HitsMOs = 0
   GetsHitByMOs = 0
   SpriteFile = ContentFile
      FilePath = Base.rte/Effects/Pyro/MuzzleFlash02.bmp
   FrameCount = 3
   SpriteOffset = Vector
      X = -2
      Y = -6
   AtomGroup = AtomGroup
      AutoGenerate = 1
      Material = Material
         CopyOf = Air
      Resolution = 2
      Depth = 100
   DeepGroup = AtomGroup
      AutoGenerate = 1
      Material = Material
         CopyOf = Air
      Resolution = 3
      Depth = 100
   DeepCheck = 0
   JointStrength = 10000
   JointStiffness = 1
   ScreenEffect = ContentFile
      FilePath = Base.rte/Effects/Glows/YellowSmall.bmp
   DrawAfterParent = 0


Tue Feb 15, 2011 2:04 am
Profile
User avatar

Joined: Sat Feb 12, 2011 8:05 pm
Posts: 39
Location: Somewhere over the Double Rainbow
Reply with quote
Post Re: Need help with defining Muzzle Flash
Ah, thanks so much! Pretty sure I understand now.
Actually, I do not. When I looked at any other digger, even other weapons, the code you gave me did not seem to be anywhere. Could it be in a separate file, maybe? Like I said, I really don't know much about modding. :-(


Tue Feb 15, 2011 7:10 pm
Profile
DRL Developer
DRL Developer

Joined: Fri May 15, 2009 10:29 am
Posts: 4107
Location: Russia
Reply with quote
Post Re: Need help with defining Muzzle Flash
It's in Base.rte/Effects/Pyro/Pyro.ini.


Tue Feb 15, 2011 7:34 pm
Profile
User avatar

Joined: Sat Feb 12, 2011 8:05 pm
Posts: 39
Location: Somewhere over the Double Rainbow
Reply with quote
Post Re: Need help with defining Muzzle Flash
What I've done so far:

Reverted the Muzzle Flash Copy to the default: Digger Muzzle Flash
Code:
Flash = Attachable
      CopyOf = Digger Muzzle Flash


Copied the Effects folder from MDC over to my mod's folder, and added the file to the index

I still get the problem, and I honestly have no idea what to do. :oops:


Tue Feb 15, 2011 9:12 pm
Profile
User avatar

Joined: Tue Jun 12, 2007 11:52 pm
Posts: 13144
Location: Here
Reply with quote
Post Re: Need help with defining Muzzle Flash
Is there code for "Digger Muzzle Flash"?


Tue Feb 15, 2011 9:50 pm
Profile
User avatar

Joined: Sat Feb 12, 2011 8:05 pm
Posts: 39
Location: Somewhere over the Double Rainbow
Reply with quote
Post Re: Need help with defining Muzzle Flash
Yes. It's in the Effects.ini file I put in my mod's folder.
Code:
AddEffect = Attachable
   PresetName = Digger Muzzle Flash
   HitsMOs = 0
   GetsHitByMOs = 0
   SpriteFile = ContentFile
      FilePath = Base.rte/Null.bmp
   FrameCount = 1
   SpriteOffset = Vector
      X = -1
      Y = -1
   AtomGroup = AtomGroup
      AutoGenerate = 1
      Material = Material
         CopyOf = Air
      Resolution = 2
      Depth = 100
   DeepGroup = AtomGroup
      AutoGenerate = 1
      Material = Material
         CopyOf = Air
      Resolution = 3
      Depth = 100
   DeepCheck = 0
   JointStrength = 10000
   JointStiffness = 1
   ScreenEffect = ContentFile
      FilePath = Base.rte/Effects/Glows/YellowSmall.bmp
   EffectStartTime = 0
   EffectStopTime = 100
   EffectStartStrength = 1
   EffectStopStrength = 0
   DrawAfterParent = 0



Tue Feb 15, 2011 9:55 pm
Profile
User avatar

Joined: Tue Jun 12, 2007 11:52 pm
Posts: 13144
Location: Here
Reply with quote
Post Re: Need help with defining Muzzle Flash
Make sure the Effects.ini loads before the device code.


Tue Feb 15, 2011 10:20 pm
Profile
User avatar

Joined: Sat Feb 12, 2011 8:05 pm
Posts: 39
Location: Somewhere over the Double Rainbow
Reply with quote
Post Re: Need help with defining Muzzle Flash
That seems to make sense. Am I able to change the name of Effects.ini to be able to load it before the Devices folder?


Tue Feb 15, 2011 10:43 pm
Profile
User avatar

Joined: Tue Jun 12, 2007 11:52 pm
Posts: 13144
Location: Here
Reply with quote
Post Re: Need help with defining Muzzle Flash
All you need to do is make the FilePath to the effects file come before the FilePath of the digger's file.


Wed Feb 16, 2011 12:04 am
Profile
User avatar

Joined: Sat Feb 12, 2011 8:05 pm
Posts: 39
Location: Somewhere over the Double Rainbow
Reply with quote
Post Re: Need help with defining Muzzle Flash
Thank jebus, I finally made it work. Sorry to waste your time. Thanks!


Wed Feb 16, 2011 12:50 am
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 11 posts ] 

Who is online

Users browsing this forum: Google [Bot]


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 post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.033s | 15 Queries | GZIP : Off ]