Home   Help Search Login Register  

Author Topic: need help w/ guba  (Read 1695 times)

0 Members and 1 Guest are viewing this topic.

Offline dalton

  • Members
  • *
  • i R n00b
need help w/ guba
« on: 29 Jan 2004, 04:16:22 »
hey i need 2 find out how to make guba in my mission. i know how to do angelina but how about guba? ne1 know?
"freedom aint free"

Dubieman

  • Guest
Re:need help w/ guba
« Reply #1 on: 29 Jan 2004, 05:04:40 »
What do you mean? Do you want his body and head?
Just download kegety's editor add on. It has Guba+clothes, Angelina+clothes, eastern western and resistance spies and all the buildings and objects in the game that can be put on the map.

Best download ever.... :cheers:

Offline dalton

  • Members
  • *
  • i R n00b
Re:need help w/ guba
« Reply #2 on: 29 Jan 2004, 12:54:05 »
ok i tried that but how do u give him a weapon? cuz i tried the addweapon thing but it didnt work
"freedom aint free"

PsyWarrior

  • Guest
Re:need help w/ guba
« Reply #3 on: 29 Jan 2004, 13:05:47 »
Greetings Dalton,

Put this in Guba's init line:

this addMagazines ["ak74" 3]; this addWeapon "ak74"

I think this is correct. It might me ak74Mag for the magazines, but I can't be sure. I usually check this stuff in the Online ComRef, but I can't access it at the moment ::).
If that doesn't work try:

this addMagazine "ak74"; this addMagazine "ak74"; this addMagazine "ak74"; this addMagazine "ak74"; this addWeapon "ak74"

Or try replacing ak74 with ak74mag for the addMagazine command.

If it still doesn't work, post up exactly what you typed here, and we'll try to fix it...

 8)

-Supreme Commander PsyWarrior
-Psychic Productions

P.S. And now, there's General Baron's Editor addon, even better than kegetys.
« Last Edit: 29 Jan 2004, 13:06:43 by PsyWarrior »

Offline dalton

  • Members
  • *
  • i R n00b
