SendNetMsg Error
Posted: Thu Oct 08, 2015 10:57 pm
Hey, currently trying to make a Hero Wars server. Am trying to keep console clean for debugging and managing database related issues. Come across this whilst trying to perform a lot of things at the same time.
Running the code below to cause this issue.
Sorry the coding is quite messy, and only seems to fire when the detection statement is satisfied.
Also, everything works fine. Just get the error for some reason. :D
Code: Select all
SendNetMsg <Insert IP Address>: stream[netchan_t::unreliabledata] buffer overflow (maxsize = 4000)!
Running the code below to cause this issue.
Syntax: Select all
class I8(Item):
name = 'Bouncy Bullets'
description = 'When bullets impact a wall they will ricochet, changing direction and velocity.'
cost = 2000
permanent = False
limit = 1
category = 'Offensive'
damages = {
'weapon_hkp2000': 21,
'weapon_p250': 26,
'weapon_glock': 13,
'weapon_fiveseven': 35,
'weapon_elite': 19,
'weapon_deagle': 58,
'weapon_tec9': 35,
'weapon_bizon': 15,
'weapon_mac10': 16,
'weapon_mp7': 22,
'weapon_mp9': 19,
'weapon_p90': 21,
'weapon_ump45': 22,
'weapon_ssg08': 93,
'weapon_awp': 121,
'weapon_g3sg1': 82,
'weapon_scar20': 65,
'weapon_ak47': 34,
'weapon_galilar': 23,
'weapon_aug': 26,
'weapon_famas': 20,
'weapon_m4a1': 48,
'weapon_sg556': 47,
'weapon_m249': 26,
'weapon_negev': 32
}
def weapon_fire(self, player, weapon, **eargs):
weapon = 'weapon_'+weapon
if weapon not in ('weapon_knife', 'weapon_hegrenade',
'weapon_c4', 'weapon_smokegrenade', 'weapon_flashbang',
'weapon_molotov', 'weapon_incendiary'):
origin = player.origin
angle = player.view_angle
velocity = player.view_vector
line = player.get_trace_ray()
## MANIPULATION FOR VECTORS
normal = line.plane.normal
wall = line.end_position
product = normal.dot(velocity)
normal *= product*2
ricochet = velocity-normal
end = wall+ricochet*1000
## TRACE OF NEW LINE
trace = GameTrace()
engine_trace.trace_ray(Ray(wall, end), ContentMasks.ALL,
TraceFilterSimple((player.index,)), trace)
## DETECTION OF PLAYER
if trace.did_hit() and not trace.did_hit_world() and not player.view_player:
target = Entity(trace.get_entity_index())
target.take_damage(self.damages[weapon], attacker_index=player.index)
## EFFECTS
loc = target.origin
loc.z += 40
temp_entities.beam_points(RecipientFilter(),
0, wall, loc,
beam_model.index, beam_model.index, 0, 255, 1, 1,
1, 3, 0, 255, 255, 255, 50, 1)
## DEBUGGING
self.message(player.index, ' TEST 2')
self.message(player.index, ' TEST')
Sorry the coding is quite messy, and only seems to fire when the detection statement is satisfied.
Also, everything works fine. Just get the error for some reason. :D