UGX-Mods Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch

Growing Soul Collectors v1.4

HOT
broken avatar :(
Created 8 years ago
by MakeCents
0 Members and 1 Guest are viewing this topic.
16,816 views
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 14 September 2013
Last active: 4 years ago
Posts
1,895
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
BE ORIGINAL
Signature
×
MakeCents's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
BO3 Modtools Alpha
BO3 Modtools Alpha
This user has access to the Black Ops 3 Modtools Alpha
Growing Soul Collectors



Rewards per soul collector can be randomized or collector specific.
 - script_string kvp on the collector will override level settings
 - Can change weapons rewarded or level reward without randomization
Can play a looping animation of collectors - optional, requires uncommenting of a few lines
Includes prefabs to get you started
Only setup for one set of soul collectors and one final reward on a map
Many level vars to edit, including fx and sounds (be sure to add fx to precache and zone if adding more fx)


v 1.1
  - Added level var option to not grow
  - Added level vars to reward on completion the following:
          - gun
          - door
          - buyable ending

v1.2
  - Fixed developer 2 errors

v1.3
  - Added multiple soul collector support with multiple reward support, and individual sizing with script_noteworthy

v1.3.1
  - Find player.cost and replace it with player.score to fix buyable ending

v1.4
  - Added rotating door prefab, updated normal door prefab, fixed endgame trigger, and updated endgame text

Instructions
Code Snippet
Plaintext


MakeCents
v1.4
Updated 12-20-16

Prefabs - in multiple folders (each folder is a different system with different kvps)
  grow_soul_complete - everything you need with gun reward
  grow_soul_complete_door - everything you need with door reward
  grow_soul_complete_ending - everything you need with end game reward
  grow_soul - just one of the soul collectors
  grow_soul_door - just the door reward
  grow_soul_ending - just the end game reward
  grow_soul_with_clip - jus one of the soul collectors with a clip
  grow_soul_door_rotate - door that rotates, script_string controls angle

To make this work you can use one of the complete prefabs, stamp once, and then chose the soul
collector with a clip or without and delete the other.
Next copy the soul collector you kept around where you want them and place the reward where you want it
- end game trigger, door, or gun structs

Then in the script there are notes at the top.

This goes in your main function in your mapname.gsc
grow_soul::init(  );

This goes in your mapname.gsc with the other using's
#using scripts\zm\growing_soulbox;

This goes in your zone file:
scriptparsetree,scripts/zm/growing_soulbox.gsc
fx,zombie/fx_ritual_pap_energy_trail


1.3.1 fixes end game score

1.4 adds more prefabs, rotating door, updates normal door, edits endgame text

To make multiple systems work, do the same you did for the first system, but select from another folder.
In these other folders each item has a different kvp.
You can add more if you like, I provided 3 systems.
Last Edit: December 20, 2016, 03:50:32 pm by MakeCents
broken avatar :(
×
broken avatar :(
Location: gbEurasian Plate, The Crust, Earth, The Solar System, The Milky Way
Date Registered: 4 November 2014
Last active: 2 months ago
Posts
181
Respect
Forum Rank
Pack-a-Puncher
Primary Group
Donator ♥
My Groups
More
My Contact & Social Links
More
Personal Quote
Mod Tools Tutorial Creator YouTube.com/IceGrenade
Signature
YouTuber Call of Duty Mod Tools Tutorial Creator on YouTube.com/IceGrenade
×
IceGrenade's Groups
Donator ♥ Benevolent Soul who has our eternal gratitude and exclusive access to betas and the donator section of the forum.
A tutorial I made on adding these soul chest to your map. :D

broken avatar :(
×
broken avatar :(
Location: usU.S.A! U.S.A!
Date Registered: 10 June 2015
Last active: 3 years ago
Posts
86
Respect
Forum Rank
Rotting Walker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Abnormal202
Signature
-Abnormal202
×
qwerty195's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Hello, I was editing your script for the soul collectors and I ran into some problems that only you, the creator, might know how to fix. What I wanted to do was make it so that every time a soul collector was finished (in my case they are 4 different colored rocks) the rock of that soul collector would move to its pedestal, as well as the light that made them look glowing. This is currently my script:
Code Snippet
Plaintext
#using scripts\shared\flag_shared;
#using scripts\zm\_zm_perks;
#using scripts\shared\array_shared;
#using scripts\zm\_zm_audio;
#using scripts\zm\_zm_powerups;
#using scripts\shared\util_shared;
#using scripts\codescripts\struct;
#using scripts\shared\laststand_shared;
#using scripts\zm\_zm_weapons;

/*
#####################
by: M.A.K.E C E N T S
#####################
Script: v1.1               //MAKE SURE ALL ENTITIES ARE PRESENT IN RADIANT!//

scriptparsetree,scripts/zm/growing_soulbox.gsc
fx,zombie/fx_ritual_pap_energy_trail
//fx,any other fx you add
//the following is optional for anims
xanim,youranimhere//your anim here
rawfile,animtrees/youranimtreename.atr//your animtree here


###############################################################################
*/

// #precache( "xanim", "youranimhere");//your anim here

#precache( "fx", "zombie/fx_powerup_on_green_zmb" );
#precache( "fx", "zombie/fx_ritual_pap_energy_trail" );
#precache( "fx", "zombie/fx_powerup_off_green_zmb" );
#namespace grow_soul;

//#using_animtree( "youranimtreename" );//your animtree here

function init()
{
level.post_blue_light = GetEnt( "post_blue_light", "targetname");
level.post_green_light = GetEnt( "post_green_light", "targetname");
level.post_yellow_light = GetEnt( "post_yellow_light", "targetname");
level.post_red_light = GetEnt( "post_red_light", "targetname");
level.post_blue_light Hide();
level.post_green_light Hide();
level.post_yellow_light Hide();
level.post_red_light Hide();
//vars for growing and reward
level.grow_soul_grow = true;//true to grow, and false to not grow
level.grow_soul_final_reward = "door";//options: gun, ending, door
level.grow_soul_start_scale = 0.75;//starting scale of model
level.grow_soul_anim = undefined;//set to true to play an anim, define down in PlayMyAnim function, and uncomment anim related lines
level.grow_soulallreward = "raygun_mark3";
level.grow_soul_explode = true;
level.grow_soulfx_limit = 5;
level.grow_soul_growth = 0.05;//growth per zombie
level.grow_soul_size = 1;//how big you want it to get scale wise
level.grow_souldistance = 300;//how far away they can be
level.growspeed = .015;//how fast to grow
level.grow_soul_scaler = .001;//how much it grows during growspeed
level.soul_speed_divider = 200;//the higher the number the faster it travels
level.grow_soul_reward = "random_weapon";//can also be other things, random_weapon, tesla, minigun, and so on
level.grow_soul_rand_rewards = array("random_weapon");//can add other powerups also
level.grow_soul_rand_weapons = array( "ar_damage", "lmg_cqb", "shotgun_pump", "smg_versatile" );//added for the weapons to randomly reward
level.grow_soul_randomize = true;//make false or undefined to not randomize rewards
//vars for fx and sounds
level.grow_soulsoulfx = "zombie/fx_ritual_pap_energy_trail";//fx for the soul to travel
level.grow_soulenterfx = "zombie/fx_powerup_grab_red_zmb";//fx for when the soul gets to the box
level.grow_soulexplode = "zombie/fx_powerup_off_green_zmb";//fx for exploding
level.grow_soulentersound = "evt_nuked";//play sound for soul to box
level.grow_soulrewardsound = "zmb_couch_slam";//sound to play when box is
level.grow_soul_idlefx = undefined;//"zombie/fx_powerup_on_green_zmb";// fx for model while idle

//start it up
grow_souls = GetEntArray("grow_soul","targetname");
array::thread_all(grow_souls, &MonitorGrowSouls);
level.grow_souls = grow_souls.size;
thread WatchZombies();
thread SetUpReward();
}

function SetUpReward()
{
if(isdefined(level.grow_soul_final_reward))
{
if(level.grow_soul_final_reward=="door")
{
if(level.grow_soul_final_reward=="door")
{
trigs = GetEntArray("grow_soul_door","targetname");
array::thread_all(trigs, &GrowSoulDoor);
}
}
else if(level.grow_soul_final_reward=="ending")
{
trig = GetEnt("grow_soul_ending","targetname");
//trig Hide();
trig thread GrowSoulEnding();
}
}
}

function GrowSoulEnding()
{
self SetCursorHint("HINT_NOICON");
self SetHintString("You may not leave until you finish collecting my souls.");
level waittill("allgrowsouls");
IPrintLnBold("You may now escape, if you can.");
self Show();
cost = 50000;
if(isdefined(self.zombie_cost))
{
cost = self.zombie_cost;
}
self SetCursorHint("HINT_NOICON");
self SetHintString("Press & hold [{+activate}] for buyable ending [Cost: " + cost + "].");
while(1)
{
self waittill("trigger", player);
if(player.cost+5<cost)
{
player PlayLocalSound("zmb_no_cha_ching");
continue;
}
player PlayLocalSound("zmb_cha_ching");
IPrintLnBold("Congratulations! You escaped in " + level.round_number + " rounds.");
level notify("end_game");
}
}

function GrowSoulDoor()
{
self SetCursorHint("HINT_NOICON");
self SetHintString("It is too soon. Collect the Four Stones First");
if(isdefined(self.script_flag) && self.script_flag!="")
{
flag::init(self.script_flag);
}
self thread HandlePaths(false);
level waittill("allgrowsouls");
IPrintLnBold("You Sense an Awakening");
self SetHintString("");
self thread HandlePaths();
if(isdefined(self.script_flag))
{
flag::set(self.script_flag);
}
wait(1);
self delete();
}

function HandlePaths(connect = true)
{
if(isdefined(self.target))
{
doors = GetEntArray(self.target,"targetname");
foreach(door in doors)
{
if(!isdefined(door.model))
{
if(connect)
{
door NotSolid();
door ConnectPaths();
}
else
{
door DisconnectPaths();
}
}
if(connect)
{
if(isdefined(door.script_noteworthy) && door.script_noteworthy=="clip")
{
door Delete();
}
else
{
if(isdefined(door.script_vector))
{
vector = VectorScale( door.script_vector, 1 );
IPrintLnBold("move door");
IPrintLnBold(self.origin + vector);
door MoveTo(self.origin + vector,1);
}
if(isdefined(door.script_sound))
{
door PlaySound(door.script_sound);
}
}
}
if(isdefined(door))
{
door thread HandlePaths(connect);
}
}
}
}

function MonitorGrowSouls()
{
self endon("death");
if(isdefined(level.grow_soul_anim) && level.grow_soul_anim)
{
self thread PlayMyAnim();
}
if(isdefined(self) && isdefined(level.grow_soul_idlefx))
{
PlayFXOnTag(level.grow_soul_idlefx,self,"tag_origin");
}
if(isdefined(self))
{
if(isdefined(level.grow_soul_start_scale))
{
self.scale = level.grow_soul_start_scale;
}
else
{
self.scale = 1;
}
}
while(isdefined(self) && self.scale<level.grow_soul_size)
{
wait(.05);
}
if(isdefined(self) && isdefined(level.grow_soul_explode) && level.grow_soul_explode)
{
self thread BlowUpGrowSoul();
}
}

function PlayMyAnim()
{
// self UseAnimTree(#animtree);
// self AnimScripted("done",self.origin,self.angles,%youranimhere);
}

function BlowUpGrowSoul()
{
self endon("death");
level.grow_souls--;
if(level.grow_souls<=0)
{
thread RewardForAllGrowSouls();
}
if(isdefined(self) && isdefined(level.grow_soul_idlefx))
{
PlayFX(level.grow_soulexplode,self.origin);
}
// Playfx( level._effect["lightning_dog_spawn"], self.origin );
if(isdefined(self))
{
self thread lets_get_moving();
self thread RewardPlayers();
}
}

function lets_get_moving()
{
blue   = GetEnt( "blue_rock", "script_noteworthy" );
green  = GetEnt( "green_rock", "script_noteworthy" );
yellow = GetEnt( "yellow_rock", "script_noteworthy" );
red    = GetEnt( "red_rock", "script_noteworthy" );
blue_light   = GetEnt( "blue_light", "targetname" );
green_light  = GetEnt( "green_light", "targetname" );
yellow_light = GetEnt( "yellow_light", "targetname" );
red_light    = GetEnt( "red_light", "targetname" );
pre_blue_origin = GetEnt( "pre_blue_origin", "targetname");
pre_green_origin = GetEnt( "pre_green_origin", "targetname");
pre_yellow_origin = GetEnt( "pre_yellow_origin", "targetname");
pre_red_origin = GetEnt( "pre_red_origin", "targetname");
blue_origin = GetEnt( "blue_origin", "targetname");
green_origin = GetEnt( "green_origin", "targetname");
yellow_origin = GetEnt( "yellow_origin", "targetname");
red_origin = GetEnt( "red_origin", "targetname");

if(level.closest == blue)
{
blue_light Delete();
blue MoveZ( -50, 3);
blue MoveTo( pre_blue_origin, 0.05);
blue MoveTo( blue_origin, 5);
level.post_blue_light show();
}
else if(level.closest == green)
{
green_light Delete();
green MoveZ( -50, 3);
green MoveTo( pre_green_origin, 0.05);
green MoveTo( green_origin, 5);
level.post_green_light show();
}
else if(level.closest == yellow)
{
yellow_light Delete();
yellow MoveZ( -50, 3);
yellow MoveTo( pre_yellow_origin, 0.05);
yellow MoveTo( yellow_origin, 5);
level.post_yellow_light show();
}
else
{
red_light Delete();
red MoveZ( -50, 3);
red MoveTo( pre_red_origin, 0.05);
red MoveTo( red_origin, 5);
level.post_red_light show();
}

}
//modified section down to end of SpinMe for gun give reward, set to ray gun
function RewardPlayers()
{
self endon("death");
if(isdefined(self))
{
self PlaySound(level.grow_soulrewardsound);
}
//script_script kvp on model will override level settings
if(isdefined(self.script_string))
{
if(self.script_string == "random_weapon")
{
thread RewardGun(self.origin+(0,0,50), array::randomize(level.grow_soul_rand_weapons)[0]);
}
else
{
zm_powerups::specific_powerup_drop( self.script_string, self.origin);
}
}
else
{
if(isdefined(level.grow_soul_randomize) && level.grow_soul_randomize)
{
reward = array::randomize(level.grow_soul_rand_rewards)[0];
if(!isdefined(level.grow_soullastreward))
{
if(reward=="random_weapon")
{
thread RewardGun(self.origin+(0,0,50), array::randomize(level.grow_soul_rand_weapons)[0]);
}
else
{
zm_powerups::specific_powerup_drop( reward, self.origin);
}
level.grow_soullastreward = reward;
}
else
{
while(reward==level.grow_soullastreward || (reward == "minigun" && level.round_number<5))
{
reward = array::randomize(level.grow_soul_rand_rewards)[0];
}
if(reward=="random_weapon")
{
thread RewardGun(self.origin+(0,0,50), array::randomize(level.grow_soul_rand_weapons)[0]);
}
else
{
zm_powerups::specific_powerup_drop( reward, self.origin);
}
level.grow_soullastreward = reward;
}
}
else
{
if(level.grow_soul_reward=="random_weapon")
{
thread RewardGun(self.origin+(0,0,50), array::randomize(level.grow_soul_rand_weapons)[0]);
}
else
{
zm_powerups::specific_powerup_drop( level.grow_soul_reward, self.origin);
}
}
}
if(isdefined(self.target))
{
clips = GetEntArray(self.target,"targetname");
foreach(clip in clips)
{
clip ConnectPaths();
clip Delete();
}
}
self delete();
}

function SetGunHint(text, trig)
{
if(isdefined(self.grow_soul_hud))
{
return;
}
self.grow_soul_hud = NewClientHudElem( self );
self.grow_soul_hud.horzAlign = "center";
self.grow_soul_hud.vertAlign = "middle";
self.grow_soul_hud.alignX = "center";
self.grow_soul_hud.alignY = "middle";
self.grow_soul_hud.foreground = 1;
self.grow_soul_hud.fontscale = 1;
self.grow_soul_hud.alpha = 1;
self.grow_soul_hud.color = ( 0.44, .74, .94 );
self.grow_soul_hud SetText(text);
while(isdefined(trig) && self IsTouching(trig))
{
wait(.05);
}
self.grow_soul_hud SetText("");
self.grow_soul_hud Destroy();
self.grow_soul_hud = undefined;
}

function RewardForAllGrowSouls()
{
level notify("allgrowsouls");
if(!isdefined(level.grow_soul_final_reward) || level.grow_soul_final_reward == "gun")
{
IPrintLnBold("Soul collection complete! Find & Claim your reward!");
structs = struct::get_array("grow_soul_reward", "targetname");
players = GetPlayers();
for( i=0;i<players.size;i++ )
{
thread RewardGun(structs[i].origin);
}
}
}

function RewardGun(pos, weapon = level.grow_soulallreward)
{
gun = spawn("script_model", pos);
playsoundatposition("zmb_spawn_powerup", pos);

gun SetModel(GetWeaponWorldModel(GetWeapon(weapon)));
PlayFXOnTag(level._effect["powerup_grabbed_solo"], gun, "tag_orign");
trig = spawn("trigger_radius", gun.origin, 0, 20, 50);
gun thread SpinMe();
gun thread GiveMe(weapon, trig);
if(weapon != level.grow_soulallreward)
{
gun thread LifeTime(trig);
}
}

function LifeTime(trig)
{
self endon("death");
wait(120);//wait 2 minutes then delete
if(isdefined(self))
{
self notify("rewardgun_delete");
}
if(isdefined(trig))
{
trig delete();
}
if(isdefined(self))
{
self delete();
}
}

function GiveMe(weapon = level.grow_soulallreward, trig)
{
self endon("rewardgun_delete");
while(1)
{
trig waittill("trigger", player);
player thread SetGunHint("Press & hold [{+activate}] to take weapon.", trig);
if(player HasWeapon(getweapon("minigun")))
{
continue;
}
if(!(player UseButtonPressed()))
{
continue;
}
if(player HasWeapon(getweapon(weapon)))
{
continue;
}
if(player laststand::player_is_in_laststand())
{
continue;
}
trig delete();
self delete();
player zm_weapons::weapon_give(getweapon(weapon));
player SwitchToWeapon(getweapon(weapon));
break;
wait(.1);
}
}

function SpinMe()
{
self endon("rewardgun_delete");
self endon("death");
if(isdefined(self))
{
PlayFXOnTag(level.grow_soul_idlefx,self,"tag_origin");
}
while(isdefined(self))
{
if(isdefined(self))
{
self rotateyaw(360,2);
}
wait(1.9);
}
}

function WatchZombies()
{
level endon("allgrowsouls");
while(1)
{
zombies = GetAiSpeciesArray( "axis", "all" );
for(i=0;i<zombies.size;i++)
{
if(isdefined(zombies[i].grow_soul))
{
continue;
}
else
{
zombies[i] thread WatchMe();
}
}
wait(.05);
}
}

function WatchMe()
{
level endon("allgrowsouls");
if(isdefined(self))
{
self.grow_soul = true;
}
else
{
return;
}
self waittill("death");
// start = self GetTagOrigin( "J_SpineLower" );//different for dog
start = self.origin+(0,0,60);
if(!isdefined(start))
{
return;
}
grow_souls = GetEntArray("grow_soul","targetname");
level.closest = level.grow_souldistance;
cgs = undefined;
foreach(gs in grow_souls)
{
if(Distance(start,gs.origin)<level.closest && BulletTracePassed( start, gs.origin+(0,0,50), false, self ))
{
level.closest = Distance(start,gs.origin);
cgs = gs;
}
}
if(!isdefined(cgs) || !isdefined(cgs.origin))
{
return;
}
cgs thread SendSoul(start);
}

function SendSoul(start)
{
if(isdefined(self))
{
end = self.origin;
}
if(!isdefined(start) || !isdefined(end))
{
return;
}
if(isdefined(self))
{
self PlaySound(level.grow_soulentersound);
}
if(isdefined(self))
{
if(isdefined(level.grow_soul_grow) && level.grow_soul_grow)
{
self thread Grow();
}
else
{
self.scale+=level.grow_soul_growth;
}
}
if(!isdefined(level.grow_soulfx_count))
{
level.grow_soulfx_count = 0;
}
if(level.grow_soulfx_count < level.grow_soulfx_limit)
{
level.grow_soulfx_count++;
fxOrg = util::spawn_model( "tag_origin", start );
fx = PlayFxOnTag( level.grow_soulsoulfx, fxOrg, "tag_origin" );
time = Distance(start,end)/level.soul_speed_divider;
fxOrg MoveTo(end+(0,0,50),time);
fxOrg waittill(time - .05);
fxOrg moveto(end, .5);
fxOrg waittill("movedone");
if(isdefined(self))
{
self PlaySound(level.grow_soulentersound);
}
PlayFX(level.grow_soulenterfx,end);
fxOrg delete();
level.grow_soulfx_count--;
}
else
{
if(isdefined(self))
{
self PlaySound(level.grow_soulentersound);
}
PlayFX(level.grow_soulenterfx,end);
}
}

function Grow()
{
level endon("allgrowsouls");
self endon("death");
scale = 0;
while(isdefined(self) && scale<level.grow_soul_growth)
{
wait(level.growspeed);
if(isdefined(self))
{
self SetScale(self.scale+level.grow_soul_scaler);
}
if(isdefined(self))
{
self.scale = self.scale+level.grow_soul_scaler;
}
scale+=level.grow_soul_scaler;
if(isdefined(self) && self.scale>=level.grow_soul_size)
{
break;
}
}
}


With most of the changes being in:
Code Snippet
Plaintext
function lets_get_moving()
{
blue   = GetEnt( "blue_rock", "script_noteworthy" );
green  = GetEnt( "green_rock", "script_noteworthy" );
yellow = GetEnt( "yellow_rock", "script_noteworthy" );
red    = GetEnt( "red_rock", "script_noteworthy" );
blue_light   = GetEnt( "blue_light", "targetname" );
green_light  = GetEnt( "green_light", "targetname" );
yellow_light = GetEnt( "yellow_light", "targetname" );
red_light    = GetEnt( "red_light", "targetname" );
pre_blue_origin = GetEnt( "pre_blue_origin", "targetname");
pre_green_origin = GetEnt( "pre_green_origin", "targetname");
pre_yellow_origin = GetEnt( "pre_yellow_origin", "targetname");
pre_red_origin = GetEnt( "pre_red_origin", "targetname");
blue_origin = GetEnt( "blue_origin", "targetname");
green_origin = GetEnt( "green_origin", "targetname");
yellow_origin = GetEnt( "yellow_origin", "targetname");
red_origin = GetEnt( "red_origin", "targetname");

if(level.closest == blue)
{
blue_light Delete();
blue MoveZ( -50, 3);
blue MoveTo( pre_blue_origin, 0.05);
blue MoveTo( blue_origin, 5);
level.post_blue_light show();
}
else if(level.closest == green)
{
green_light Delete();
green MoveZ( -50, 3);
green MoveTo( pre_green_origin, 0.05);
green MoveTo( green_origin, 5);
level.post_green_light show();
}
else if(level.closest == yellow)
{
yellow_light Delete();
yellow MoveZ( -50, 3);
yellow MoveTo( pre_yellow_origin, 0.05);
yellow MoveTo( yellow_origin, 5);
level.post_yellow_light show();
}
else
{
red_light Delete();
red MoveZ( -50, 3);
red MoveTo( pre_red_origin, 0.05);
red MoveTo( red_origin, 5);
level.post_red_light show();
}

}
I think the reason it doesn't work may be due to level.closest not actually being the closest soul collector. I looked through your script and I was fairly confused, being new to scripting and all, and I couldn't find a variable defined for the single soul collector the player has completed. I appreciate any help.
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 14 September 2013
Last active: 4 years ago
Posts
1,895
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
BE ORIGINAL
×
MakeCents's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
BO3 Modtools Alpha
BO3 Modtools Alpha
This user has access to the Black Ops 3 Modtools Alpha
Well your working off 1.1, some additions have been made since. such as multiple soul box systems. I'm up to 1.4 now.

It sounds like you could achieve this by just spawning the rock back and moving it. You could also change level.grow_soul_explode to false, and then in the MonitorGrowSouls function, add an else like this:

Code Snippet
Plaintext
//up top change level.grow_soul_explode = true; to level.grow_soul_explode = false;
        if(isdefined(self) && isdefined(level.grow_soul_explode) && level.grow_soul_explode)
{
self thread BlowUpGrowSoul(system);
}
else
{
if(isdefined(self.target))//stamp prefab and select model and then struct, that is where you want it to move to
{
struct = struct::get(self.target, "targetname");
if(isdefined(struct))
{
self MoveTo(struct.origin,2);
}
}
}

You could decide where to move the rock by distance or maybe even setting up a target of a struct, getting the struct, and moving it do that origin.

If you have an level.grow_soul_idlefx playing on the model, you can modify the
Code Snippet
Plaintext
PlayFX(level.grow_soulexplode,self.origin);
to:
Code Snippet
Plaintext
PlayFXOnTag(level.grow_soulexplode,self, "tag_origin");
and the fx will stay with the model when it moves then, if the fx is setup right
Last Edit: December 22, 2016, 07:27:02 pm by MakeCents
broken avatar :(
×
broken avatar :(
Location: usU.S.A! U.S.A!
Date Registered: 10 June 2015
Last active: 3 years ago
Posts
86
Respect
Forum Rank
Rotting Walker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Abnormal202
×
qwerty195's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
I appreciate your quick response, its very helpful, but I am a little confused. I inserted the script in MonitorGrowSouls and set level.grow_soul_explode to false, but I am a little confused where to put the struct and what KVPs it should have. Also, I don't have an FX for the rocks, but I do have a different colored light for each one of them that I would like to move with them, or at least delete themselves and then reappear at the end. I am know somewhat how to script but as you could see before, not very well. I'm just a little confused whats going on in the script right now, and if could explain it that would be awesome, and would help me become a better scripter in the long run.
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 14 September 2013
Last active: 4 years ago
Posts
1,895
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
BE ORIGINAL
×
MakeCents's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
BO3 Modtools Alpha
BO3 Modtools Alpha
This user has access to the Black Ops 3 Modtools Alpha
What I proposed, you would make the struct the target of the model. Select the prefab, stamp it, if necessary, then select the rock, then select the struct and press w. Then move the struct where you want the rock to end up. You can select one and then the other, enter the origin kvp and hit enter to line things up. Depending which you select first, depends which will go to the others origin. That's just for assignment purposes. Move the rock back once you have the struct aligned.

As far as the light. I've seen gsc scripting options on lights, but hasn't tried it yet. If you can get a light by target name, I would try linking it to the rock, our just moving it yourself, maybe to the struct + 0 0 30, or whatever. Or you can put the light in an fx, and do the play fx on tag thing I said.

I have a tut on script too radiant relationship on my YouTube, if you haven't seen it, check it out. I plan on adding two more parts before the end of next week.
Last Edit: December 22, 2016, 09:53:47 pm by MakeCents
broken avatar :(
×
broken avatar :(
Location: usU.S.A! U.S.A!
Date Registered: 10 June 2015
Last active: 3 years ago
Posts
86
Respect
Forum Rank
Rotting Walker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Abnormal202
×
qwerty195's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
So I put in the script, set the level.grow_soul_explode to false, and created a struct where I want the rock to end up. I selected the rock (which has the targetname "grow_souls" like it should, and is a script model) and then selected the struct and pressed W, created a line with an arrow pointing from the rock to the struct. The problem is, when I go in game the rocks are all just where they end up, at the script struct, from the beginning, And you can't collect any souls. The magical door doesn't even open up.
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 14 September 2013
Last active: 4 years ago
Posts
1,895
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
BE ORIGINAL
×
MakeCents's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
BO3 Modtools Alpha
BO3 Modtools Alpha
This user has access to the Black Ops 3 Modtools Alpha
So I put in the script, set the level.grow_soul_explode to false, and created a struct where I want the rock to end up. I selected the rock (which has the targetname "grow_souls" like it should, and is a script model) and then selected the struct and pressed W, created a line with an arrow pointing from the rock to the struct. The problem is, when I go in game the rocks are all just where they end up, at the script struct, from the beginning, And you can't collect any souls. The magical door doesn't even open up.

Well, I'm not sure why its doing that. This here:
Code Snippet
Plaintext
	while(isdefined(self) && self.scale<finalscale)
{
wait(.05);
}

Should not let it get to that part of the code until self.scale > finalscale.
broken avatar :(
×
broken avatar :(
Location: usU.S.A! U.S.A!
Date Registered: 10 June 2015
Last active: 3 years ago
Posts
86
Respect
Forum Rank
Rotting Walker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Abnormal202
×
qwerty195's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Alright I got the collectors to collect souls again. They collect souls, then move to the correct pedestal. Everything works except for the door. It doesn't open and the hintstring doesn't change.
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 14 September 2013
Last active: 4 years ago
Posts
1,895
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
BE ORIGINAL
×
MakeCents's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
BO3 Modtools Alpha
BO3 Modtools Alpha
This user has access to the Black Ops 3 Modtools Alpha
Alright I got the collectors to collect souls again. They collect souls, then move to the correct pedestal. Everything works except for the door. It doesn't open and the hintstring doesn't change.

Well, it sounds like either that ee is not complete, or maybe there is a string typo or something like that. You can add prints to see where it is getting hung up at.
broken avatar :(
×
broken avatar :(
Location: usU.S.A! U.S.A!
Date Registered: 10 June 2015
Last active: 3 years ago
Posts
86
Respect
Forum Rank
Rotting Walker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Abnormal202
×
qwerty195's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Well, it sounds like either that ee is not complete, or maybe there is a string typo or something like that. You can add prints to see where it is getting hung up at.
What do you mean add prints?
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 14 September 2013
Last active: 4 years ago
Posts
1,895
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
BE ORIGINAL
×
MakeCents's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
BO3 Modtools Alpha
BO3 Modtools Alpha
This user has access to the Black Ops 3 Modtools Alpha
What do you mean add prints?

Like where the rewards are given and where it checks if the ee is done. Add things like:

Code Snippet
Plaintext
iprintlnbold("this is happening");

then you can see where the code is running, and maybe why its not rewarding or if it is, but it may be a kvp issue in radiant instead.
Last Edit: December 30, 2016, 05:46:45 pm by MakeCents
broken avatar :(
×
broken avatar :(
Location: usU.S.A! U.S.A!
Date Registered: 10 June 2015
Last active: 3 years ago
Posts
86
Respect
Forum Rank
Rotting Walker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Abnormal202
×
qwerty195's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
You know, I've been wondering how you call the script using:
Code Snippet
Plaintext
grow_soul::init(  );
despite the name of the file being growing_soulbox.gsc.

I'm trying to add a second growing soulbox script (yes it has to be in its own .gsc to work) but I don't know how to reference it. Using:
Code Snippet
Plaintext
growing_soulbox_2::init(  );
does not work.
broken avatar :(
×
broken avatar :(
Location: us
Date Registered: 14 September 2013
Last active: 4 years ago
Posts
1,895
Respect
Forum Rank
Zombie Destroyer
Primary Group
Community Scripter
My Groups
More
My Contact & Social Links
More
Personal Quote
BE ORIGINAL
×
MakeCents's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
Community Scripter Has shown effort and knowledge in the area of scripting while being a part of the UGX-Mods community.
BO3 Modtools Alpha
BO3 Modtools Alpha
This user has access to the Black Ops 3 Modtools Alpha
You know, I've been wondering how you call the script using:
Code Snippet
Plaintext
grow_soul::init(  );
despite the name of the file being growing_soulbox.gsc.

I'm trying to add a second growing soulbox script (yes it has to be in its own .gsc to work) but I don't know how to reference it. Using:
Code Snippet
Plaintext
growing_soulbox_2::init(  );
does not work.

My system supports multiple soul box systems already, Just by adding the prefabs, and the line of script. But the reason I call it with that is because of name spaces. If a script declares a name space, you use that instead of the scripts name.
broken avatar :(
×
broken avatar :(
Location: usU.S.A! U.S.A!
Date Registered: 10 June 2015
Last active: 3 years ago
Posts
86
Respect
Forum Rank
Rotting Walker
Primary Group
Community Mapper
My Groups
More
My Contact & Social Links
More
Personal Quote
Abnormal202
×
qwerty195's Groups
Community Mapper Has released one or more maps to the UGX-Mods community which have been added to the UGX Map Manager.
ah , I understand now. I hadn't seen namespaces used yet. I need to have multiple .gsc's though because the level vars have to be different for the other set (as well as some extra script things I need to add in).

 
Loading ...