Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsCog Forum → Great. The first real cog I make doesn't work
Great. The first real cog I make doesn't work
2000-11-14, 4:10 AM #1
Code:
# Jedi Knight Cog Script
#
# suicidespeedmode.COG
#
# [DWP2] 
#
# This Cog is Not supported by LucasArts Entertainment Co

symbols

thing		player   			local

sound		suimodesnd=suimode.WAV

template	suicideal=suicidemode	local

message		activated
message		deactivated

end                                                                           

# ========================================================================================

code

activated:
          Print("Suicide Speed Mode On");
	   PlaySoundThing(suimodesnd, player, 1.0, -1, -1, 128);
	   SetThingTemplate(player,suicidal);

#................................................................................................#

dectivated:
	    Print("Suicide Speed Mode Off");
	    SetThingTemplate(player,walkplayer);

# ........................................................................................

end

When I activate it it does nothing

------------------
Hard work has a future. Laziness pays off now.
Click here for some fun
Deluxe Weapons Pack- Setting the standard for mediocrity.
2000-11-14, 6:13 AM #2
Probably a typo:

template suicideal=suicidemode local

SetThingTemplate(player,suicidal );

-RayNbow
Too lasy to make a signature... [http://forums.massassi.net/html/wink.gif]


[This message has been edited by RayNbow (edited November 14, 2000).]
-RayNbow
2000-11-14, 6:20 AM #3
I believe you need to put: Return; after your activated and deactivated messages. At least it messes up when I don't.
Jedi Knight Enhanced
Freelance Illustrator
2000-11-14, 6:46 AM #4
It still doesn't work.

------------------
Hard work has a future. Laziness pays off now.
Click here for some fun
Deluxe Weapons Pack- Setting the standard for mediocrity.
2000-11-14, 9:29 AM #5
In addition to the other two "fixes,", add player = GetLocalPlayerThing(); at the beginning of both messages.

-Jipe

[This message has been edited by Jipe (edited November 14, 2000).]
2000-11-14, 10:01 AM #6
It still doesn't work. Here's what I have.
Code:
# Jedi Knight Cog Script
#
# suicidespeedmode.COG
#
# [DWP2] 
#
# This Cog is Not supported by LucasArts Entertainment Co

symbols

thing		player   			local

sound		suimodesnd=suimode.WAV

template	suicidal=suicidemode	local

message		activated
message		deactivated

end                                                                           

# ========================================================================================

code

activated:
	  player = GetLocalPlayerThing(); 
          Print("Suicide Speed Mode On");
	  PlaySoundThing(suimodesnd, player, 1.0, -1, -1, 128);
	  SetThingTemplate(player,suicidal);

	Return;

#................................................................................................#

dectivated:
	    player = GetLocalPlayerThing(); 
	    Print("Suicide Speed Mode Off");
	    SetThingTemplate(player,walkplayer);

	Return;

# ........................................................................................

end


------------------
Hard work has a future. Laziness pays off now.
Click here for some fun
Deluxe Weapons Pack- Setting the standard for mediocrity.
2000-11-14, 12:49 PM #7
What are you trying to do with this cog? Make the player move extremely ludicrously fast?

-Jipe
2000-11-14, 12:51 PM #8
Yes.

------------------
Hard work has a future. Laziness pays off now.
Click here for some fun
Deluxe Weapons Pack- Setting the standard for mediocrity.
2000-11-14, 2:59 PM #9
here:
Code:
symbols
thing player
message startup
message activated
message deactivated
end

code
startup:
player=GetLocalPlayerThing();

activated:
Print("Suicide Mode Enabled");  
SetActorExtraSpeed(player, 6);
Return;

deactivated:
Print("Suicide Mode Disabled");
SetActorExtraSpeed(player, 0);
Return;

end
Capitalization
Commas
Periods
Question Marks
Apostrophes
Confusable Words
Plague Words

↑ Up to the top!