Level Editing: Scripting

Talk about Severance Blade of Darkness modifications and maps here. No tips or tech support questions please, use the forum above. Note that the game is rated 18 so some content may be unsuitable for younger readers.

Moderators: Ade, prospero

Sir Random
Dragon
Posts: 737
Joined: Thu Nov 15, 2001 12:58 am
Location: Ireland
Contact:

Post by Sir Random »

Hmm, The Mino can't use humanoid anims, so your options are a bit limited. If there's an anim that looks ok, you could play a growl wav file at the same time.

User avatar
Tomash
Dragon
Posts: 247
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Post by Tomash »

May be someone will be interested. Working with Journal I wanted to make a text looks like:

&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp COMBOS
Barabrian got new ability for axes:
&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp AttF + FB
And combo for Big Ice Sword:
&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp AttR + B

But I got:

COMBOS Barbarian got new ability
for axes: AttF + FB And combo for
Big Ice sword: AttR + B

I tried to use "\n" to break the lines, but as I've found the original scripts of Talk.py don't allow to do it.
So, I modified the function of Talk and now I can use "\n" and make my text looks as I want)

Sir Random
Dragon
Posts: 737
Joined: Thu Nov 15, 2001 12:58 am
Location: Ireland
Contact:

Post by Sir Random »

I haven't used Journal, but to display screen text I would use:

######### Text Setup

import GameText
import MenuText

def GetText(s):
return MenuText.GetMenuText(s)

####### Display text:

Code: Select all

def ShowText():
	GameText.ClearText()
	GameText.WriteTextAux(GetText("COMBOS\n\nBarbarian got new ability\nAttF + FB\nAnd combo for Big Ice Sword:\nAttr + B"), 5, 255, 140, 20, 0, 200, 

[])

The numbers 5, 255, 140, 20, 0, 200, = Display time, R, G, B, 0, Screenposition(vertical)

User avatar
Tomash
Dragon
Posts: 247
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Post by Tomash »

Thanks SR:) But TalkSystem and GameText are quite different tools

krehmall
Dragon
Posts: 176
Joined: Wed Apr 11, 2007 11:01 pm
Location: Israel
Contact:

Post by krehmall »

Question about creating buttons from stone blocks.i ve created one

o=Bladex.CreateEntity("Bloque_618","Bloque",88171.3327766,-18481.7000851,291657.998744, Reference.ObjType("Bloque"))
o.Scale=0.8
o.Orientation=(0.707106769085,0.0,0.707106769085,0.0)
darfuncs.SetHint(o,"Trigger")
button=Button.CreateButtonCombination(0,OpenDoor7,"")
button.AddButton("Bloque_618",3,(2,0,3),200,0,0,1)

on last script a lot of numbers what they mean ?8)]

Sir Random
Dragon
Posts: 737
Joined: Thu Nov 15, 2001 12:58 am
Location: Ireland
Contact:

Post by Sir Random »

The function AddButton uses these paramaters:

button_name, time, direction, distance, order, state, correct_state)

Check out \Lib\Button.py for the Button funcs

krehmall
Dragon
Posts: 176
Joined: Wed Apr 11, 2007 11:01 pm
Location: Israel
Contact:

Post by krehmall »

ok thanx[:D],and how do i make button to go back to original position after it did its job?

Sir Random
Dragon
Posts: 737
Joined: Thu Nov 15, 2001 12:58 am
Location: Ireland
Contact:

Post by Sir Random »

In the function "OpenDoor7", add:

Code: Select all

	Bladex.AddScheduledFunc(Bladex.GetTime()+5.0,button.Reset,(1,))

krehmall
Dragon
Posts: 176
Joined: Wed Apr 11, 2007 11:01 pm
Location: Israel
Contact:

Post by krehmall »

Tnx youre great.
Another thing ive made scenes where minotaur roar ,but i dont hear him roar at all i see that camera comes close and do not hear how mino roars how can i make that his roar will be hearble:)?

