Alliedassault

Alliedassault (alliedassault.us/index.php)
-   Tech Questions & Problems (alliedassault.us/forumdisplay.php?f=8)
-   -   I need Help with Single Player Scripts??????????????........ (alliedassault.us/showthread.php?t=12170)

carlpenn 11-10-2002 12:32 PM

I need Help with Single Player Scripts??????????????........
 
Hi all,
Im creating a Single Player map for MOHAA and need help with my scripting I can do the basics - give player weapons etc but need to learn more.....
How do I get the german AI to use the MG42 posts? how to get the Allies to follow me across the map e.t.c. I am new to editing so I apologise if I seem a little thick !!!!!!!!!
HE HE HE
angel:

I have browsed through the forum but havent found what Im looking for

oOo:

jv_map 11-10-2002 01:17 PM

http://dynamic4.gamespy.com/%7Emap/phpB ... .php?t=454

carlpenn 11-10-2002 01:25 PM

Cheers !!!!!!!!!!

Im off to try out what you said !!

You have helped a lot..........

THANKYOU !!!!!!!

carlpenn 11-10-2002 02:42 PM

Now can anybody tell me how to get a german using the MG42????????
HE HE HE................

fire1: M16:

jv_map 11-11-2002 01:43 AM

'nother link
 
http://www.planetmedalofhonor.com/map/t ... otter.html

carlpenn 11-11-2002 09:57 AM

Excellent..............

Are you related to Yoda by any chance ???????????????

he he

Just looked at your link and gonna do it tonight........cool mate

thanks again.......... cool:

carlpenn 11-12-2002 09:41 AM

ok i tried what it says in there ............but my mg42 is still inactive?
AAAAAAAAARRRRRRRRRRRRRRRGGGGGGGHHH !!!!!!!!!!!!!!

here is my script..............where is it wrong?



exec global/ai.scr


level waittill prespawn

main:

$player item weapons/colt45.tik
$player item weapons/m1_garand.tik
$player item weapons/bar.tik
$player item weapons/m2frag_grenade_SP_start.tik
$player ammo pistol 200
$player ammo rifle 200
$player ammo mg 500
$player ammo grenade 10

$player stufftext"tmstart sound/music/mus_17a_mystery.mp3"

thread mg_targeting $mg42_1

exec global/friendly.scr

level waittill spawn

end

$mg42_1 thread global/mg42_active.scr::mg42 1024


level.friendly1 thread global/friendly.scr::friendlythink
level.friendly1.friendtype = 1 //toggle this to -1 to shut down following
level.friendly1.distance = 64


level.friendly2 thread global/friendly.scr::friendlythink
level.friendly2.friendtype = 1 //toggle this to -1 to shut down following
level.friendly2.distance = 64

level.friendly3 thread global/friendly.scr::friendlythink
level.friendly3.friendtype = 1 //toggle this to -1 to shut down following
level.friendly3.distance = 64



level.friendly4 thread global/friendly.scr::friendlythink
level.friendly4.friendtype = 1 //toggle this to -1 to shut down following
level.friendly4.distance = 64



level.friendly4 thread global/friendly.scr::friendlythink
level.friendly4.friendtype = 1 //toggle this to -1 to shut down following
level.friendly4.distance = 64



level.friendly5 thread global/friendly.scr::friendlythink
level.friendly5.friendtype = 1 //toggle this to -1 to shut down following
level.friendly5.distance = 64

Is that ok or net?
how do i precache the german mg42 gunner?

jv_map 11-12-2002 10:47 AM

Yo no worry man
 
Move 'main:' to the top of your script file and 'end' to the end of it.

stufftext"tmstart ...

Should be stufftext "tmstart ...

thread mg_targeting ...

That thread doesn't exist.

Precaches are in mymapname_precache.scr

For example add a line like the following:
cache models/human/wehrmact_grenadier.tik