Re:need help w/ guba
« Reply #4 on: 29 Jan 2004, 13:19:37 »
it didnt work >:(
this is exactly what i did:
this addweapon ak47; this addmagazine ak47; this addmagazine ak47; this addmagazine ak47; this addmagazine ak47; this addmagazine ak47; this addmagazine ak47; this addmagazine ak47; this addmagazine ak47; this addmagazine ak47
"freedom aint free"

Offline dalton

  • Members
  • *
  • i R n00b
Re:need help w/ guba
« Reply #5 on: 29 Jan 2004, 13:20:48 »
but i know there is a way cuz guba was in rts2 w/ a gun and i know how to make angelina w/o the addon
"freedom aint free"

PsyWarrior

  • Guest
Re:need help w/ guba
« Reply #6 on: 29 Jan 2004, 13:22:21 »
Speech Marks.

This addMagazine "ak74"

and add the magazines first, or guba will have no ammo chambered into his gun.

Try it now...

-Supr. Cmdr. PsyWarrior
-Psychic Productions
« Last Edit: 29 Jan 2004, 13:23:20 by PsyWarrior »

Offline dalton

  • Members
  • *
  • i R n00b
Re:need help w/ guba
« Reply #7 on: 29 Jan 2004, 14:13:38 »
he neva had a gun
"freedom aint free"

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:need help w/ guba
« Reply #8 on: 29 Jan 2004, 21:46:34 »
Of course he didn't have a gun........you left out the quotes.

this addweapon "ak47"

NOT

this addweapon ak47

The same does for the magazines.



Planck
I know a little about a lot, and a lot about a little.

Dubieman

  • Guest
Re:need help w/ guba
« Reply #9 on: 30 Jan 2004, 00:48:57 »
I was once as angry with the script init lines as you when I began, but the init lines or script is being read by a computer so it will screw with you a lot.... :(

Anyways, planck is right, the only thing is I think the game is picky about capitals too. :wow:

So use this......

this addweapon "AK74"; this addmagazine "Ak74";

this line of code needs to be copied exactly, and will give Guba one AK74 and one magazine, it doesn't matter what goes first cause he will automatically reload when the mission starts, repeat the addmagazine commands for more ammo. :)

Just a rundown..

     ;     this symbol tells the com to stop reading and begin reading the next line so its like a period in a sentence.   If I said "Hello Dalton." that's easy to read

If I said "Hello Dalton why you so unhappy today you depressed."  You would go what the hell is he saying...

Any weapon or magazine needs " "   marks to specify what it is. Most all script lines begin "this" meaning it starts right when the mission begins.
Hope it helps. :wave:

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:need help w/ guba
« Reply #10 on: 30 Jan 2004, 01:03:12 »
OFP code is supposed to be case insensitive, so it should not matter whether you use CAPITALS or lower case.    However, the odd counterexample has been reported.

Lines of code starting with "this" can happen anywhere in a mission, it doesn't have to be at the start.   However, any code in the init line of a unit will be executed at the start of the mission.    (I think the game does init lines before the triggers, though it may be the other way around I can never remember.)

Code in init lines of units usually refer to that unit, and that is what the "this" means in a unit in init field - execute the code on this unit.

In a trigger, "this" is something entirely different:  it is a boolean (true or false) determined by whether the conditions in the Activation Box are met or not.

"_this" with an underscore before it means something else again, but we won't get into that here.  The crucial point is that the names of weapons and magazines fall into a class of things which are known as strings, and strings must be enclosed by quotes " " or curly brackets { }.
Plenty of reviewed ArmA missions for you to play

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:need help w/ guba
« Reply #11 on: 30 Jan 2004, 01:04:31 »
Fortunately there is no case sensitivity in scripts.........just syntax sensitivity.   ;D


As has been stated before, if you add at least 1 magazine before the weapon, the weapons will start off as loaded.


Planck
I know a little about a lot, and a lot about a little.

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:need help w/ guba
« Reply #12 on: 30 Jan 2004, 01:07:24 »
 ;) No need for the editor update. To put Guba in your mission, you need to edit the SQM (like you did for Angelina) with this classname:

GeneralE

Now, I gotta correct you on some things, RoachKilla :)

Quote
Anyways, planck is right, the only thing is I think the game is picky about capitals too.

When it comes to things like weapon/unit names, no, the game doesn't care about caps. When it comes to labels and variables, the game very much DOES care though.

Quote
it doesn't matter what goes first cause he will automatically reload when the mission starts, repeat the addmagazine commands for more ammo.

If you first give the guy a weapon, then give the guy some ammo, he will start with no magazine loaded in his gun. He WON'T reload when the mission starts: he will reload when he tries to fire. If you give him a magazine BEFORE giving him a gun, then he will start out with ammo in the weapon.

Quote
Most all script lines begin "this" meaning it starts right when the mission begins.

Wrong  ;)
"this" refers to whichever UNIT the code is being run from. So lets say I've got a guy named "bob", and I run this from his init field:

this setdammage 1

Bob will be set to full damage (killed) as soon as the mission starts. However, I could get the exact same result by putting this line in ANYONE else's init field:

bob setdammage 1

So you see, "this" basically replaces the name of the unit, when using init fields. This way you don't have to name every single unit you place: you can just use "this" instead.

A little more advanced: "this" takes on different meanings when it is used in different contexts. For example, when you call a script, the parameters you pass to it can be used in the script with "_this".
« Last Edit: 30 Jan 2004, 01:12:02 by General Barron »
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Offline dalton

  • Members
  • *
  • i R n00b
Re:need help w/ guba
« Reply #13 on: 30 Jan 2004, 02:55:49 »
ok it worked ;D
but when i picked up the weapon after i killed him, the ammo said "0"
btw the weapon is a g36
"freedom aint free"

Offline dalton

  • Members
  • *
  • i R n00b
Re:need help w/ guba
« Reply #14 on: 30 Jan 2004, 03:02:51 »
nm i got it. i had 2 do "g36amag" instead of "g36a"
"freedom aint free"