Author Topic: anyone is ready to help me ?  (Read 1088 times)

0 Members and 1 Guest are viewing this topic.

Offline mich1103

  • Flagrunner
  • ****
  • Posts: 558
  • Did you say chocolate ? O.o
    • ZoMbIe-DeStRoYeR pk server
anyone is ready to help me ?
« on: March 06, 2010, 09:35:32 am »
Okayy i know all people will say ''LEARN SCRIPTING BY YOURSELF''
but a guy's have arealdy said to me, that each person learn by his way
My way is to read script and see how he made it so please take this info:
and make my script  working and if you want you can say how you do it .

this is my info for my script :


1-OnActivateServer:
/say Zombie game start !
/addbot2 zombie
/addbot2 zombie
/addbot2 zombie

2-OnMapChange
/kick Zombie
/kick Serker Zombie
/kick Burning Zombie
/kick Taliban
/kick Ghost
/kick Slicer Zombie

3-OnMapChange
/say The zombie game will begin in 20 second !
(in 20 second that will do this command ) :
/say Zombie game start ! Pay attention to brain eater !
/addbot2 zombie
/addbot2 zombie
/addbot2 zombie

4-if TimeLeft = 8(minute)
/say 3 more person got infected ! The population of zombie is now : 6.
/addbot2 slicerzombie
/addbot2 burningzombie
/addbot2 zombie

5-if TimeLeft = 6(minute)
/say 3 more person got infected ! The population of zombie is now : 9.
/addbot2 serkerzombie
/addbot2 taliban
/addbot2 zombie

6-if TimeLeft = 4(minute)
/say 3 more person got infected ! The population of zombie is now : 12
/addbot2 zombie
/addbot2 ghost
/addbot2 slicerzombie

7-if TimeLeft = 2(minute)
/say 3 more person got infected ! The population of zombie is now : 15.
/addbot2 ghost
/addbot2 taliban
/addbot2 slicerzombie

Offline croat1gamer

  • Veteran
  • *****
  • Posts: 1327
  • OMG CHANGING AVATAR!!! ^ω^
Re: anyone is ready to help me ?
« Reply #1 on: March 06, 2010, 10:20:22 am »
When we say "learn to script", we mean that you learn and understand what means what in the syntax and that you know to write the syntax properly.
Last year, I dreamt I was pissing at a restroom, but I missed the urinal and my penis exploded.

Offline mich1103

  • Flagrunner
  • ****
  • Posts: 558
  • Did you say chocolate ? O.o
    • ZoMbIe-DeStRoYeR pk server
Re: anyone is ready to help me ?
« Reply #2 on: March 06, 2010, 10:35:16 am »
wath is a syntax ?

Offline croat1gamer

  • Veteran
  • *****
  • Posts: 1327
  • OMG CHANGING AVATAR!!! ^ω^
Re: anyone is ready to help me ?
« Reply #3 on: March 06, 2010, 10:47:22 am »
Last year, I dreamt I was pissing at a restroom, but I missed the urinal and my penis exploded.

Offline mich1103

  • Flagrunner
  • ****
  • Posts: 558
  • Did you say chocolate ? O.o
    • ZoMbIe-DeStRoYeR pk server
Re: anyone is ready to help me ?
« Reply #4 on: March 06, 2010, 01:19:47 pm »
the thing i dont know is that :
Procedure AppOnIdle(Ticks: integer)
begin
   if Ticks mod (60 * 60) = 0 then      <----//WHAT MEAN THAT
   begin
          if TimeLeft = 8 then
      begin

Offline Gizd

  • Flagrunner
  • ****
  • Posts: 586
  • (Re)tired
    • Eat-this! community site
Re: anyone is ready to help me ?
« Reply #5 on: March 06, 2010, 03:06:18 pm »
   if Ticks mod (60 * 60) = 0 then      <----//WHAT MEAN THAT
That it will continue if rest from 60*60/Ticks is 0

Offline mich1103

  • Flagrunner
  • ****
  • Posts: 558
  • Did you say chocolate ? O.o
    • ZoMbIe-DeStRoYeR pk server
Re: anyone is ready to help me ?
« Reply #6 on: March 06, 2010, 03:26:16 pm »
i dont understand ???

Offline DorkeyDear

  • Veteran
  • *****
  • Posts: 1507
  • I also go by Curt or menturi
Re: anyone is ready to help me ?
« Reply #7 on: March 06, 2010, 07:47:38 pm »
mod is very closely related to dividing. There are three operators that are related to dividing:
/
div
mod

the '/' operator returns generally a floating point value (decimals) of dividing the left by the right

the 'div' operator (short for divide) returns an integer (no decimals) of dividing the left by the right

the 'mod' operator (short for modulo, or modulus) is different than those two. It is the remainder when you divide two numbers. For example if you try to divide 14 by 3, you know 3 goes into 14 4 times, and there is 2 left over. mod gives you this '2' number.

So when we say Ticks mod (60*60) = 0, we are trying to say "When the remainder of dividing Ticks by 3600 (60*60) is equal to zero"
Every second, Ticks increases by 60 (60 ticks per second). doing (Ticks div 60) mod 60 is equivalent to the previous statement. Aka, we are trying to evaluate TimeInSeconds mod 60 = 0. When we try dividing various numbers by 60, only certain ones will have a remainder of zero: 0, 60, 120, 180, etc. This means every minute, the action is going to occur.