(could be grenadeir as EA developers can't spell)

carlpenn 11-12-2002 10:51 AM

ok cheers................
i copied mg_target line from another script??
strange !!!!!!!!

ive read through my script twice over to make sure i made no spelling errors. ill try what you said............

thanks a lot........... eatthis:

jv_map 11-12-2002 11:36 AM

thread mg_targeting $mg42_1

That line is supposed to refer to a different part of the script, e.g.
mg_targeting local.mg:
(..)
end

Thus, the thread command starts a separate script process that needs to be defined somewhere in the script or in an other script file.

carlpenn 11-12-2002 11:41 AM

ok.........cheers.

Told you i was thick at this.........he he

carlpenn 11-13-2002 05:58 AM

I done all you said and still dont get the gunners to spawn.....

in map:- info pathnode $targetname/ mg42_spawner_gunner
info pathnode $targetname/ mg42_gunner_path
then I scripted what you said and still no reaction from them !!

what line do i need in the precache script ?
i have the cache/models/ai_german_afrikacorps_grenadier.tik
do i need any other lines ?

ive even removed and reapplied the pathnodes with no luck.

everything else is fine:: the friendlys follow me round like lost sheep and the other german ai respond within set distance etc..its just the mg42 gunners im having trouble with...... fire2:

jv_map 11-13-2002 10:22 AM

I think the tutorial is a little confusing (it's not mine, though my tutorials are confusing too).

It says:
[quote:69c7c]Give it a $targetname / mg42_gunner_path.[/quote:69c7c]
This means add 'targetname' in the 'key' field, press enter, and then type 'mg42_spawner_gunner' in the 'value' field. Finally press enter again to assign this property.

My guess it you could perhaps have entered '/ mg42_spawner_gunner' as as targetname, which is not correct.

Also make sure the spawn points have a #spawn value.

carlpenn 11-13-2002 10:57 AM

ok this is how i entered info.......



KEY = $targetname
Value= mg42_spawner_gunner

KEY = $spawn
VALUE = 2

and then


KEY = $targetname
Value= mg42_gunner_path
is that correct? cuz they didnt work off that?

carlpenn 11-13-2002 05:43 PM

i am still unable to get them working:

so heres my script again:-

main:


exec global/ai.scr


level waittill prespawn

$player item weapons/colt45.tik
$player item weapons/m1_garand.tik
$player item weapons/bar.tik
$player item weapons/m2frag_grenade_SP.tik
$player ammo pistol 200
$player ammo rifle 200
$player ammo mg 500
$player ammo grenade 6

$player stufftext "tmstart sound/music/mus_14a_action.mp3"

exec global/friendly.scr

level waittill spawn

$mg42_gunner.enableEnemy = 0
$mg42_1 thread global/mg42_active.scr::mg42 1024

level.friendly1 say ("dfr_head_attack_"+level.friendly1.voicetype)


level.friendly1 thread global/friendly.scr::friendlythink
level.friendly1.friendtype = 1 //toggle this to -1 to shut down following
level.friendly1.distance = 128


level.friendly2 thread global/friendly.scr::friendlythink
level.friendly2.friendtype = 1 //toggle this to -1 to shut down following
level.friendly2.distance = 128

level.friendly3 thread global/friendly.scr::friendlythink
level.friendly3.friendtype = 1 //toggle this to -1 to shut down following
level.friendly3.distance = 128



level.friendly4 thread global/friendly.scr::friendlythink
level.friendly4.friendtype = 1 //toggle this to -1 to shut down following
level.friendly4.distance = 128



level.friendly4 thread global/friendly.scr::friendlythink
level.friendly4.friendtype = 1 //toggle this to -1 to shut down following
level.friendly4.distance = 128



level.friendly5 thread global/friendly.scr::friendlythink
level.friendly5.friendtype = 1 //toggle this to -1 to shut down following
level.friendly5.distance = 128



level.friendly6 thread global/friendly.scr::friendlythink
level.friendly6.friendtype = 1 //toggle this to -1 to shut down following
level.friendly6.distance = 128


end


I typed in values as previous message and still no luck..........any ideas?

eek: eek: eek: eek: eek: eek: eek: eek: eek:

jv_map 11-14-2002 01:36 AM

$mg42_1 thread global/mg42_active.scr::mg42 1024

Is mg42_1 the name of your turret? In that case the name of the spawn locations should be too: mg42_1_gunner_path and mg42_1_spawner_gunner.

carlpenn 11-14-2002 02:46 AM

Ah ha !!!!!!

I never thought of that.........ill correct it tonight and let you know.

Thanks a lot JV.......

Are you going to do a tutorial on SP Scripts?
hope so cuz you seem to know what your talking about.

Big Thanks


All times are GMT -6. The time now is 01:01 AM.

Powered by vBulletin® Version 3.8.12 by ScriptzBin
Copyright ©2000 - 2025, vBulletin Solutions Inc.
© 1998 - 2007 by Rudedog Productions | All trademarks used are properties of their respective owners. All rights reserved.