Jump to content

ammo variable system


Andr3wHur5t
 Share

Recommended Posts

Hi

so i am working on a ammo variables system and what i have come up with seems complacated. dose anyone have a more effecent idea

 

 

\---z = 1

\---clip = 30

\---ammo = 300

\---reloadstart = ???

\---reloadend = ???

\---reloadk = ???

\--------------if RecevedMessage(gun,"shot") then

\------------------clip=z-clip

\------------------if clip = 0 then

\---------------------if ammo = 0 then

\------------------------notify(out of ammo,x,y)

\------------------------end

\---------------------if else then

\------------------------PlayAnmationFrames(player,reloadstart(),reloadend())

\------------------------if anmationFrame(player,Reloadk) then

\-----------------------> ammo = ammo-z

\-----------------------| clip = clip+z

\-----------------------| if clip() = clipfull() then

\-----------------------| end

\-----------------------| if else then

\-----------------------| if ammo = 0 then

\-----------------------| end

\-----------------------> if else then

 

 

the script betwen the > and | are suposed to be repeeted how meny bullets there are in a clip

Edited by ryao

Tools:

AC3D | 3D Canvas(pro) | Texture Maker(pro) | Genetica(basic) | 3D World Studio | Fragmotion |Leadwerks 2 | XNA 4 | Visual Studio 2010 Professional | XCode 5.x |UU3D Pro

 

Programing & Scripting Languages:

C |C++ | C# | Obj-C | LUA | Javascript | PHP | Ruby

Link to comment
Share on other sites

thanks,

did not know that

Tools:

AC3D | 3D Canvas(pro) | Texture Maker(pro) | Genetica(basic) | 3D World Studio | Fragmotion |Leadwerks 2 | XNA 4 | Visual Studio 2010 Professional | XCode 5.x |UU3D Pro

 

Programing & Scripting Languages:

C |C++ | C# | Obj-C | LUA | Javascript | PHP | Ruby

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...