Author Topic: Scripting a gun  (Read 4133 times)

Offline retrocity77

  • Scripter
  • Gold Member
  • *
  • Posts: 49
    • View Profile
    • Awards
Scripting a gun
« on: January 09, 2014, 09:06:50 PM »
So i started off basic and got this script... although i have no idea how to reload my gun... any tips you could give me?
How much swag could a Swag Cow swag if a swag cow could swag, swag?

Offline wakeboarderCWB

  • Gold Member
  • *
  • Posts: 2,486
  • Awards [OCRP Award] Social Player [OCRP Award] You Own The Mall [OCRP Award] Dedicated Player [OCRP Award] Millionaire
    • View Profile
    • Awards
Re: Scripting a gun
« Reply #1 on: January 09, 2014, 09:45:12 PM »
What's your script look like? Be sure to use the Reload() hook.

http://wiki.garrysmod.com/page/WEAPON/Reload

Offline retrocity77

  • Scripter
  • Gold Member
  • *
  • Posts: 49
    • View Profile
    • Awards
Re: Scripting a gun
« Reply #2 on: January 10, 2014, 04:40:31 PM »
This is a website i started off from, now i went on my own and i cant figure it out...

http://maurits.tv/data/garrysmod/wiki/wiki.garrysmod.com/index8e50.html
How much swag could a Swag Cow swag if a swag cow could swag, swag?

Offline wakeboarderCWB

  • Gold Member
  • *
  • Posts: 2,486
  • Awards [OCRP Award] Social Player [OCRP Award] You Own The Mall [OCRP Award] Dedicated Player [OCRP Award] Millionaire
    • View Profile
    • Awards
Re: Scripting a gun
« Reply #3 on: January 10, 2014, 04:50:23 PM »
Take a look at this hook and example.
http://maurits.tv/data/garrysmod/wiki/wiki.garrysmod.com/index1bed.html

The hook is used when you press whatever button is bound to +reload, and in the hook you simply handle animations, clips, etc.

Offline retrocity77

  • Scripter
  • Gold Member
  • *
  • Posts: 49
    • View Profile
    • Awards
Re: Scripting a gun
« Reply #4 on: January 10, 2014, 08:06:29 PM »
ok, thanks for the help wake
How much swag could a Swag Cow swag if a swag cow could swag, swag?

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal