fodev.net

FOnline Development => General Discussion => Topic started by: ronon dex on June 19, 2012, 09:17:53 pm

Title: I need Help with scripts - turning off town supply and 3D models
Post by: ronon dex on June 19, 2012, 09:17:53 pm
Code: [Select]
void CallTownSupply(Critter& victim, Critter& hostile) // Export
{
   if(IsValidForSupply(victim,hostile))
   {
      uint[] values={victim.Id,hostile.Id,0};
      ::CreateTimeEvent(__FullSecond+SUPPLY_TIME,"e_CallTownSupply",values,true);
   }
}

EDIT:

Code: [Select]
void CallTownSupply(Critter& victim, Critter& hostile) // Export
{
   if(IsValidForSupply(victim,hostile))
   {
      return;
     
      uint[] values={victim.Id,hostile.Id,0};
      ::CreateTimeEvent(__FullSecond+SUPPLY_TIME,"e_CallTownSupply",values,true);
   }
}

edit doesn't work.
how do I turn off script Bounty Hunters?
Title: Re: I need Help with scripts
Post by: Jimmy BoyX on June 19, 2012, 09:48:36 pm
... //Export
{return;
  if...

Try this shall work because I did it year ago.
Title: Re: I need Help with scripts
Post by: ronon dex on June 20, 2012, 04:53:44 am
{return;
  if...

Try this shall work because I did it year ago.
void CallTownSupply(Critter& victim, Critter& hostile) // Export
{
//Export
{return;

   if(IsValidForSupply(victim,hostile))
   {
           
      uint[] values={victim.Id,hostile.Id,0};
      ::CreateTimeEvent(__FullSecond+SUPPLY_TIME,"e_CallTownSupply",values,true);
   }
}

I write it here?
Title: Re: I need Help with scripts
Post by: ronon dex on June 20, 2012, 05:55:36 am
how do I turn off script 3D players model?
Title: Re: I need Help with scripts
Post by: JovankaB on June 20, 2012, 08:20:14 am
Quote
I write it here?

If you open a block with curly brace { you must close it with equivalent }.
Read some C/C++ book for beginners for such things. DevilScript syntax is based on these languages.

Return you wrote in beginning should work, except you will get a warning about unreachable code.
No idea why it doesn't work ??? maybe delete all world saves (wipe server) and check again.
Title: Re: I need Help with scripts
Post by: Jimmy BoyX on June 20, 2012, 08:29:48 am
Code: [Select]
void CallTownSupply(Critter& victim, Critter& hostile) // Export
{return;
   if(IsValidForSupply(victim,hostile))
   {
      uint[] values={victim.Id,hostile.Id,0};
      ::CreateTimeEvent(__FullSecond+SUPPLY_TIME,"e_CallTownSupply",values,true);
   }
}

Try this because my friend has problem with and someone help him and it work. I dont remember if it is but something like it.
Title: Re: I need Help with scripts
Post by: Skycast on June 20, 2012, 09:27:24 am
how do I turn off script Bounty Hunters?

Main.fos  line somewhere near 1176
change
Code: [Select]
CallTownSupply( cr, killer );to
Code: [Select]
//CallTownSupply( cr, killer );bounty disabled
Title: Re: I need Help with scripts - turning off town supply and 3D models
Post by: ronon dex on June 22, 2012, 06:39:06 am
Still can not I turn off the 3D player models. Please have someone Fo SDK free 3d models or script that disables it? I tried to turn it off, but without success. Someone please send me the script where they are banned 3d player models.
Title: Re: I need Help with scripts - turning off town supply and 3D models
Post by: Jimmy BoyX on June 22, 2012, 06:54:00 am
Go to _defines.fos and there are somethings like 3d player, head slot and naked (no bluesuit). Write // for disable (make comment).

If you wanna delete all stuff I cannot help you.
Title: Re: I need Help with scripts - turning off town supply and 3D models
Post by: Skycast on June 22, 2012, 09:17:20 am
If 3D models was turned on by default, that means that you are using very old sdk version *)