View unanswered posts | View active topics It is currently Sun Jan 05, 2025 1:53 am



Reply to topic  [ 6 posts ] 
 Very weird problem... 
Author Message
User avatar

Joined: Sat Jun 19, 2010 5:02 pm
Posts: 331
Location: Mekkan
Reply with quote
Post Very weird problem...
So, for Sweet Dreams I have multiple missions, and my checkpoints Lua scripts (called save stones in-campaign) have to communicate with the mission itself to work. So, I have to have different Lua scripts that use different mission names to communicate. (SweetDreams, SweetDreams2, etc.) But, the Lua isn't the problem. So, to make multiple checkpoints, I had to make several MOSRotatings (Checkpoint, Checkpoint 2) that used multiple different Lua scripts.

The problem is, When I create Checkpoint 2 in the ini, even when I try to create just Checkpoint, not Checkpoint 2, (via Lua) it makes Checkpoint 2! I can tell because the checkpoint keeps giving errors from Checkpoint 2.lua! If I try to make Checkpoint 2, it makes Checkpoint 2 just fine though. If I remove Checkpoint 2 from the ini, it'll make a normal Checkpoint just fine. In fact, I tested, what ever I name Checkpoint, it always creates Checkpoint 2!

Sorry if this is ridiculously confusing. Does anyone know what's wrong?

EDIT: Since no-one's replying, here's the gist: I have a checkpoint. I have to make multiple different types of checkpoints. But whenever I make a second type, no matter what, even if I try to make the first, it always makes the second. How do I fix this?


Thu Sep 02, 2010 1:33 am
Profile
User avatar

Joined: Tue Jun 12, 2007 11:52 pm
Posts: 13144
Location: Here
Reply with quote
Post Re: Very weird problem...
If you're using a "CopyOf = Checkpoint" to create "Checkpoint 2", make sure Checkpoint 2's PresetName is after the CopyOf line.

Edit: PresetName lines should be after CopyOf lines in general.


Thu Sep 02, 2010 10:06 pm
Profile
User avatar

Joined: Wed Jan 07, 2009 10:26 am
Posts: 4074
Location: That quaint little British colony down south
Reply with quote
Post Re: Very weird problem...
Anything you want to keep will have to be after the CopyOf, otherwise the CopyOf just overwrites it.


Fri Sep 03, 2010 7:38 am
Profile WWW
User avatar

Joined: Wed Feb 17, 2010 12:07 am
Posts: 1545
Location: That small peaceful place called Hell.
Reply with quote
Post Re: Very weird problem...
411570N3 wrote:
Anything you want to keep will have to be after the CopyOf, otherwise the CopyOf just overwrites it.


Not the entire bit of code.

Whatever is defined in the original Code will stay unless the CopyOf defines it again.
Ex.

Code:
AddEffect = MOSRotating
   PresetName = Soldier Misc Gib A
   Mass = 7.32
   Sharpness = 1
   HitsMOs = 1
   GetsHitByMOs = 1
   SpriteFile = ContentFile
      FilePath = Coalition.rte/Actors/Soldier/MiscGibA.bmp
   FrameCount = 1
   SpriteOffset = Vector
      X = -4
      Y = -4
   AngularVel = 6
   AtomGroup = AtomGroup
      AutoGenerate = 1
      Material = Material
         CopyOf = Flesh
      Resolution = 4
      Depth = 0
   DeepCheck = 0
   AddGib = Gib
      GibParticle = MOPixel
         CopyOf = Drop Blood
      Count = 15
      Spread = 2.25
      MaxVelocity = 15
      MinVelocity = 5
   GibImpulseLimit = 120
   GibWoundLimit = 2


And then you go

Code:
AddEffect = MOSRotating
   CopyOf = Soldier Misc Gib A
   PresetName = Whatever
   Mass = 5
   AddGib = Gib
      GibParticle = MOPixel
         CopyOf = Drop Blood
      Count = 15
      Spread = 2.25
      MaxVelocity = 15
      MinVelocity = 5


Then the Mass of the New MOSRotating will change but the original Gib will stay and the newly defined MOSRotating will Gib that and whats defined in the new one.

Hope that helps.


Fri Sep 03, 2010 9:10 am
Profile
User avatar

Joined: Wed Jan 07, 2009 10:26 am
Posts: 4074
Location: That quaint little British colony down south
Reply with quote
Post Re: Very weird problem...
Right. Yeah, that's what I meant. Sorry for any misunderstandings that may have caused.


Fri Sep 03, 2010 9:18 am
Profile WWW
User avatar

Joined: Sat Jun 19, 2010 5:02 pm
Posts: 331
Location: Mekkan
Reply with quote
Post Re: Very weird problem...
Hey, I never used copyof in my ini at all. I realized that would have been a smart idea and I tried it; no difference. I'll just make one type of checkpoint with really complex code that checks which mission it's in via mass to do it... (Each mission will give its checkpoints certain masses when they are spawned)

EDIT: It worked. Thanks anyway!


Fri Sep 03, 2010 12:30 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 6 posts ] 

Who is online

Users browsing this forum: No registered users


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:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.060s | 13 Queries | GZIP : Off ]