Sir Random
Dragon
Posts: 737
Joined: Thu Nov 15, 2001 12:58 am
Location: Ireland
Contact:

Post by Sir Random »

<blockquote id="quote"><font size="1" face="Verdana, Arial, Helvetica" id="quote">quote:<hr height="1" noshade id="quote"><i>Originally posted by krehmall</i>

Tnx youre great.
Another thing ive made scenes where minotaur roar ,but i dont hear him roar at all i see that camera comes close and do not hear how mino roars how can i make that his roar will be hearble:)?
<hr height="1" noshade id="quote"></font id="quote"></blockquote id="quote">

If you're making a Cut-Scene with camera movement, you're probably still only hearing stuff from the position of "Player1".

By default, the game hears sounds from the Player's position, but there must be a way to make it hear from the camera's position, I'll investigate...

EDIT\
Ok, try this:

When you start camera stuff, add this:

Bladex.SetListenerPosition(2)


When returning control to "Player1", reset to "1":

Bladex.SetListenerPosition(1)

krehmall
Dragon
Posts: 176
Joined: Wed Apr 11, 2007 11:01 pm
Location: Israel
Contact:

Post by krehmall »

Ive tryed hehe its works[:p]

Bladex.SetListenerPosition(2)


but this one dont need to use after scene its automaticaly returns to player one listening position.

Bladex.SetListenerPosition(1)

krehmall
Dragon
Posts: 176
Joined: Wed Apr 11, 2007 11:01 pm
Location: Israel
Contact:

Post by krehmall »

def dropDMiniStoneB():
o=Bladex.CreateEntity("MiniStone1","Piedra_08",557.640020,-30646.304128,-54069.111998)
o.Static=0
o.Scale=0.819544
o.Orientation=0.707107,0.707107,0.000000,0.000000
o.Impulse(0,-400,0)

def dropDMiniStoneC():
o=Bladex.CreateEntity("MiniStone2","Piedra_01",-10568.862164,-33274.310306,-55490.420629)
o.Static=0
o.Scale=1.000000
o.Orientation=0.707107,0.707107,0.000000,0.000000
o.Impulse(0,-400,-4000)

def dropDMiniStoneD():
o=Bladex.CreateEntity("MiniStone3","Piedra_01",-7698.870797,-31564.444478,-52154.700939)
o.Static=0
o.Scale=1.000000
o.Orientation=0.707107,0.707107,0.000000,0.000000
o.Impulse(0,-400,0)

def dropDMiniStoneE():
o=Bladex.CreateEntity("MiniStone4","Piedra_01",-4070.789465,-31062.063125,-52332.511616)
o.Static=0
o.Scale=1.000000
o.Orientation=0.707107,0.707107,0.000000,0.000000
o.Impulse(0,-400,0)

i found these functions in mine_m5
what does mean ?
o.Impulse(0,-400,0)

Sir Random
Dragon
Posts: 737
Joined: Thu Nov 15, 2001 12:58 am
Location: Ireland
Contact:

Post by Sir Random »

"Impulse" gives an object momentum, as if it has been thrown.

The numbers set the initial direction and speed of the object, then the game's gravity will take over and it will fall to the ground naturally.

charly
Dragon
Posts: 152
Joined: Wed Oct 22, 2008 10:52 am
Location: Hungary

Post by charly »

hi masters

is there a way to change fog (color and opacity) in main game, like in Gorge of orlok or in Tell Halaf, or in Abyss the red fog in the deep

thxx any help guys

User avatar
Tomash
Dragon
Posts: 247
Joined: Sat Oct 25, 2008 11:23 am
Location: Russia
Contact:

Post by Tomash »

If you have the *.mp files of the original maps then you can change any params, compile bw-file and replace original one.
Also it is possible to change the density of atmosphere using rOpenGL video render

Post Reply