Page 3 of 3

Re: Build and Shoot News Letter #3

Posted: Fri Mar 15, 2013 6:30 pm
by VladVP
Strozzi wrote:
Blue_Happy1
EEK! A blue sympatist! Kill it with fire!!! Green_Surprised2 Green_Septic Green_Spade Green_Rifle

Re: Build and Shoot News Letter #3

Posted: Fri Mar 15, 2013 9:04 pm
by Buffet_of_Lies
Just for the record, here is the latest release of BR's Blood Shot blood splatter server script.
Code: Select all
from commands import *
from pyspades.world import *
from pyspades.constants import *
from pyspades.server import *
from pyspades.common import *

MAX_BLOOD = 250
BLOOD_COLOR = (175, 20, 20)

def apply_script(protocol, connection, config):
        class BloodConnection(connection):
                def on_hit(hitter, hit_amount, hittee, type, grenade):
                        #hitter.protocol.send_chat("on hit: " + hitter.name + ", " + str(hit_amount) + ", " + hittee.name + ", " + str(type) + ", " + str(grenade))
                        result = connection.on_hit(hitter, hit_amount, hittee, type, grenade)
                        if result == False or result <= 0 or MAX_BLOOD <= 0:
                                return result
                        if result is not None:
                                hit_amount = result
                        #hitter.protocol.send_chat("hit not cancelled, new damage " + str(hit_amount))
                        pos = hittee.world_object.position
                        pos2 = hitter.world_object.position
                        for i in range(min(10, int(hit_amount / 10) + 1)):
                                #hitter.protocol.send_chat("trace")
                                dir = pos - pos2
                                dir.normalize()
                                dir.x = dir.x + random.random() * 0.4 - 0.2
                                dir.y = dir.y + random.random() * 0.4 - 0.2
                                dir.z = dir.z + random.random() - 0.2
                                dir.normalize()
                                c = Character(hittee.world_object.world, pos, dir)
                                loc = c.cast_ray()
                                if loc:
                                #if cast_ray(hittee.world_object.world.map.map, pos.x, pos.y, pos.z, dir.x, dir.y, dir.z, 8, x, y, z):
                                        x, y, z = loc
                                        #hitter.protocol.send_chat(str(x) + ", " + str(y) + ", " + str(z) + ", ray found")
                                        if x < 0 or y < 0 or z < 0 or x >= 512 or y >= 512 or z >= 63:
                                                continue
                                        #hitter.protocol.send_chat("painting")
                                        if hitter.protocol.map.get_color(x, y, z) == BLOOD_COLOR:
                                                continue
                                        if hitter.protocol.index >= MAX_BLOOD:
                                                solid = hitter.protocol.map.get_point(hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][0], hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][1], hit
ter.protocol.blood[hitter.protocol.index % MAX_BLOOD][2])
                                                if solid and hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][3] is not None:
                                                        hitter.protocol.map.set_point(hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][0], hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][1], hit
ter.protocol.blood[hitter.protocol.index % MAX_BLOOD][2], hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][3])
                                                        set_color.value = make_color(*hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][3])
                                                        set_color.player_id = 32
                                                        hitter.protocol.send_contained(set_color)
                                                        block_action.x = hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][0]
                                                        block_action.y = hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][1]
                                                        block_action.z = hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD][2]
                                                        block_action.player_id = 32
                                                        block_action.value = DESTROY_BLOCK
                                                        hitter.protocol.send_contained(block_action, save = True)
                                                        block_action.value = BUILD_BLOCK
                                                        hitter.protocol.send_contained(block_action, save = True)
                                        hitter.protocol.blood[hitter.protocol.index % MAX_BLOOD] = (x, y, z, hitter.protocol.map.get_color(x, y, z))
                                        hitter.protocol.index = hitter.protocol.index + 1
                                        #hitter.protocol.send_chat(str(hitter.protocol.index))
                                        hitter.protocol.map.set_point(x, y, z, BLOOD_COLOR)
                                        set_color.value = make_color(*BLOOD_COLOR)
                                        set_color.player_id = 32
                                        hitter.protocol.send_contained(set_color)
                                        block_action.x = x
                                        block_action.y = y
                                        block_action.z = z
                                        block_action.player_id = 32
                                        block_action.value = DESTROY_BLOCK
                                        hitter.protocol.send_contained(block_action, save = True)
                                        block_action.value = BUILD_BLOCK
                                        hitter.protocol.send_contained(block_action, save = True)
                        #hitter.protocol.send_chat("end")
                        return hit_amount
        class BloodProtocol(protocol):
                blood = {}
                index = 0
        return BloodProtocol, BloodConnection
Sadly, there is a 'scattered block' glitch though. Still really cool. Maybe someone can figure out why it leaves blocks floating in the air after awhile?

Re: Build and Shoot News Letter #3

Posted: Sat Mar 16, 2013 5:14 pm
by Revolet
I have a question about the launcher. Will the same security(votekick process, moderation) for 0.75 and 0.76 be added to the version that didn't have moderation at all?

Re: Build and Shoot News Letter #3

Posted: Mon Mar 18, 2013 6:55 pm
by StackOverflow
Revolet wrote:
I have a question about the launcher. Will the same security(votekick process, moderation) for 0.75 and 0.76 be added to the version that didn't have moderation at all?
There will be limited support for older versions. For the most part it will come down to the individuals hosting the server(s) in regards to stuff like moderation.

Re: Build and Shoot News Letter #3

Posted: Tue Mar 19, 2013 2:41 pm
by FaultCheck
@Danhezee - I just wanted to make sure you're not waiting on me, I'm pretty sure I saw a post by you after the contest ended, with a list of badges, but not sure where it went, and not sure if that was the final official. Let me know, and I can get them finished up and over to you.

Re: Build and Shoot News Letter #3

Posted: Fri Mar 22, 2013 12:36 am
by RyanK
Launcher looks awesome! Now I'm hoping for it to happen!

Re: Build and Shoot News Letter #3

Posted: Fri Mar 22, 2013 4:22 am
by Handles
It will happen. It's just a matter of when. Green_Wink1

Re: Build and Shoot News Letter #3

Posted: Sat Mar 23, 2013 1:27 am
by RyanK
That's good.Can't wait for it! Hopefully it'll be soon.

Re: Build and Shoot News Letter #3

Posted: Thu Sep 19, 2013 10:28 am
by iqbalfiona
I love the epic promotion video. Great job!

Re: Build and Shoot News Letter #3

Posted: Tue Nov 25, 2014 11:37 am
by ultatv
very nice promo this video